4.24.41 \(y''(x)+y(x)=e^{-x}\)

ODE
\[ y''(x)+y(x)=e^{-x} \] ODE Classification

[[_2nd_order, _with_linear_symmetries]]

Book solution method
TO DO

Mathematica
cpu = 0.0243605 (sec), leaf count = 25

\[\left \{\left \{y(x)\to c_2 \sin (x)+c_1 \cos (x)+\frac {e^{-x}}{2}\right \}\right \}\]

Maple
cpu = 0.021 (sec), leaf count = 19

\[ \left \{ y \left ( x \right ) =\sin \left ( x \right ) {\it \_C2}+\cos \left ( x \right ) {\it \_C1}+{\frac {{{\rm e}^{-x}}}{2}} \right \} \] Mathematica raw input

DSolve[y[x] + y''[x] == E^(-x),y[x],x]

Mathematica raw output

{{y[x] -> 1/(2*E^x) + C[1]*Cos[x] + C[2]*Sin[x]}}

Maple raw input

dsolve(diff(diff(y(x),x),x)+y(x) = exp(-x), y(x),'implicit')

Maple raw output

y(x) = sin(x)*_C2+cos(x)*_C1+1/2*exp(-x)