Internal problem ID [5727]
Internal file name [OUTPUT/4975_Sunday_June_05_2022_03_15_40_PM_2246626/index.tex
]
Book: Ordinary differential equations and calculus of variations. Makarets and Reshetnyak. Wold
Scientific. Singapore. 1995
Section: Chapter 1. First order differential equations. Section 1.1 Separable equations problems.
page 7
Problem number: 14.
ODE order: 1.
ODE degree: 1.
The type(s) of ODE detected by this program : "exact", "separable", "first_order_ode_lie_symmetry_lookup"
Maple gives the following as the ode type
[_separable]
\[ \boxed {-\left ({\mathrm e}^{x}+1\right ) y y^{\prime }=-{\mathrm e}^{x}} \] With initial conditions \begin {align*} [y \left (0\right ) = 1] \end {align*}
This is non linear first order ODE. In canonical form it is written as \begin {align*} y^{\prime } &= f(x,y)\\ &= \frac {{\mathrm e}^{x}}{\left ({\mathrm e}^{x}+1\right ) y} \end {align*}
The \(x\) domain of \(f(x,y)\) when \(y=1\) is \[ \{2 i \pi \_Z183 +i \pi <x\} \] But the point \(x_0 = 0\) is not inside this domain. Hence existence and uniqueness theorem does not apply. There could be infinite number of solutions, or one solution or no solution at all.
In canonical form the ODE is \begin {align*} y' &= F(x,y)\\ &= f( x) g(y)\\ &= \frac {{\mathrm e}^{x}}{\left ({\mathrm e}^{x}+1\right ) y} \end {align*}
Where \(f(x)=\frac {{\mathrm e}^{x}}{{\mathrm e}^{x}+1}\) and \(g(y)=\frac {1}{y}\). Integrating both sides gives \begin{align*} \frac {1}{\frac {1}{y}} \,dy &= \frac {{\mathrm e}^{x}}{{\mathrm e}^{x}+1} \,d x \\ \int { \frac {1}{\frac {1}{y}} \,dy} &= \int {\frac {{\mathrm e}^{x}}{{\mathrm e}^{x}+1} \,d x} \\ \frac {y^{2}}{2}&=\ln \left ({\mathrm e}^{x}+1\right )+c_{1} \\ \end{align*} Which results in \begin{align*} y &= \sqrt {2 \ln \left ({\mathrm e}^{x}+1\right )+2 c_{1}} \\ y &= -\sqrt {2 \ln \left ({\mathrm e}^{x}+1\right )+2 c_{1}} \\ \end{align*} Initial conditions are used to solve for \(c_{1}\). Substituting \(x=0\) and \(y=1\) in the above solution gives an equation to solve for the constant of integration. \begin {align*} 1 = -\sqrt {2 \ln \left (2\right )+2 c_{1}} \end {align*}
Warning: Unable to solve for constant of integration. Initial conditions are used to solve for \(c_{1}\). Substituting \(x=0\) and \(y=1\) in the above solution gives an equation to solve for the constant of integration. \begin {align*} 1 = \sqrt {2 \ln \left (2\right )+2 c_{1}} \end {align*}
The solutions are \begin {align*} c_{1} = -\ln \left (2\right )+\frac {1}{2} \end {align*}
Trying the constant \begin {align*} c_{1} = -\ln \left (2\right )+\frac {1}{2} \end {align*}
Substituting this in the general solution gives \begin {align*} y&=\sqrt {2 \ln \left ({\mathrm e}^{x}+1\right )-2 \ln \left (2\right )+1} \end {align*}
The constant \(c_{1} = -\ln \left (2\right )+\frac {1}{2}\) gives valid solution.
Summary
The solution(s) found are the following \begin{align*} \tag{1} y &= \sqrt {2 \ln \left ({\mathrm e}^{x}+1\right )-2 \ln \left (2\right )+1} \\ \end{align*}
Verification of solutions
\[ y = \sqrt {2 \ln \left ({\mathrm e}^{x}+1\right )-2 \ln \left (2\right )+1} \] Verified OK.
\[ \begin {array}{lll} & {} & \textrm {Let's solve}\hspace {3pt} \\ {} & {} & \left [-\left ({\mathrm e}^{x}+1\right ) y y^{\prime }=-{\mathrm e}^{x}, y \left (0\right )=1\right ] \\ \bullet & {} & \textrm {Highest derivative means the order of the ODE is}\hspace {3pt} 1 \\ {} & {} & y^{\prime } \\ \bullet & {} & \textrm {Solve for the highest derivative}\hspace {3pt} \\ {} & {} & y^{\prime }=\frac {{\mathrm e}^{x}}{\left ({\mathrm e}^{x}+1\right ) y} \\ \bullet & {} & \textrm {Separate variables}\hspace {3pt} \\ {} & {} & y y^{\prime }=\frac {{\mathrm e}^{x}}{{\mathrm e}^{x}+1} \\ \bullet & {} & \textrm {Integrate both sides with respect to}\hspace {3pt} x \\ {} & {} & \int y y^{\prime }d x =\int \frac {{\mathrm e}^{x}}{{\mathrm e}^{x}+1}d x +c_{1} \\ \bullet & {} & \textrm {Evaluate integral}\hspace {3pt} \\ {} & {} & \frac {y^{2}}{2}=\ln \left ({\mathrm e}^{x}+1\right )+c_{1} \\ \bullet & {} & \textrm {Solve for}\hspace {3pt} y \\ {} & {} & \left \{y=\sqrt {2 \ln \left ({\mathrm e}^{x}+1\right )+2 c_{1}}, y=-\sqrt {2 \ln \left ({\mathrm e}^{x}+1\right )+2 c_{1}}\right \} \\ \bullet & {} & \textrm {Use initial condition}\hspace {3pt} y \left (0\right )=1 \\ {} & {} & 1=\sqrt {2 \ln \left (2\right )+2 c_{1}} \\ \bullet & {} & \textrm {Solve for}\hspace {3pt} c_{1} \\ {} & {} & c_{1} =-\ln \left (2\right )+\frac {1}{2} \\ \bullet & {} & \textrm {Substitute}\hspace {3pt} c_{1} =-\ln \left (2\right )+\frac {1}{2}\hspace {3pt}\textrm {into general solution and simplify}\hspace {3pt} \\ {} & {} & y=\sqrt {2 \ln \left ({\mathrm e}^{x}+1\right )-2 \ln \left (2\right )+1} \\ \bullet & {} & \textrm {Use initial condition}\hspace {3pt} y \left (0\right )=1 \\ {} & {} & 1=-\sqrt {2 \ln \left (2\right )+2 c_{1}} \\ \bullet & {} & \textrm {Solve for}\hspace {3pt} c_{1} \\ {} & {} & c_{1} =\left (\right ) \\ \bullet & {} & \textrm {Solution does not satisfy initial condition}\hspace {3pt} \\ \bullet & {} & \textrm {Solution to the IVP}\hspace {3pt} \\ {} & {} & y=\sqrt {2 \ln \left ({\mathrm e}^{x}+1\right )-2 \ln \left (2\right )+1} \end {array} \]
Maple trace
`Methods for first order ODEs: --- Trying classification methods --- trying a quadrature trying 1st order linear trying Bernoulli <- Bernoulli successful`
✓ Solution by Maple
Time used: 0.219 (sec). Leaf size: 19
dsolve([exp(x)-(1+exp(x))*y(x)*diff(y(x),x)=0,y(0) = 1],y(x), singsol=all)
\[ y \left (x \right ) = \sqrt {2 \ln \left ({\mathrm e}^{x}+1\right )-2 \ln \left (2\right )+1} \]
✓ Solution by Mathematica
Time used: 0.182 (sec). Leaf size: 23
DSolve[{Exp[x]-(1+Exp[x])*y[x]*y'[x]==0,{y[0]==1}},y[x],x,IncludeSingularSolutions -> True]
\[ y(x)\to \sqrt {2 \log \left (e^x+1\right )+1-\log (4)} \]