27.1.6 problem 6

Internal problem ID [4300]
Book : An introduction to the solution and applications of differential equations, J.W. Searl, 1966
Section : Chapter 4, Ex. 4.1
Problem number : 6
Date solved : Tuesday, March 04, 2025 at 06:10:03 PM
CAS classification : [[_homogeneous, `class A`], _exact, _rational, _dAlembert]

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

With initial conditions

\begin{align*} y \left (1\right )&=0 \end{align*}

Maple. Time used: 0.335 (sec). Leaf size: 33
ode:=x/(x^2+y(x)^2)+y(x)/x^2+(y(x)/(x^2+y(x)^2)-1/x)*diff(y(x),x) = 0; 
ic:=y(1) = 0; 
dsolve([ode,ic],y(x), singsol=all);
 
\[ y \left (x \right ) = \frac {x \left (2 \ln \left (x \right )+\operatorname {RootOf}\left (4+4 \ln \left (x \right )^{2}+4 \ln \left (x \right ) \textit {\_Z} +\textit {\_Z}^{2}-4 \,{\mathrm e}^{\textit {\_Z}}\right )\right )}{2} \]
Mathematica. Time used: 0.172 (sec). Leaf size: 28
ode=(x/(x^2+y[x]^2)+y[x]/x^2)+(y[x]/(x^2+y[x]^2)-1/x)*D[y[x],x]==0; 
ic=y[1]==0; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\[ \text {Solve}\left [\frac {y(x)}{x}-\frac {1}{2} \log \left (\frac {y(x)^2}{x^2}+1\right )=\log (x),y(x)\right ] \]
Sympy. Time used: 2.107 (sec). Leaf size: 22
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(x/(x**2 + y(x)**2) + (y(x)/(x**2 + y(x)**2) - 1/x)*Derivative(y(x), x) + y(x)/x**2,0) 
ics = {y(1): 0} 
dsolve(ode,func=y(x),ics=ics)
 
\[ \log {\left (x \right )} = - \log {\left (\sqrt {1 + \frac {y^{2}{\left (x \right )}}{x^{2}}} \right )} + \frac {y{\left (x \right )}}{x} \]