62.36.3 problem Ex 3

Internal problem ID [13001]
Book : An elementary treatise on differential equations by Abraham Cohen. DC heath publishers. 1906
Section : Chapter IX, Miscellaneous methods for solving equations of higher order than first. Article 60. Exact equation. Integrating factor. Page 139
Problem number : Ex 3
Date solved : Tuesday, January 28, 2025 at 04:47:14 AM
CAS classification : [[_2nd_order, _exact, _linear, _nonhomogeneous]]

\begin{align*} \left (x -1\right )^{2} y^{\prime \prime }+4 \left (x -1\right ) y^{\prime }+2 y&=\cos \left (x \right ) \end{align*}

Solution by Maple

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

dsolve((x-1)^2*diff(y(x),x$2)+4*(x-1)*diff(y(x),x)+2*y(x)=cos(x),y(x), singsol=all)
 
\[ y = \frac {c_{2} +c_{1} x -\cos \left (x \right )}{\left (x -1\right )^{2}} \]

Solution by Mathematica

Time used: 0.148 (sec). Leaf size: 52

DSolve[(x-1)^2*D[y[x],{x,2}]+4*(x-1)*D[y[x],x]+2*y[x]==Cos[x],y[x],x,IncludeSingularSolutions -> True]
 
\[ y(x)\to \frac {(x-1) \int _1^x\cos (K[1])dK[1]+\int _1^x-\cos (K[2]) (K[2]-1)dK[2]+c_1 x-c_1+c_2}{(x-1)^2} \]