74.7.23 problem 23

Internal problem ID [16021]
Book : INTRODUCTORY DIFFERENTIAL EQUATIONS. Martha L. Abell, James P. Braselton. Fourth edition 2014. ElScAe. 2014
Section : Chapter 2. First Order Equations. Exercises 2.5, page 64
Problem number : 23
Date solved : Thursday, March 13, 2025 at 07:16:48 AM
CAS classification : [_linear]

\begin{align*} t -y+t y^{\prime }&=0 \end{align*}

Maple. Time used: 0.001 (sec). Leaf size: 12
ode:=t-y(t)+t*diff(y(t),t) = 0; 
dsolve(ode,y(t), singsol=all);
 
\[ y = \left (-\ln \left (t \right )+c_{1} \right ) t \]
Mathematica. Time used: 0.025 (sec). Leaf size: 14
ode=(t-y[t])+t*D[y[t],t]==0; 
ic={}; 
DSolve[{ode,ic},y[t],t,IncludeSingularSolutions->True]
 
\[ y(t)\to t (-\log (t)+c_1) \]
Sympy. Time used: 0.155 (sec). Leaf size: 8
from sympy import * 
t = symbols("t") 
y = Function("y") 
ode = Eq(t*Derivative(y(t), t) + t - y(t),0) 
ics = {} 
dsolve(ode,func=y(t),ics=ics)
 
\[ y{\left (t \right )} = t \left (C_{1} - \log {\left (t \right )}\right ) \]