2.5 problem 10.3.6

Internal problem ID [4551]

Book: Basic Training in Mathematics. By R. Shankar. Plenum Press. NY. 1995
Section: Chapter 10, Differential equations. Section 10.3, ODEs with variable Coefficients. First order. page 315
Problem number: 10.3.6.
ODE order: 1.
ODE degree: 1.

CAS Maple gives this as type [_linear]

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

Solution by Maple

Time used: 0.001 (sec). Leaf size: 24

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

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

Solution by Mathematica

Time used: 0.036 (sec). Leaf size: 27

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

\begin{align*} y(x)\to (x-1) \left (\frac {1}{2} (x-1)^2-\log (x-1)+c_1\right ) \\ \end{align*}