15.1.1 problem 1

Internal problem ID [2841]
Book : Differential Equations by Alfred L. Nelson, Karl W. Folley, Max Coral. 3rd ed. DC heath. Boston. 1964
Section : Exercise 5, page 21
Problem number : 1
Date solved : Sunday, March 30, 2025 at 12:33:46 AM
CAS classification : [_separable]

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

Maple. Time used: 0.002 (sec). Leaf size: 13
ode:=x*y(x)+(x^2+1)*diff(y(x),x) = 0; 
dsolve(ode,y(x), singsol=all);
 
\[ y = \frac {c_1}{\sqrt {x^{2}+1}} \]
Mathematica. Time used: 0.031 (sec). Leaf size: 22
ode=x*y[x]+(x^2+1)*D[y[x],x]==0; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)\to \frac {c_1}{\sqrt {x^2+1}} \\ y(x)\to 0 \\ \end{align*}
Sympy. Time used: 0.252 (sec). Leaf size: 12
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(x*y(x) + (x**2 + 1)*Derivative(y(x), x),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ y{\left (x \right )} = \frac {C_{1}}{\sqrt {x^{2} + 1}} \]