11.7 problem Problem 10

Internal problem ID [2309]

Book: Differential equations and linear algebra, Stephen W. Goode and Scott A Annin. Fourth edition, 2015
Section: Chapter 8, Linear differential equations of order n. Section 8.9, Reduction of Order. page 572
Problem number: Problem 10.
ODE order: 2.
ODE degree: 1.

CAS Maple gives this as type [[_2nd_order, _linear, _nonhomogeneous]]

Solve \begin {gather*} \boxed {y^{\prime \prime }+y-\csc \relax (x )=0} \end {gather*} Given that one solution of the ode is \begin {align*} y_1 &= \sin \relax (x ) \end {align*}

Solution by Maple

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

dsolve([diff(y(x),x$2)+y(x)=csc(x),sin(x)],y(x), singsol=all)
 

\[ y \relax (x ) = \sin \relax (x ) c_{2}+\cos \relax (x ) c_{1}-\ln \left (\frac {1}{\sin \relax (x )}\right ) \sin \relax (x )-x \cos \relax (x ) \]

Solution by Mathematica

Time used: 0.009 (sec). Leaf size: 24

DSolve[y''[x]+y[x]==Csc[x],y[x],x,IncludeSingularSolutions -> True]
 

\begin{align*} y(x)\to (-x+c_1) \cos (x)+\sin (x) (\log (\sin (x))+c_2) \\ \end{align*}