40.4.18 problem 19 (t)

Internal problem ID [6658]
Book : Schaums Outline. Theory and problems of Differential Equations, 1st edition. Frank Ayres. McGraw Hill 1952
Section : Chapter 6. Equations of first order and first degree (Linear equations). Supplemetary problems. Page 39
Problem number : 19 (t)
Date solved : Wednesday, March 05, 2025 at 01:35:34 AM
CAS classification : [[_1st_order, `_with_symmetry_[F(x)*G(y),0]`]]

\begin{align*} 1+\sin \left (y\right )&=\left (2 y \cos \left (y\right )-x \left (\sec \left (y\right )+\tan \left (y\right )\right )\right ) y^{\prime } \end{align*}

Maple. Time used: 0.046 (sec). Leaf size: 25
ode:=1+sin(y(x)) = (2*y(x)*cos(y(x))-x*(sec(y(x))+tan(y(x))))*diff(y(x),x); 
dsolve(ode,y(x), singsol=all);
 
\[ x +\frac {-y^{2}-c_1}{\sec \left (y\right )+\tan \left (y\right )} = 0 \]
Mathematica. Time used: 1.095 (sec). Leaf size: 66
ode=(1+Sin[y[x]])==(2*y[x]*Cos[y[x]]-x*(Sec[y[x]]+Tan[y[x]]) )*D[y[x],x]; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)\to -\frac {\pi }{2} \\ y(x)\to \frac {3 \pi }{2} \\ \text {Solve}\left [x&=y(x)^2 e^{-2 \text {arctanh}\left (\tan \left (\frac {y(x)}{2}\right )\right )}+c_1 e^{-2 \text {arctanh}\left (\tan \left (\frac {y(x)}{2}\right )\right )},y(x)\right ] \\ y(x)\to -\frac {\pi }{2} \\ \end{align*}
Sympy
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq((x*(tan(y(x)) + 1/cos(y(x))) - 2*y(x)*cos(y(x)))*Derivative(y(x), x) + sin(y(x)) + 1,0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
Timed Out