23.1.321 problem 309

Internal problem ID [4928]
Book : Ordinary differential equations and their solutions. By George Moseley Murphy. 1960
Section : Part II. Chapter 1. THE DIFFERENTIAL EQUATION IS OF FIRST ORDER AND OF FIRST DEGREE, page 223
Problem number : 309
Date solved : Tuesday, September 30, 2025 at 09:00:31 AM
CAS classification : [_separable]

\begin{align*} \left (a^{2}+x^{2}\right ) y^{\prime }&=\left (b +y\right ) \left (x +\sqrt {a^{2}+x^{2}}\right ) \end{align*}
Maple. Time used: 0.002 (sec). Leaf size: 53
ode:=(a^2+x^2)*diff(y(x),x) = (b+y(x))*(x+(a^2+x^2)^(1/2)); 
dsolve(ode,y(x), singsol=all);
 
\[ y = \frac {\left (c_1 \sqrt {a^{2}+x^{2}}\, a^{2}+b x \right ) \left (x \sqrt {a^{2}+x^{2}}+a^{2}+x^{2}\right )}{\sqrt {a^{2}+x^{2}}\, a^{2}} \]
Mathematica. Time used: 0.172 (sec). Leaf size: 81
ode=(a^2+x^2)*D[y[x],x]==(b+y[x])*(x+Sqrt[a^2+x^2]); 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)&\to \frac {\left (x \left (x-\sqrt {a^2+x^2}\right )+a^2\right ) \left (b x-c_1 \sqrt {a^2+x^2}\right )}{\sqrt {a^2+x^2} \left (x-\sqrt {a^2+x^2}\right )^2}\\ y(x)&\to -b \end{align*}
Sympy. Time used: 1.579 (sec). Leaf size: 22
from sympy import * 
x = symbols("x") 
a = symbols("a") 
b = symbols("b") 
y = Function("y") 
ode = Eq((a**2 + x**2)*Derivative(y(x), x) - (b + y(x))*(x + sqrt(a**2 + x**2)),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ y{\left (x \right )} = C_{1} \sqrt {a^{2} + x^{2}} e^{\operatorname {asinh}{\left (\frac {x}{a} \right )}} - b \]