74.3.30 problem 25

Internal problem ID [15819]
Book : INTRODUCTORY DIFFERENTIAL EQUATIONS. Martha L. Abell, James P. Braselton. Fourth edition 2014. ElScAe. 2014
Section : Chapter 2. First Order Equations. Exercises 2.1, page 32
Problem number : 25
Date solved : Monday, March 31, 2025 at 01:56:42 PM
CAS classification : [_quadrature]

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

With initial conditions

\begin{align*} y \left (0\right )&={\frac {1}{2}} \end{align*}

Maple. Time used: 0.036 (sec). Leaf size: 11
ode:=diff(y(t),t) = y(t)^2; 
ic:=y(0) = 1/2; 
dsolve([ode,ic],y(t), singsol=all);
 
\[ y = -\frac {1}{t -2} \]
Mathematica. Time used: 0.003 (sec). Leaf size: 12
ode=D[y[t],t]==y[t]^2; 
ic={y[0]==1/2}; 
DSolve[{ode,ic},y[t],t,IncludeSingularSolutions->True]
 
\[ y(t)\to \frac {1}{2-t} \]
Sympy. Time used: 0.140 (sec). Leaf size: 8
from sympy import * 
t = symbols("t") 
y = Function("y") 
ode = Eq(-y(t)**2 + Derivative(y(t), t),0) 
ics = {y(0): 1/2} 
dsolve(ode,func=y(t),ics=ics)
 
\[ y{\left (t \right )} = - \frac {1}{t - 2} \]