76.4.16 problem 20

Internal problem ID [17339]
Book : Differential equations. An introduction to modern methods and applications. James Brannan, William E. Boyce. Third edition. Wiley 2015
Section : Chapter 2. First order differential equations. Section 2.6 (Exact equations and integrating factors). Problems at page 100
Problem number : 20
Date solved : Monday, March 31, 2025 at 03:55:02 PM
CAS classification : [NONE]

\begin{align*} \frac {\sin \left (y\right )}{y}-2 \,{\mathrm e}^{-x} \sin \left (x \right )+\frac {\left (\cos \left (y\right )+2 \,{\mathrm e}^{-x} \cos \left (x \right )\right ) y^{\prime }}{y}&=0 \end{align*}

Maple. Time used: 0.032 (sec). Leaf size: 17
ode:=sin(y(x))/y(x)-2*exp(-x)*sin(x)+(cos(y(x))+2*exp(-x)*cos(x))/y(x)*diff(y(x),x) = 0; 
dsolve(ode,y(x), singsol=all);
 
\[ \sin \left (y\right ) {\mathrm e}^{x}+2 \cos \left (x \right ) y+c_1 = 0 \]
Mathematica. Time used: 0.155 (sec). Leaf size: 73
ode=(Sin[y[x]]/y[x]-2*Exp[-x]*Sin[x]) + (Cos[y[x]]+2*Exp[-x]*Cos[x])/y[x]*D[y[x],x]==0; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\[ \text {Solve}\left [\int _1^x\left (e^{K[1]} \sin (y(x))-2 \sin (K[1]) y(x)\right )dK[1]+\int _1^{y(x)}\left (2 \cos (x)+e^x \cos (K[2])-\int _1^x\left (e^{K[1]} \cos (K[2])-2 \sin (K[1])\right )dK[1]\right )dK[2]=c_1,y(x)\right ] \]
Sympy
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq((cos(y(x)) + 2*exp(-x)*cos(x))*Derivative(y(x), x)/y(x) - 2*exp(-x)*sin(x) + sin(y(x))/y(x),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
Timed Out