ODE
\[ x^2 y''(x)+4 x y'(x)+2 y(x)=e^x \] ODE Classification
[[_2nd_order, _exact, _linear, _nonhomogeneous]]
Book solution method
TO DO
Mathematica ✓
cpu = 0.0145965 (sec), leaf count = 19
\[\left \{\left \{y(x)\to \frac {c_1 x+c_2+e^x}{x^2}\right \}\right \}\]
Maple ✓
cpu = 0.014 (sec), leaf count = 15
\[ \left \{ y \left ( x \right ) ={\frac {{\it \_C2}+{\it \_C1}\,x+{{\rm e}^{x}}}{{x}^{2}}} \right \} \] Mathematica raw input
DSolve[2*y[x] + 4*x*y'[x] + x^2*y''[x] == E^x,y[x],x]
Mathematica raw output
{{y[x] -> (E^x + x*C[1] + C[2])/x^2}}
Maple raw input
dsolve(x^2*diff(diff(y(x),x),x)+4*x*diff(y(x),x)+2*y(x) = exp(x), y(x),'implicit')
Maple raw output
y(x) = (_C2+_C1*x+exp(x))/x^2