85.18.6 problem 1 (f)

Internal problem ID [22552]
Book : Applied Differential Equations. By Murray R. Spiegel. 3rd edition. 1980. Pearson. ISBN 978-0130400970
Section : Chapter two. First order and simple higher order ordinary differential equations. A Exercises at page 52
Problem number : 1 (f)
Date solved : Thursday, October 02, 2025 at 08:50:30 PM
CAS classification : [_linear]

\begin{align*} 2 y \sin \left (x \right )-\cos \left (x \right )^{3}+\cos \left (x \right ) y^{\prime }&=0 \end{align*}
Maple. Time used: 0.001 (sec). Leaf size: 15
ode:=2*y(x)*sin(x)-cos(x)^3+cos(x)*diff(y(x),x) = 0; 
dsolve(ode,y(x), singsol=all);
 
\[ y = \frac {\left (x +c_1 \right ) \left (1+\cos \left (2 x \right )\right )}{2} \]
Mathematica. Time used: 0.025 (sec). Leaf size: 14
ode=(2*y[x]*Sin[x]-Cos[x]^3)+Cos[x]*D[y[x],x]== 0; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)&\to (x+c_1) \cos ^2(x) \end{align*}
Sympy. Time used: 0.362 (sec). Leaf size: 10
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(2*y(x)*sin(x) - cos(x)**3 + cos(x)*Derivative(y(x), x),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ y{\left (x \right )} = \left (C_{1} + x\right ) \cos ^{2}{\left (x \right )} \]