76.10.19 problem 19

Internal problem ID [17470]
Book : Differential equations. An introduction to modern methods and applications. James Brannan, William E. Boyce. Third edition. Wiley 2015
Section : Chapter 3. Systems of two first order equations. Section 3.6 (A brief introduction to nonlinear systems). Problems at page 195
Problem number : 19
Date solved : Monday, March 31, 2025 at 04:14:29 PM
CAS classification : system_of_ODEs

\begin{align*} \frac {d}{d t}x \left (t \right )&=-x \left (t \right )+2 x \left (t \right ) y \left (t \right )\\ \frac {d}{d t}y \left (t \right )&=y \left (t \right )-x \left (t \right )^{2}-y \left (t \right )^{2} \end{align*}

Maple. Time used: 0.240 (sec). Leaf size: 104
ode:=[diff(x(t),t) = -x(t)+2*x(t)*y(t), diff(y(t),t) = y(t)-x(t)^2-y(t)^2]; 
dsolve(ode);
 
\begin{align*} \left [\{x \left (t \right ) = 0\}, \left \{y \left (t \right ) &= \frac {1}{1+{\mathrm e}^{-t} c_1}\right \}\right ] \\ \left [\left \{x \left (t \right ) &= \operatorname {RootOf}\left (-\int _{}^{\textit {\_Z}}-\frac {3}{\sqrt {-12 \textit {\_a}^{4}+9 \textit {\_a} c_1 +9 \textit {\_a}^{2}}}d \textit {\_a} +t +c_2 \right ), x \left (t \right ) = \operatorname {RootOf}\left (-\int _{}^{\textit {\_Z}}\frac {3}{\sqrt {-12 \textit {\_a}^{4}+9 \textit {\_a} c_1 +9 \textit {\_a}^{2}}}d \textit {\_a} +t +c_2 \right )\right \}, \left \{y \left (t \right ) = \frac {\frac {d}{d t}x \left (t \right )+x \left (t \right )}{2 x \left (t \right )}\right \}\right ] \\ \end{align*}
Mathematica. Time used: 1.215 (sec). Leaf size: 995
ode={D[x[t],t]==-x[t]+2*x[t]*y[t],D[y[t],t]==y[t]-x[t]^2-y[t]^2}; 
ic={}; 
DSolve[{ode,ic},{x[t],y[t]},t,IncludeSingularSolutions->True]
 
\begin{align*} \text {Solution too large to show}\end{align*}

Sympy
from sympy import * 
t = symbols("t") 
x = Function("x") 
y = Function("y") 
ode=[Eq(-2*x(t)*y(t) + x(t) + Derivative(x(t), t),0),Eq(x(t)**2 + y(t)**2 - y(t) + Derivative(y(t), t),0)] 
ics = {} 
dsolve(ode,func=[x(t),y(t)],ics=ics)