75.5.1 problem 100

Internal problem ID [16666]
Book : A book of problems in ordinary differential equations. M.L. KRASNOV, A.L. KISELYOV, G.I. MARKARENKO. MIR, MOSCOW. 1983
Section : Section 5. Homogeneous equations. Exercises page 44
Problem number : 100
Date solved : Monday, March 31, 2025 at 03:04:22 PM
CAS classification : [[_homogeneous, `class A`], _dAlembert]

\begin{align*} x y^{\prime }&=y+x \cos \left (\frac {y}{x}\right )^{2} \end{align*}

Maple. Time used: 0.004 (sec). Leaf size: 11
ode:=x*diff(y(x),x) = y(x)+x*cos(y(x)/x)^2; 
dsolve(ode,y(x), singsol=all);
 
\[ y = \arctan \left (\ln \left (x \right )+c_1 \right ) x \]
Mathematica. Time used: 0.426 (sec). Leaf size: 35
ode=x*D[y[x],x]==y[x]+x*Cos[y[x]/x]^2; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)\to x \arctan (\log (x)+2 c_1) \\ y(x)\to -\frac {\pi x}{2} \\ y(x)\to \frac {\pi x}{2} \\ \end{align*}
Sympy
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(-x*cos(y(x)/x)**2 + x*Derivative(y(x), x) - y(x),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
TypeError : cannot determine truth value of Relational