68.1.4 problem Problem 1.3(b)

Internal problem ID [14133]
Book : Differential Equations, Linear, Nonlinear, Ordinary, Partial. A.C. King, J.Billingham, S.R.Otto. Cambridge Univ. Press 2003
Section : Chapter 1 VARIABLE COEFFICIENT, SECOND ORDER DIFFERENTIAL EQUATIONS. Problems page 28
Problem number : Problem 1.3(b)
Date solved : Tuesday, January 28, 2025 at 06:15:29 AM
CAS classification : [[_2nd_order, _linear, _nonhomogeneous]]

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

Solution by Maple

Time used: 0.003 (sec). Leaf size: 30

dsolve(diff(y(x),x$2)+4*y(x)=2*sec(2*x),y(x), singsol=all)
 
\[ y = -\frac {\cos \left (2 x \right ) \ln \left (\sec \left (2 x \right )\right )}{2}+\cos \left (2 x \right ) c_{1} +\sin \left (2 x \right ) \left (x +c_{2} \right ) \]

Solution by Mathematica

Time used: 0.036 (sec). Leaf size: 32

DSolve[D[y[x],{x,2}]+4*y[x]==2*Sec[2*x],y[x],x,IncludeSingularSolutions -> True]
 
\[ y(x)\to (x+c_2) \sin (2 x)+\cos (2 x) \left (\frac {1}{2} \log (\cos (2 x))+c_1\right ) \]