85.33.40 problem 40

Internal problem ID [22663]
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 : 40
Date solved : Thursday, October 02, 2025 at 09:03:17 PM
CAS classification : [_linear]

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