5.5 problem 5

Internal problem ID [5073]

Book: Ordinary differential equations and calculus of variations. Makarets and Reshetnyak. Wold Scientific. Singapore. 1995
Section: Chapter 2. Linear homogeneous equations. Section 2.3.4 problems. page 104
Problem number: 5.
ODE order: 2.
ODE degree: 1.

CAS Maple gives this as type [[_2nd_order, _exact, _linear, _nonhomogeneous]]

Solve \begin {gather*} \boxed {x \left (1+x \right ) y^{\prime \prime }+\left (2+x \right ) y^{\prime }-y-x -\frac {1}{x}=0} \end {gather*}

Solution by Maple

Time used: 0.002 (sec). Leaf size: 42

dsolve(x*(1+x)*diff(y(x),x$2)+(x+2)*diff(y(x),x)-y(x)=x+1/x,y(x), singsol=all)
 

\[ y \relax (x ) = \frac {c_{1}}{x}+\frac {\left (x +1\right )^{2} c_{2}}{x}+\frac {2 \ln \relax (x ) x^{2}+4 \ln \relax (x ) x +6 x +5}{4 x} \]

Solution by Mathematica

Time used: 0.019 (sec). Leaf size: 37

DSolve[x*(1+x)*y''[x]+(x+2)*y'[x]-y[x]==x+1/x,y[x],x,IncludeSingularSolutions -> True]
 

\begin{align*} y(x)\to \frac {1}{2} (x+2) \log (x)+\frac {1+c_1}{x}+\frac {1}{4} (-1+2 c_2) x+1+c_2 \\ \end{align*}