28.1.135 problem 158

Internal problem ID [4441]
Book : Differential equations for engineers by Wei-Chau XIE, Cambridge Press 2010
Section : Chapter 2. First-Order and Simple Higher-Order Differential Equations. Page 78
Problem number : 158
Date solved : Sunday, March 30, 2025 at 03:22:29 AM
CAS classification : [[_homogeneous, `class A`], _dAlembert]

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

Maple. Time used: 0.028 (sec). Leaf size: 32
ode:=x+sin(y(x)/x)^2*(y(x)-x*diff(y(x),x)) = 0; 
dsolve(ode,y(x), singsol=all);
 
\[ \frac {-x \sin \left (\frac {2 y}{x}\right )+2 y}{4 x}-\ln \left (x \right )-c_1 = 0 \]
Mathematica. Time used: 0.37 (sec). Leaf size: 31
ode=x+Sin[y[x]/x]^2*(y[x]-x*D[y[x],x])==0; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\[ \text {Solve}\left [\frac {y(x)}{2 x}-\frac {1}{4} \sin \left (\frac {2 y(x)}{x}\right )=\log (x)+c_1,y(x)\right ] \]
Sympy
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(x + (-x*Derivative(y(x), x) + y(x))*sin(y(x)/x)**2,0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
TypeError : cannot determine truth value of Relational