13.2.14 problem 14

Internal problem ID [3543]
Book : Differential equations and linear algebra, Stephen W. Goode, second edition, 2000
Section : 1.6, page 50
Problem number : 14
Date solved : Tuesday, September 30, 2025 at 06:42:01 AM
CAS classification : [_quadrature]

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