15.14.13 problem 13

Internal problem ID [3185]
Book : Differential Equations by Alfred L. Nelson, Karl W. Folley, Max Coral. 3rd ed. DC heath. Boston. 1964
Section : Exercise 23, page 106
Problem number : 13
Date solved : Monday, January 27, 2025 at 07:25:24 AM
CAS classification : [[_2nd_order, _linear, _nonhomogeneous]]

\begin{align*} y^{\prime \prime }+2 n^{2} y^{\prime }+n^{4} y&=\sin \left (k x \right ) \end{align*}

Solution by Maple

Time used: 0.004 (sec). Leaf size: 61

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

Solution by Mathematica

Time used: 0.211 (sec). Leaf size: 64

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