81.5.3 problem 3

Internal problem ID [18666]
Book : A short course on differential equations. By Donald Francis Campbell. Maxmillan company. London. 1907
Section : Chapter IV. Ordinary linear differential equations with constant coefficients. Exercises at page 58
Problem number : 3
Date solved : Tuesday, January 28, 2025 at 12:09:01 PM
CAS classification : [[_2nd_order, _with_linear_symmetries]]

\begin{align*} y^{\prime \prime }-4 y^{\prime }+2 y&=x \end{align*}

Solution by Maple

Time used: 0.003 (sec). Leaf size: 30

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

Solution by Mathematica

Time used: 0.021 (sec). Leaf size: 41

DSolve[D[y[x],{x,2}]-4*D[y[x],x]+2*y[x]==x,y[x],x,IncludeSingularSolutions -> True]
 
\[ y(x)\to \frac {x}{2}+c_1 e^{-\left (\left (\sqrt {2}-2\right ) x\right )}+c_2 e^{\left (2+\sqrt {2}\right ) x}+1 \]