30.1.14 problem 14

Internal problem ID [7404]
Book : Fundamentals of Differential Equations. By Nagle, Saff and Snider. 9th edition. Boston. Pearson 2018.
Section : Chapter 2, First order differential equations. Section 2.2, Separable Equations. Exercises. page 46
Problem number : 14
Date solved : Tuesday, September 30, 2025 at 04:31:21 PM
CAS classification : [_quadrature]

\begin{align*} x^{\prime }-x^{3}&=x \end{align*}
Maple. Time used: 0.003 (sec). Leaf size: 29
ode:=diff(x(t),t)-x(t)^3 = x(t); 
dsolve(ode,x(t), singsol=all);
 
\begin{align*} x &= \frac {1}{\sqrt {{\mathrm e}^{-2 t} c_1 -1}} \\ x &= -\frac {1}{\sqrt {{\mathrm e}^{-2 t} c_1 -1}} \\ \end{align*}
Mathematica. Time used: 0.114 (sec). Leaf size: 51
ode=D[x[t],t]-x[t]^3==x[t]; 
ic={}; 
DSolve[{ode,ic},x[t],t,IncludeSingularSolutions->True]
 
\begin{align*} x(t)&\to \text {InverseFunction}\left [\int _1^{\text {$\#$1}}\frac {1}{K[1] \left (K[1]^2+1\right )}dK[1]\&\right ][t+c_1]\\ x(t)&\to 0\\ x(t)&\to -i\\ x(t)&\to i \end{align*}
Sympy. Time used: 0.578 (sec). Leaf size: 36
from sympy import * 
t = symbols("t") 
x = Function("x") 
ode = Eq(-x(t)**3 - x(t) + Derivative(x(t), t),0) 
ics = {} 
dsolve(ode,func=x(t),ics=ics)
 
\[ \left [ x{\left (t \right )} = - \sqrt {\frac {e^{2 t}}{C_{1} - e^{2 t}}}, \ x{\left (t \right )} = \sqrt {\frac {e^{2 t}}{C_{1} - e^{2 t}}}\right ] \]