Internal problem ID [7385]
Internal file name [OUTPUT/6486_Saturday_August_06_2022_05_19_40_AM_11615872/index.tex
]
Book: First order enumerated odes
Section: section 1
Problem number: 69.
ODE order: 1.
ODE degree: 1.
The type(s) of ODE detected by this program : "first order special form ID 1", "first_order_ode_lie_symmetry_lookup"
Maple gives the following as the ode type
[[_1st_order, `_with_symmetry_[F(x),G(x)]`]]
\[ \boxed {y^{\prime }-{\mathrm e}^{x +y} x=\sin \left (x \right )} \]
Writing the ode as \begin {align*} y^{\prime } &= {\mathrm e}^{x +y} x +\sin \left (x \right )\tag {1} \end {align*}
And using the substitution \(u={\mathrm e}^{-y}\) then \begin {align*} u' &= -y^{\prime } {\mathrm e}^{-y} \end {align*}
The above shows that \begin {align*} y^{\prime } &= -u^{\prime }\left (x \right ) {\mathrm e}^{y}\\ &= -\frac {u^{\prime }\left (x \right )}{u} \end {align*}
Substituting this in (1) gives \begin {align*} -\frac {u^{\prime }\left (x \right )}{u}&=\frac {x \,{\mathrm e}^{x}}{u}+\sin \left (x \right ) \end {align*}
The above simplifies to \begin {align*} -u^{\prime }\left (x \right )&=x \,{\mathrm e}^{x}+\sin \left (x \right ) u \left (x \right )\\ u^{\prime }\left (x \right )+\sin \left (x \right ) u \left (x \right )&=-x \,{\mathrm e}^{x}\tag {2} \end {align*}
Now ode (2) is solved for \(u \left (x \right )\)
Entering Linear first order ODE solver. In canonical form a linear first order is \begin {align*} u^{\prime }\left (x \right ) + p(x)u \left (x \right ) &= q(x) \end {align*}
Where here \begin {align*} p(x) &=\sin \left (x \right )\\ q(x) &=-x \,{\mathrm e}^{x} \end {align*}
Hence the ode is \begin {align*} u^{\prime }\left (x \right )+\sin \left (x \right ) u \left (x \right ) = -x \,{\mathrm e}^{x} \end {align*}
The integrating factor \(\mu \) is \begin{align*} \mu &= {\mathrm e}^{\int \sin \left (x \right )d x} \\ &= {\mathrm e}^{-\cos \left (x \right )} \\ \end{align*} The ode becomes \begin {align*} \frac {\mathop {\mathrm {d}}}{ \mathop {\mathrm {d}x}}\left ( \mu u\right ) &= \left (\mu \right ) \left (-x \,{\mathrm e}^{x}\right ) \\ \frac {\mathop {\mathrm {d}}}{ \mathop {\mathrm {d}x}} \left ({\mathrm e}^{-\cos \left (x \right )} u\right ) &= \left ({\mathrm e}^{-\cos \left (x \right )}\right ) \left (-x \,{\mathrm e}^{x}\right )\\ \mathrm {d} \left ({\mathrm e}^{-\cos \left (x \right )} u\right ) &= \left (-x \,{\mathrm e}^{x -\cos \left (x \right )}\right )\, \mathrm {d} x \end {align*}
Integrating gives \begin {align*} {\mathrm e}^{-\cos \left (x \right )} u &= \int {-x \,{\mathrm e}^{x -\cos \left (x \right )}\,\mathrm {d} x}\\ {\mathrm e}^{-\cos \left (x \right )} u &= \int -x \,{\mathrm e}^{x -\cos \left (x \right )}d x + c_{1} \end {align*}
Dividing both sides by the integrating factor \(\mu ={\mathrm e}^{-\cos \left (x \right )}\) results in \begin {align*} u \left (x \right ) &= {\mathrm e}^{\cos \left (x \right )} \left (\int -x \,{\mathrm e}^{x -\cos \left (x \right )}d x \right )+c_{1} {\mathrm e}^{\cos \left (x \right )} \end {align*}
which simplifies to \begin {align*} u \left (x \right ) &= {\mathrm e}^{\cos \left (x \right )} \left (-\left (\int x \,{\mathrm e}^{x -\cos \left (x \right )}d x \right )+c_{1} \right ) \end {align*}
Substituting the solution found for \(u \left (x \right )\) in \(u={\mathrm e}^{-y}\) gives \begin {align*} y&= -\ln \left (u \left (x \right )\right )\\ &= -\ln \left ({\mathrm e}^{\cos \left (x \right )} \left (-\left (\int x \,{\mathrm e}^{x -\cos \left (x \right )}d x \right )+c_{1} \right )\right )\\ &= -\ln \left ({\mathrm e}^{\cos \left (x \right )} \left (-\left (\int x \,{\mathrm e}^{x -\cos \left (x \right )}d x \right )+c_{1} \right )\right ) \end {align*}
Summary
The solution(s) found are the following \begin{align*} \tag{1} y &= -\ln \left ({\mathrm e}^{\cos \left (x \right )} \left (-\left (\int x \,{\mathrm e}^{x -\cos \left (x \right )}d x \right )+c_{1} \right )\right ) \\ \end{align*}
Verification of solutions
\[ y = -\ln \left ({\mathrm e}^{\cos \left (x \right )} \left (-\left (\int x \,{\mathrm e}^{x -\cos \left (x \right )}d x \right )+c_{1} \right )\right ) \] Verified OK.
Writing the ode as \begin {align*} y^{\prime }&=x \,{\mathrm e}^{x +y}+\sin \left (x \right )\\ y^{\prime }&= \omega \left ( x,y\right ) \end {align*}
The condition of Lie symmetry is the linearized PDE given by \begin {align*} \eta _{x}+\omega \left ( \eta _{y}-\xi _{x}\right ) -\omega ^{2}\xi _{y}-\omega _{x}\xi -\omega _{y}\eta =0\tag {A} \end {align*}
The type of this ode is known. It is of type first order special form ID 1
. Therefore we
do not need to solve the PDE (A), and can just use the lookup table shown below to find \(\xi ,\eta \)
ODE class |
Form |
\(\xi \) |
\(\eta \) |
linear ode |
\(y'=f(x) y(x) +g(x)\) |
\(0\) |
\(e^{\int fdx}\) |
separable ode |
\(y^{\prime }=f\left ( x\right ) g\left ( y\right ) \) |
\(\frac {1}{f}\) |
\(0\) |
quadrature ode |
\(y^{\prime }=f\left ( x\right ) \) |
\(0\) |
\(1\) |
quadrature ode |
\(y^{\prime }=g\left ( y\right ) \) |
\(1\) |
\(0\) |
homogeneous ODEs of Class A |
\(y^{\prime }=f\left ( \frac {y}{x}\right ) \) |
\(x\) |
\(y\) |
homogeneous ODEs of Class C |
\(y^{\prime }=\left ( a+bx+cy\right ) ^{\frac {n}{m}}\) |
\(1\) |
\(-\frac {b}{c}\) |
homogeneous class D |
\(y^{\prime }=\frac {y}{x}+g\left ( x\right ) F\left (\frac {y}{x}\right ) \) |
\(x^{2}\) |
\(xy\) |
First order special form ID 1 |
\(y^{\prime }=g\left ( x\right ) e^{h\left (x\right ) +by}+f\left ( x\right ) \) |
\(\frac {e^{-\int bf\left ( x\right )dx-h\left ( x\right ) }}{g\left ( x\right ) }\) |
\(\frac {f\left ( x\right )e^{-\int bf\left ( x\right ) dx-h\left ( x\right ) }}{g\left ( x\right ) }\) |
polynomial type ode |
\(y^{\prime }=\frac {a_{1}x+b_{1}y+c_{1}}{a_{2}x+b_{2}y+c_{2}}\) |
\(\frac {a_{1}b_{2}x-a_{2}b_{1}x-b_{1}c_{2}+b_{2}c_{1}}{a_{1}b_{2}-a_{2}b_{1}}\) |
\(\frac {a_{1}b_{2}y-a_{2}b_{1}y-a_{1}c_{2}-a_{2}c_{1}}{a_{1}b_{2}-a_{2}b_{1}}\) |
Bernoulli ode |
\(y^{\prime }=f\left ( x\right ) y+g\left ( x\right ) y^{n}\) |
\(0\) |
\(e^{-\int \left ( n-1\right ) f\left ( x\right ) dx}y^{n}\) |
Reduced Riccati |
\(y^{\prime }=f_{1}\left ( x\right ) y+f_{2}\left ( x\right )y^{2}\) |
\(0\) |
\(e^{-\int f_{1}dx}\) |
|
|||
|
|||
The above table shows that \begin {align*} \xi \left (x,y\right ) &=\frac {{\mathrm e}^{\cos \left (x \right )-x}}{x}\\ \tag {A1} \eta \left (x,y\right ) &=\sin \left (x \right )+\frac {{\mathrm e}^{\cos \left (x \right )-x}}{x} \end {align*}
The next step is to determine the canonical coordinates \(R,S\). The canonical coordinates map \(\left ( x,y\right ) \to \left ( R,S \right )\) where \(\left ( R,S \right )\) are the canonical coordinates which make the original ode become a quadrature and hence solved by integration.
The characteristic pde which is used to find the canonical coordinates is \begin {align*} \frac {d x}{\xi } &= \frac {d y}{\eta } = dS \tag {1} \end {align*}
The above comes from the requirements that \(\left ( \xi \frac {\partial }{\partial x} + \eta \frac {\partial }{\partial y}\right ) S(x,y) = 1\). Starting with the first pair of ode’s in (1) gives an ode to solve for the independent variable \(R\) in the canonical coordinates, where \(S(R)\). Therefore \begin {align*} \frac {dy}{dx} &= \frac {\eta }{\xi }\\ &= \frac {\sin \left (x \right )+\frac {{\mathrm e}^{\cos \left (x \right )-x}}{x}}{\frac {{\mathrm e}^{\cos \left (x \right )-x}}{x}}\\ &= {\mathrm e}^{x -\cos \left (x \right )} \left (x \sin \left (x \right )+{\mathrm e}^{\cos \left (x \right )-x}\right ) \end {align*}
This is easily solved to give \begin {align*} y = \int {\mathrm e}^{x -\cos \left (x \right )} \left (x \sin \left (x \right )+{\mathrm e}^{\cos \left (x \right )-x}\right )d x +c_{1} \end {align*}
Where now the coordinate \(R\) is taken as the constant of integration. Hence \begin {align*} R &= -\left (\int {\mathrm e}^{x -\cos \left (x \right )} \left (x \sin \left (x \right )+{\mathrm e}^{\cos \left (x \right )-x}\right )d x \right )+y \end {align*}
And \(S\) is found from \begin {align*} dS &= \frac {dx}{\xi } \\ &= \frac {dx}{\frac {{\mathrm e}^{\cos \left (x \right )-x}}{x}} \end {align*}
Integrating gives \begin {align*} S &= \int { \frac {dx}{T}}\\ &= \int x \,{\mathrm e}^{x -\cos \left (x \right )}d x \end {align*}
Where the constant of integration is set to zero as we just need one solution.
\[ \begin {array}{lll} & {} & \textrm {Let's solve}\hspace {3pt} \\ {} & {} & y^{\prime }-{\mathrm e}^{x +y} x =\sin \left (x \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 }={\mathrm e}^{x +y} x +\sin \left (x \right ) \end {array} \]
Maple trace
`Methods for first order ODEs: --- Trying classification methods --- trying a quadrature trying 1st order linear trying Bernoulli trying separable trying inverse linear trying homogeneous types: trying Chini differential order: 1; looking for linear symmetries trying exact Looking for potential symmetries trying inverse_Riccati trying an equivalence to an Abel ODE differential order: 1; trying a linearization to 2nd order --- trying a change of variables {x -> y(x), y(x) -> x} differential order: 1; trying a linearization to 2nd order trying 1st order ODE linearizable_by_differentiation --- Trying Lie symmetry methods, 1st order --- `, `-> Computing symmetries using: way = 3 `, `-> Computing symmetries using: way = 4 `, `-> Computing symmetries using: way = 5 trying symmetry patterns for 1st order ODEs -> trying a symmetry pattern of the form [F(x)*G(y), 0] -> trying a symmetry pattern of the form [0, F(x)*G(y)] <- symmetry pattern of the form [0, F(x)*G(y)] successful`
✓ Solution by Maple
Time used: 0.016 (sec). Leaf size: 29
dsolve(diff(y(x),x)=x*exp(x+y(x))+sin(x),y(x), singsol=all)
\[ y \left (x \right ) = -\cos \left (x \right )-\ln \left (-c_{1} -\left (\int x \,{\mathrm e}^{x -\cos \left (x \right )}d x \right )\right ) \]
✓ Solution by Mathematica
Time used: 3.93 (sec). Leaf size: 100
DSolve[y'[x]==x*Exp[x+y[x]]+Sin[x],y[x],x,IncludeSingularSolutions -> True]
\[ \text {Solve}\left [\int _1^x\left (-e^{K[1]-\cos (K[1])} K[1]-e^{-\cos (K[1])-y(x)} \sin (K[1])\right )dK[1]+\int _1^{y(x)}-e^{-\cos (x)-K[2]} \left (e^{\cos (x)+K[2]} \int _1^xe^{-\cos (K[1])-K[2]} \sin (K[1])dK[1]-1\right )dK[2]=c_1,y(x)\right ] \]