85.33.63 problem 64

Internal problem ID [22686]
Book : Applied Differential Equations. By Murray R. Spiegel. 3rd edition. 1980. Pearson. ISBN 978-0130400970
Section : Chapter two. First order and simple higher order ordinary differential equations. A Exercises at page 65
Problem number : 64
Date solved : Thursday, October 02, 2025 at 09:06:31 PM
CAS classification : [[_homogeneous, `class A`], _rational, _Bernoulli]

\begin{align*} y^{\prime }&=\frac {x}{y}+\frac {y}{x} \end{align*}
Maple. Time used: 0.004 (sec). Leaf size: 28
ode:=diff(y(x),x) = x/y(x)+y(x)/x; 
dsolve(ode,y(x), singsol=all);
 
\begin{align*} y &= \sqrt {2 \ln \left (x \right )+c_1}\, x \\ y &= -\sqrt {2 \ln \left (x \right )+c_1}\, x \\ \end{align*}
Mathematica. Time used: 0.109 (sec). Leaf size: 36
ode=D[y[x],{x,1}]==x/y[x]+y[x]/x; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)&\to -x \sqrt {2 \log (x)+c_1}\\ y(x)&\to x \sqrt {2 \log (x)+c_1} \end{align*}
Sympy. Time used: 0.163 (sec). Leaf size: 29
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(-x/y(x) + Derivative(y(x), x) - y(x)/x,0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ \left [ y{\left (x \right )} = - x \sqrt {C_{1} + 2 \log {\left (x \right )}}, \ y{\left (x \right )} = x \sqrt {C_{1} + 2 \log {\left (x \right )}}\right ] \]