Internal problem ID [5243]
Book: An introduction to Ordinary Differential Equations. Earl A. Coddington. Dover. NY
1961
Section: Chapter 2. Linear equations with constant coefficients. Page 89
Problem number: 1(f).
ODE order: 2.
ODE degree: 1.
CAS Maple gives this as type [[_2nd_order, _linear, _nonhomogeneous]]
Solve \begin {gather*} \boxed {y^{\prime \prime }-2 i y^{\prime }-y-{\mathrm e}^{i x}+2 \,{\mathrm e}^{-i x}=0} \end {gather*}
✓ Solution by Maple
Time used: 0.125 (sec). Leaf size: 44
dsolve(diff(y(x),x$2)-2*I*diff(y(x),x)-y(x)=exp(I*x)-2*exp(-I*x),y(x), singsol=all)
\[ y \relax (x ) = c_{2} {\mathrm e}^{i x}+x \,{\mathrm e}^{i x} c_{1}+\frac {\left (x^{2}+2 i x +2\right ) \cos \relax (x )}{2}+\frac {\sin \relax (x ) \left (i x -2\right ) x}{2} \]
✓ Solution by Mathematica
Time used: 0.079 (sec). Leaf size: 39
DSolve[y''[x]-2*I*y'[x]-y[x]==Exp[I*x]-2*Exp[-I*x],y[x],x,IncludeSingularSolutions -> True]
\begin{align*} y(x)\to \frac {1}{2} e^{-i x} \left (1+e^{2 i x} \left (x^2+2 c_2 x+2 c_1\right )\right ) \\ \end{align*}