83.8.31 problem 32

Internal problem ID [19086]
Book : A Text book for differentional equations for postgraduate students by Ray and Chaturvedi. First edition, 1958. BHASKAR press. INDIA
Section : Chapter II. Equations of first order and first degree. Misc examples on chapter II at page 25
Problem number : 32
Date solved : Monday, March 31, 2025 at 06:48:04 PM
CAS classification : [`y=_G(x,y')`]

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

Maple
ode:=sec(y(x))^2*diff(y(x),x)+2*x*tan(y(x)) = x^3; 
dsolve(ode,y(x), singsol=all);
 
\[ \text {No solution found} \]
Mathematica. Time used: 18.467 (sec). Leaf size: 105
ode=Sec[y[x]]^2*D[y[x],x]+2*x*Tan[y[x]]==x^3; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)\to \arctan \left (\frac {1}{2} \left (x^2-8 c_1 e^{-x^2}-1\right )\right ) \\ y(x)\to -\arctan \left (-\frac {x^2}{2}+4 c_1 e^{-x^2}+\frac {1}{2}\right ) \\ y(x)\to -\frac {1}{2} \pi e^{x^2} \sqrt {e^{-2 x^2}} \\ y(x)\to \frac {1}{2} \pi e^{x^2} \sqrt {e^{-2 x^2}} \\ \end{align*}
Sympy
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(-x**3 + 2*x*tan(y(x)) + Derivative(y(x), x)/cos(y(x))**2,0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
NotImplementedError : The given ODE -x*(x**2 - 2*tan(y(x)))*cos(y(x))**2 + Derivative(y(x), x) cannot be solved by the factorable group method