71.3.14 problem 9

Internal problem ID [14285]
Book : Ordinary Differential Equations by Charles E. Roberts, Jr. CRC Press. 2010
Section : Chapter 2. The Initial Value Problem. Exercises 2.1, page 40
Problem number : 9
Date solved : Wednesday, March 05, 2025 at 10:42:39 PM
CAS classification : [_separable]

\begin{align*} y^{\prime }&=\frac {y}{x} \end{align*}

Maple. Time used: 0.001 (sec). Leaf size: 7
ode:=diff(y(x),x) = y(x)/x; 
dsolve(ode,y(x), singsol=all);
 
\[ y = c_{1} x \]
Mathematica. Time used: 0.022 (sec). Leaf size: 14
ode=D[y[x],x]==y[x]/x; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)\to c_1 x \\ y(x)\to 0 \\ \end{align*}
Sympy. Time used: 0.107 (sec). Leaf size: 5
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(Derivative(y(x), x) - y(x)/x,0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ y{\left (x \right )} = C_{1} x \]