44.5.50 problem 46

Internal problem ID [7112]
Book : A First Course in Differential Equations with Modeling Applications by Dennis G. Zill. 12 ed. Metric version. 2024. Cengage learning.
Section : Chapter 2. First order differential equations. Section 2.2 Separable equations. Exercises 2.2 at page 53
Problem number : 46
Date solved : Sunday, March 30, 2025 at 11:42:47 AM
CAS classification : [_quadrature]

\begin{align*} y^{\prime }&=\left (y-1\right )^{2}-\frac {1}{100} \end{align*}

With initial conditions

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

Maple. Time used: 0.078 (sec). Leaf size: 23
ode:=diff(y(x),x) = (-1+y(x))^2-1/100; 
ic:=y(0) = 1; 
dsolve([ode,ic],y(x), singsol=all);
 
\[ y = \frac {11+9 \,{\mathrm e}^{\frac {x}{5}}}{10 \,{\mathrm e}^{\frac {x}{5}}+10} \]
Mathematica. Time used: 0.009 (sec). Leaf size: 30
ode=D[y[x],x]==(y[x]-1)^2-1/100; 
ic={y[0]==1}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\[ y(x)\to \frac {9 e^{x/5}+11}{10 e^{x/5}+10} \]
Sympy. Time used: 0.335 (sec). Leaf size: 27
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(-(y(x) - 1)**2 + Derivative(y(x), x) + 1/100,0) 
ics = {y(0): 1} 
dsolve(ode,func=y(x),ics=ics)
 
\[ x - 5 \log {\left (y{\left (x \right )} - \frac {11}{10} \right )} + 5 \log {\left (y{\left (x \right )} - \frac {9}{10} \right )} = - 5 i \pi \]