Internal problem ID [4970]
Book: Fundamentals of Differential Equations. By Nagle, Saff and Snider. 9th edition. Boston.
Pearson 2018.
Section: Chapter 2, First order differential equations. Section 2.3, Linear equations. Exercises.
page 54
Problem number: 21.
ODE order: 1.
ODE degree: 1.
CAS Maple gives this as type [_linear]
\[ \boxed {\cos \left (x \right ) y^{\prime }+\sin \left (x \right ) y=2 \cos \left (x \right )^{2} x} \] With initial conditions \begin {align*} \left [y \left (\frac {\pi }{4}\right ) = -\frac {15 \sqrt {2}\, \pi ^{2}}{32}\right ] \end {align*}
✓ Solution by Maple
Time used: 0.015 (sec). Leaf size: 16
dsolve([cos(x)*diff(y(x),x)+y(x)*sin(x)=2*x*cos(x)^2,y(1/4*Pi) = -15/32*2^(1/2)*Pi^2],y(x), singsol=all)
\[ y \left (x \right ) = \left (-\pi ^{2}+x^{2}\right ) \cos \left (x \right ) \]
✓ Solution by Mathematica
Time used: 0.071 (sec). Leaf size: 17
DSolve[{Cos[x]*y'[x]+y[x]*Sin[x]==2*x*Cos[x]^2,{y[Pi/4]==-15*Sqrt[2]*Pi^2/32}},y[x],x,IncludeSingularSolutions -> True]
\[ y(x)\to \left (x^2-\pi ^2\right ) \cos (x) \]