60.1.131 problem 134

Internal problem ID [10145]
Book : Differential Gleichungen, E. Kamke, 3rd ed. Chelsea Pub. NY, 1948
Section : Chapter 1, linear first order
Problem number : 134
Date solved : Wednesday, March 05, 2025 at 08:33:35 AM
CAS classification : [_linear]

\begin{align*} x^{2} y^{\prime }-y+x^{2} {\mathrm e}^{x -\frac {1}{x}}&=0 \end{align*}

Maple. Time used: 0.001 (sec). Leaf size: 17
ode:=x^2*diff(y(x),x)-y(x)+x^2*exp(x-1/x) = 0; 
dsolve(ode,y(x), singsol=all);
 
\[ y = \left (-{\mathrm e}^{x}+c_{1} \right ) {\mathrm e}^{-\frac {1}{x}} \]
Mathematica. Time used: 0.076 (sec). Leaf size: 21
ode=x^2*D[y[x],x] - y[x] + x^2*Exp[x-1/x]==0; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\[ y(x)\to e^{-1/x} \left (-e^x+c_1\right ) \]
Sympy. Time used: 0.327 (sec). Leaf size: 15
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(x**2*exp(x - 1/x) + x**2*Derivative(y(x), x) - y(x),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ y{\left (x \right )} = C_{1} e^{- \frac {1}{x}} - e^{x - \frac {1}{x}} \]