ODE
\[ y''(x)-a^2 y(x)=x+1 \] ODE Classification
[[_2nd_order, _with_linear_symmetries]]
Book solution method
TO DO
Mathematica ✓
cpu = 0.14994 (sec), leaf count = 31
\[\left \{\left \{y(x)\to -\frac {x+1}{a^2}+c_1 e^{a x}+c_2 e^{-a x}\right \}\right \}\]
Maple ✓
cpu = 0.015 (sec), leaf count = 27
\[\left [y \left (x \right ) = {\mathrm e}^{a x} \textit {\_C2} +{\mathrm e}^{-a x} \textit {\_C1} +\frac {-x -1}{a^{2}}\right ]\] Mathematica raw input
DSolve[-(a^2*y[x]) + y''[x] == 1 + x,y[x],x]
Mathematica raw output
{{y[x] -> -((1 + x)/a^2) + E^(a*x)*C[1] + C[2]/E^(a*x)}}
Maple raw input
dsolve(diff(diff(y(x),x),x)-a^2*y(x) = x+1, y(x))
Maple raw output
[y(x) = exp(a*x)*_C2+exp(-a*x)*_C1+(-x-1)/a^2]