Internal problem ID [6882]
Internal file name [OUTPUT/6125_Friday_August_05_2022_02_21_32_AM_77399903/index.tex
]
Book: Elementary differential equations. Rainville, Bedient, Bedient. Prentice Hall. NJ. 8th
edition. 1997.
Section: CHAPTER 16. Nonlinear equations. Miscellaneous Exercises. Page 340
Problem number: 21.
ODE order: 1.
ODE degree: 2.
The type(s) of ODE detected by this program : "exact", "linear", "differentialType", "homogeneousTypeD2", "first_order_ode_lie_symmetry_lookup"
Maple gives the following as the ode type
[_linear]
\[ \boxed {x^{2} {y^{\prime }}^{2}-\left (x -y\right )^{2}=0} \] The ode \begin {align*} x^{2} {y^{\prime }}^{2}-\left (x -y\right )^{2} = 0 \end {align*}
is factored to \begin {align*} \left (y^{\prime } x +y-x \right ) \left (-y^{\prime } x +y-x \right ) = 0 \end {align*}
Which gives the following equations \begin {align*} y^{\prime } x +y-x = 0\tag {1} \\ -y^{\prime } x +y-x = 0\tag {2} \\ \end {align*}
Each of the above equations is now solved.
Solving ODE (1)
Entering Linear first order ODE solver. In canonical form a linear first order is \begin {align*} y^{\prime } + p(x)y &= q(x) \end {align*}
Where here \begin {align*} p(x) &=\frac {1}{x}\\ q(x) &=1 \end {align*}
Hence the ode is \begin {align*} y^{\prime }+\frac {y}{x} = 1 \end {align*}
The integrating factor \(\mu \) is \begin{align*} \mu &= {\mathrm e}^{\int \frac {1}{x}d x} \\ &= x \\ \end{align*} The ode becomes \begin {align*} \frac {\mathop {\mathrm {d}}}{ \mathop {\mathrm {d}x}}\left ( \mu y\right ) &= \mu \\ \frac {\mathop {\mathrm {d}}}{ \mathop {\mathrm {d}x}} \left (x y\right ) &= x\\ \mathrm {d} \left (x y\right ) &= x\mathrm {d} x \end {align*}
Integrating gives \begin {align*} x y &= \int {x\,\mathrm {d} x}\\ x y &= \frac {x^{2}}{2} + c_{1} \end {align*}
Dividing both sides by the integrating factor \(\mu =x\) results in \begin {align*} y &= \frac {x}{2}+\frac {c_{1}}{x} \end {align*}
Summary
The solution(s) found are the following \begin{align*} \tag{1} y &= \frac {x}{2}+\frac {c_{1}}{x} \\ \end{align*}
Verification of solutions
\[ y = \frac {x}{2}+\frac {c_{1}}{x} \] Verified OK.
Summary
The solution(s) found are the following \begin{align*} \tag{1} y &= \frac {x}{2}+\frac {c_{1}}{x} \\ \end{align*}
Verification of solutions
\[ y = \frac {x}{2}+\frac {c_{1}}{x} \] Verified OK.
Solving ODE (2)
Entering Linear first order ODE solver. In canonical form a linear first order is \begin {align*} y^{\prime } + p(x)y &= q(x) \end {align*}
Where here \begin {align*} p(x) &=-\frac {1}{x}\\ q(x) &=-1 \end {align*}
Hence the ode is \begin {align*} y^{\prime }-\frac {y}{x} = -1 \end {align*}
The integrating factor \(\mu \) is \begin{align*} \mu &= {\mathrm e}^{\int -\frac {1}{x}d x} \\ &= \frac {1}{x} \\ \end{align*} The ode becomes \begin {align*} \frac {\mathop {\mathrm {d}}}{ \mathop {\mathrm {d}x}}\left ( \mu y\right ) &= \left (\mu \right ) \left (-1\right ) \\ \frac {\mathop {\mathrm {d}}}{ \mathop {\mathrm {d}x}} \left (\frac {y}{x}\right ) &= \left (\frac {1}{x}\right ) \left (-1\right )\\ \mathrm {d} \left (\frac {y}{x}\right ) &= \left (-\frac {1}{x}\right )\, \mathrm {d} x \end {align*}
Integrating gives \begin {align*} \frac {y}{x} &= \int {-\frac {1}{x}\,\mathrm {d} x}\\ \frac {y}{x} &= -\ln \left (x \right ) + c_{2} \end {align*}
Dividing both sides by the integrating factor \(\mu =\frac {1}{x}\) results in \begin {align*} y &= -\ln \left (x \right ) x +c_{2} x \end {align*}
which simplifies to \begin {align*} y &= x \left (-\ln \left (x \right )+c_{2} \right ) \end {align*}
Summary
The solution(s) found are the following \begin{align*} \tag{1} y &= x \left (-\ln \left (x \right )+c_{2} \right ) \\ \end{align*}
Verification of solutions
\[ y = x \left (-\ln \left (x \right )+c_{2} \right ) \] Verified OK.
Summary
The solution(s) found are the following \begin{align*} \tag{1} y &= x \left (-\ln \left (x \right )+c_{2} \right ) \\ \end{align*}
Verification of solutions
\[ y = x \left (-\ln \left (x \right )+c_{2} \right ) \] Verified OK.
\[ \begin {array}{lll} & {} & \textrm {Let's solve}\hspace {3pt} \\ {} & {} & x^{2} {y^{\prime }}^{2}-\left (x -y\right )^{2}=0 \\ \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} \\ {} & {} & \left [y^{\prime }=\frac {y-x}{x}, y^{\prime }=-\frac {y-x}{x}\right ] \\ \square & {} & \textrm {Solve the equation}\hspace {3pt} y^{\prime }=\frac {y-x}{x} \\ {} & \circ & \textrm {Collect w.r.t.}\hspace {3pt} y\hspace {3pt}\textrm {and simplify}\hspace {3pt} \\ {} & {} & y^{\prime }=\frac {y}{x}-1 \\ {} & \circ & \textrm {Group terms with}\hspace {3pt} y\hspace {3pt}\textrm {on the lhs of the ODE and the rest on the rhs of the ODE}\hspace {3pt} \\ {} & {} & y^{\prime }-\frac {y}{x}=-1 \\ {} & \circ & \textrm {The ODE is linear; multiply by an integrating factor}\hspace {3pt} \mu \left (x \right ) \\ {} & {} & \mu \left (x \right ) \left (y^{\prime }-\frac {y}{x}\right )=-\mu \left (x \right ) \\ {} & \circ & \textrm {Assume the lhs of the ODE is the total derivative}\hspace {3pt} \frac {d}{d x}\left (y \mu \left (x \right )\right ) \\ {} & {} & \mu \left (x \right ) \left (y^{\prime }-\frac {y}{x}\right )=y^{\prime } \mu \left (x \right )+y \mu ^{\prime }\left (x \right ) \\ {} & \circ & \textrm {Isolate}\hspace {3pt} \mu ^{\prime }\left (x \right ) \\ {} & {} & \mu ^{\prime }\left (x \right )=-\frac {\mu \left (x \right )}{x} \\ {} & \circ & \textrm {Solve to find the integrating factor}\hspace {3pt} \\ {} & {} & \mu \left (x \right )=\frac {1}{x} \\ {} & \circ & \textrm {Integrate both sides with respect to}\hspace {3pt} x \\ {} & {} & \int \left (\frac {d}{d x}\left (y \mu \left (x \right )\right )\right )d x =\int -\mu \left (x \right )d x +c_{1} \\ {} & \circ & \textrm {Evaluate the integral on the lhs}\hspace {3pt} \\ {} & {} & y \mu \left (x \right )=\int -\mu \left (x \right )d x +c_{1} \\ {} & \circ & \textrm {Solve for}\hspace {3pt} y \\ {} & {} & y=\frac {\int -\mu \left (x \right )d x +c_{1}}{\mu \left (x \right )} \\ {} & \circ & \textrm {Substitute}\hspace {3pt} \mu \left (x \right )=\frac {1}{x} \\ {} & {} & y=x \left (\int -\frac {1}{x}d x +c_{1} \right ) \\ {} & \circ & \textrm {Evaluate the integrals on the rhs}\hspace {3pt} \\ {} & {} & y=x \left (-\ln \left (x \right )+c_{1} \right ) \\ \square & {} & \textrm {Solve the equation}\hspace {3pt} y^{\prime }=-\frac {y-x}{x} \\ {} & \circ & \textrm {Collect w.r.t.}\hspace {3pt} y\hspace {3pt}\textrm {and simplify}\hspace {3pt} \\ {} & {} & y^{\prime }=1-\frac {y}{x} \\ {} & \circ & \textrm {Group terms with}\hspace {3pt} y\hspace {3pt}\textrm {on the lhs of the ODE and the rest on the rhs of the ODE}\hspace {3pt} \\ {} & {} & y^{\prime }+\frac {y}{x}=1 \\ {} & \circ & \textrm {The ODE is linear; multiply by an integrating factor}\hspace {3pt} \mu \left (x \right ) \\ {} & {} & \mu \left (x \right ) \left (y^{\prime }+\frac {y}{x}\right )=\mu \left (x \right ) \\ {} & \circ & \textrm {Assume the lhs of the ODE is the total derivative}\hspace {3pt} \frac {d}{d x}\left (y \mu \left (x \right )\right ) \\ {} & {} & \mu \left (x \right ) \left (y^{\prime }+\frac {y}{x}\right )=y^{\prime } \mu \left (x \right )+y \mu ^{\prime }\left (x \right ) \\ {} & \circ & \textrm {Isolate}\hspace {3pt} \mu ^{\prime }\left (x \right ) \\ {} & {} & \mu ^{\prime }\left (x \right )=\frac {\mu \left (x \right )}{x} \\ {} & \circ & \textrm {Solve to find the integrating factor}\hspace {3pt} \\ {} & {} & \mu \left (x \right )=x \\ {} & \circ & \textrm {Integrate both sides with respect to}\hspace {3pt} x \\ {} & {} & \int \left (\frac {d}{d x}\left (y \mu \left (x \right )\right )\right )d x =\int \mu \left (x \right )d x +c_{1} \\ {} & \circ & \textrm {Evaluate the integral on the lhs}\hspace {3pt} \\ {} & {} & y \mu \left (x \right )=\int \mu \left (x \right )d x +c_{1} \\ {} & \circ & \textrm {Solve for}\hspace {3pt} y \\ {} & {} & y=\frac {\int \mu \left (x \right )d x +c_{1}}{\mu \left (x \right )} \\ {} & \circ & \textrm {Substitute}\hspace {3pt} \mu \left (x \right )=x \\ {} & {} & y=\frac {\int x d x +c_{1}}{x} \\ {} & \circ & \textrm {Evaluate the integrals on the rhs}\hspace {3pt} \\ {} & {} & y=\frac {\frac {x^{2}}{2}+c_{1}}{x} \\ {} & \circ & \textrm {Simplify}\hspace {3pt} \\ {} & {} & y=\frac {x^{2}+2 c_{1}}{2 x} \\ \bullet & {} & \textrm {Set of solutions}\hspace {3pt} \\ {} & {} & \left \{y=x \left (-\ln \left (x \right )+c_{1} \right ), y=\frac {x^{2}+2 c_{1}}{2 x}\right \} \end {array} \]
Maple trace
`Methods for first order ODEs: --- Trying classification methods --- trying a quadrature trying 1st order linear <- 1st order linear successful Methods for first order ODEs: --- Trying classification methods --- trying a quadrature trying 1st order linear <- 1st order linear successful`
✓ Solution by Maple
Time used: 0.0 (sec). Leaf size: 24
dsolve(x^2*diff(y(x),x)^2=(x-y(x))^2,y(x), singsol=all)
\begin{align*} y \left (x \right ) &= \left (-\ln \left (x \right )+c_{1} \right ) x \\ y \left (x \right ) &= \frac {x}{2}+\frac {c_{1}}{x} \\ \end{align*}
✓ Solution by Mathematica
Time used: 0.073 (sec). Leaf size: 30
DSolve[x^2*y'[x]^2==(x-y[x])^2,y[x],x,IncludeSingularSolutions -> True]
\begin{align*} y(x)\to \frac {x}{2}+\frac {c_1}{x} \\ y(x)\to x (-\log (x)+c_1) \\ \end{align*}