3.17 problem Problem 17

Internal problem ID [2146]

Book: Differential equations and linear algebra, Stephen W. Goode and Scott A Annin. Fourth edition, 2015
Section: Chapter 1, First-Order Differential Equations. Section 1.6, First-Order Linear Differential Equations. page 59
Problem number: Problem 17.
ODE order: 1.
ODE degree: 1.

CAS Maple gives this as type [_linear]

Solve \begin {gather*} \boxed {\sin \relax (x ) y^{\prime }-\cos \relax (x ) y-\sin \left (2 x \right )=0} \end {gather*} With initial conditions \begin {align*} \left [y \left (\frac {\pi }{2}\right ) = 2\right ] \end {align*}

Solution by Maple

Time used: 0.012 (sec). Leaf size: 14

dsolve([sin(x)*diff(y(x),x)-y(x)*cos(x)=sin(2*x),y(1/2*Pi) = 2],y(x), singsol=all)
 

\[ y \relax (x ) = \left (2 \ln \left (\sin \relax (x )\right )+2\right ) \sin \relax (x ) \]

Solution by Mathematica

Time used: 0.052 (sec). Leaf size: 14

DSolve[{Sin[x]*y'[x]-y[x]*Cos[x]==Sin[2*x],{y[Pi/2]==2}},y[x],x,IncludeSingularSolutions -> True]
 

\begin{align*} y(x)\to 2 \sin (x) (\log (\sin (x))+1) \\ \end{align*}