2.1.33 problem 34

Existence and uniqueness analysis
Solved as first order autonomous ode
Solved as first order Bernoulli ode
Solved as first order Exact ode
Solved using Lie symmetry for first order ode
Maple step by step solution
Maple trace
Maple dsolve solution
Mathematica DSolve solution

Internal problem ID [8171]
Book : Own collection of miscellaneous problems
Section : section 1.0
Problem number : 34
Date solved : Sunday, November 10, 2024 at 08:19:58 PM
CAS classification : [_quadrature]

Solve

\begin{align*} p^{\prime }&=a p-b p^{2} \end{align*}

With initial conditions

\begin{align*} p \left (\operatorname {t0} \right )&=\operatorname {p0} \end{align*}

Existence and uniqueness analysis

This is non linear first order ODE. In canonical form it is written as

\begin{align*} p^{\prime } &= f(t,p)\\ &= -b \,p^{2}+a p \end{align*}

The \(p\) domain of \(f(t,p)\) when \(t=\operatorname {t0}\) is

\[ \{-\infty <p <\infty \} \]

But the point \(p_0 = \operatorname {p0}\) is not inside this domain. Hence existence and uniqueness theorem does not apply. There could be infinite number of solutions, or one solution or no solution at all.

Solved as first order autonomous ode

Time used: 0.665 (sec)

Integrating gives

\begin{align*} \int \frac {1}{-b \,p^{2}+a p}d p &= dt\\ \frac {-\ln \left (b p -a \right )+\ln \left (p \right )}{a}&= t +c_1 \end{align*}

The following diagram is the phase line diagram. It classifies each of the above equilibrium points as stable or not stable or semi-stable.

Solving for the constant of integration from initial conditions, the solution becomes

\begin{align*} \frac {-\ln \left (b p-a \right )+\ln \left (p\right )}{a} = t +\frac {-\operatorname {t0} a -\ln \left (\operatorname {p0} b -a \right )+\ln \left (\operatorname {p0} \right )}{a} \end{align*}

Solving for \(p\) gives

\begin{align*} p &= \frac {a \operatorname {p0}}{-{\mathrm e}^{-t a +\operatorname {t0} a} b \operatorname {p0} +{\mathrm e}^{-t a +\operatorname {t0} a} a +\operatorname {p0} b} \\ \end{align*}

Summary of solutions found

\begin{align*} p &= \frac {a \operatorname {p0}}{-{\mathrm e}^{-t a +\operatorname {t0} a} b \operatorname {p0} +{\mathrm e}^{-t a +\operatorname {t0} a} a +\operatorname {p0} b} \\ \end{align*}
Solved as first order Bernoulli ode

Time used: 0.280 (sec)

In canonical form, the ODE is

\begin{align*} p' &= F(t,p)\\ &= -b \,p^{2}+a p \end{align*}

This is a Bernoulli ODE.

\[ p' = \left (a\right ) p + \left (-b\right )p^{2} \tag {1} \]

The standard Bernoulli ODE has the form

\[ p' = f_0(t)p+f_1(t)p^n \tag {2} \]

Comparing this to (1) shows that

\begin{align*} f_0 &=a\\ f_1 &=-b \end{align*}

The first step is to divide the above equation by \(p^n \) which gives

\[ \frac {p'}{p^n} = f_0(t) p^{1-n} +f_1(t) \tag {3} \]

The next step is use the substitution \(v = p^{1-n}\) in equation (3) which generates a new ODE in \(v \left (t \right )\) which will be linear and can be easily solved using an integrating factor. Backsubstitution then gives the solution \(p(t)\) which is what we want.

This method is now applied to the ODE at hand. Comparing the ODE (1) With (2) Shows that

\begin{align*} f_0(t)&=a\\ f_1(t)&=-b\\ n &=2 \end{align*}

Dividing both sides of ODE (1) by \(p^n=p^{2}\) gives

\begin{align*} p'\frac {1}{p^{2}} &= \frac {a}{p} -b \tag {4} \end{align*}

Let

\begin{align*} v &= p^{1-n} \\ &= \frac {1}{p} \tag {5} \end{align*}

Taking derivative of equation (5) w.r.t \(t\) gives

\begin{align*} v' &= -\frac {1}{p^{2}}p' \tag {6} \end{align*}

Substituting equations (5) and (6) into equation (4) gives

\begin{align*} -v^{\prime }\left (t \right )&= a v \left (t \right )-b\\ v' &= -a v +b \tag {7} \end{align*}

The above now is a linear ODE in \(v \left (t \right )\) which is now solved.

Integrating gives

\begin{align*} \int \frac {1}{-a v +b}d v &= dt\\ -\frac {\ln \left (a v -b \right )}{a}&= t +c_1 \end{align*}

Singular solutions are found by solving

\begin{align*} -a v +b&= 0 \end{align*}

for \(v \left (t \right )\). This is because we had to divide by this in the above step. This gives the following singular solution(s), which also have to satisfy the given ODE.

\begin{align*} v \left (t \right ) = \frac {b}{a} \end{align*}

Solving for \(v \left (t \right )\) gives

\begin{align*} v \left (t \right ) &= \frac {{\mathrm e}^{-c_1 a -t a}+b}{a} \\ \end{align*}

The substitution \(v = p^{1-n}\) is now used to convert the above solution back to \(p\) which results in

\[ \frac {1}{p} = \frac {b}{a} \]
\[ \frac {1}{p} = \frac {{\mathrm e}^{-c_1 a -t a}+b}{a} \]

Solving for the constant of integration from initial conditions, the solution becomes

\begin{align*} \frac {1}{p} = \frac {{\mathrm e}^{\operatorname {t0} a +\ln \left (\frac {-\operatorname {p0} b +a}{\operatorname {p0}}\right )-t a}+b}{a} \end{align*}

Solving for \(p\) gives

\begin{align*} p &= \frac {a}{{\mathrm e}^{\operatorname {t0} a +\ln \left (\frac {-\operatorname {p0} b +a}{\operatorname {p0}}\right )-t a}+b} \\ \end{align*}

The solution

\[ \frac {1}{p} = \frac {b}{a} \]

was found not to satisfy the ode or the IC. Hence it is removed.

Summary of solutions found

\begin{align*} p &= \frac {a}{{\mathrm e}^{\operatorname {t0} a +\ln \left (\frac {-\operatorname {p0} b +a}{\operatorname {p0}}\right )-t a}+b} \\ \end{align*}
Solved as first order Exact ode

Time used: 0.181 (sec)

To solve an ode of the form

\begin{equation} M\left ( x,y\right ) +N\left ( x,y\right ) \frac {dy}{dx}=0\tag {A}\end{equation}

We assume there exists a function \(\phi \left ( x,y\right ) =c\) where \(c\) is constant, that satisfies the ode. Taking derivative of \(\phi \) w.r.t. \(x\) gives

\[ \frac {d}{dx}\phi \left ( x,y\right ) =0 \]

Hence

\begin{equation} \frac {\partial \phi }{\partial x}+\frac {\partial \phi }{\partial y}\frac {dy}{dx}=0\tag {B}\end{equation}

Comparing (A,B) shows that

\begin{align*} \frac {\partial \phi }{\partial x} & =M\\ \frac {\partial \phi }{\partial y} & =N \end{align*}

But since \(\frac {\partial ^{2}\phi }{\partial x\partial y}=\frac {\partial ^{2}\phi }{\partial y\partial x}\) then for the above to be valid, we require that

\[ \frac {\partial M}{\partial y}=\frac {\partial N}{\partial x}\]

If the above condition is satisfied, then the original ode is called exact. We still need to determine \(\phi \left ( x,y\right ) \) but at least we know now that we can do that since the condition \(\frac {\partial ^{2}\phi }{\partial x\partial y}=\frac {\partial ^{2}\phi }{\partial y\partial x}\) is satisfied. If this condition is not satisfied then this method will not work and we have to now look for an integrating factor to force this condition, which might or might not exist. The first step is to write the ODE in standard form to check for exactness, which is

\[ M(t,p) \mathop {\mathrm {d}t}+ N(t,p) \mathop {\mathrm {d}p}=0 \tag {1A} \]

Therefore

\begin{align*} \mathop {\mathrm {d}p} &= \left (-b \,p^{2}+a p\right )\mathop {\mathrm {d}t}\\ \left (b \,p^{2}-a p\right ) \mathop {\mathrm {d}t} + \mathop {\mathrm {d}p} &= 0 \tag {2A} \end{align*}

Comparing (1A) and (2A) shows that

\begin{align*} M(t,p) &= b \,p^{2}-a p\\ N(t,p) &= 1 \end{align*}

The next step is to determine if the ODE is is exact or not. The ODE is exact when the following condition is satisfied

\[ \frac {\partial M}{\partial p} = \frac {\partial N}{\partial t} \]

Using result found above gives

\begin{align*} \frac {\partial M}{\partial p} &= \frac {\partial }{\partial p} \left (b \,p^{2}-a p\right )\\ &= 2 b p -a \end{align*}

And

\begin{align*} \frac {\partial N}{\partial t} &= \frac {\partial }{\partial t} \left (1\right )\\ &= 0 \end{align*}

Since \(\frac {\partial M}{\partial p} \neq \frac {\partial N}{\partial t}\), then the ODE is not exact. Since the ODE is not exact, we will try to find an integrating factor to make it exact. Let

\begin{align*} A &= \frac {1}{N} \left (\frac {\partial M}{\partial p} - \frac {\partial N}{\partial t} \right ) \\ &=1\left ( \left ( 2 b p -a\right ) - \left (0 \right ) \right ) \\ &=2 b p -a \end{align*}

Since \(A\) depends on \(p\), it can not be used to obtain an integrating factor. We will now try a second method to find an integrating factor. Let

\begin{align*} B &= \frac {1}{M} \left ( \frac {\partial N}{\partial t} - \frac {\partial M}{\partial p} \right ) \\ &=-\frac {1}{p \left (-b p +a \right )}\left ( \left ( 0\right ) - \left (2 b p -a \right ) \right ) \\ &=\frac {2 b p -a}{p \left (-b p +a \right )} \end{align*}

Since \(B\) does not depend on \(t\), it can be used to obtain an integrating factor. Let the integrating factor be \(\mu \). Then

\begin{align*} \mu &= e^{\int B \mathop {\mathrm {d}p}} \\ &= e^{\int \frac {2 b p -a}{p \left (-b p +a \right )}\mathop {\mathrm {d}p} } \end{align*}

The result of integrating gives

\begin{align*} \mu &= e^{-\ln \left (p \left (b p -a \right )\right ) } \\ &= \frac {1}{p \left (b p -a \right )} \end{align*}

\(M\) and \(N\) are now multiplied by this integrating factor, giving new \(M\) and new \(N\) which are called \(\overline {M}\) and \(\overline {N}\) so not to confuse them with the original \(M\) and \(N\).

\begin{align*} \overline {M} &=\mu M \\ &= \frac {1}{p \left (b p -a \right )}\left (b \,p^{2}-a p\right ) \\ &= 1 \end{align*}

And

\begin{align*} \overline {N} &=\mu N \\ &= \frac {1}{p \left (b p -a \right )}\left (1\right ) \\ &= \frac {1}{p \left (b p -a \right )} \end{align*}

So now a modified ODE is obtained from the original ODE which will be exact and can be solved using the standard method. The modified ODE is

\begin{align*} \overline {M} + \overline {N} \frac { \mathop {\mathrm {d}p}}{\mathop {\mathrm {d}t}} &= 0 \\ \left (1\right ) + \left (\frac {1}{p \left (b p -a \right )}\right ) \frac { \mathop {\mathrm {d}p}}{\mathop {\mathrm {d}t}} &= 0 \end{align*}

The following equations are now set up to solve for the function \(\phi \left (t,p\right )\)

\begin{align*} \frac {\partial \phi }{\partial t } &= \overline {M}\tag {1} \\ \frac {\partial \phi }{\partial p } &= \overline {N}\tag {2} \end{align*}

Integrating (1) w.r.t. \(t\) gives

\begin{align*} \int \frac {\partial \phi }{\partial t} \mathop {\mathrm {d}t} &= \int \overline {M}\mathop {\mathrm {d}t} \\ \int \frac {\partial \phi }{\partial t} \mathop {\mathrm {d}t} &= \int 1\mathop {\mathrm {d}t} \\ \tag{3} \phi &= t+ f(p) \\ \end{align*}

Where \(f(p)\) is used for the constant of integration since \(\phi \) is a function of both \(t\) and \(p\). Taking derivative of equation (3) w.r.t \(p\) gives

\begin{equation} \tag{4} \frac {\partial \phi }{\partial p} = 0+f'(p) \end{equation}

But equation (2) says that \(\frac {\partial \phi }{\partial p} = \frac {1}{p \left (b p -a \right )}\). Therefore equation (4) becomes

\begin{equation} \tag{5} \frac {1}{p \left (b p -a \right )} = 0+f'(p) \end{equation}

Solving equation (5) for \( f'(p)\) gives

\[ f'(p) = -\frac {1}{p \left (-b p +a \right )} \]

Integrating the above w.r.t \(p\) gives

\begin{align*} \int f'(p) \mathop {\mathrm {d}p} &= \int \left ( -\frac {1}{p \left (-b p +a \right )}\right ) \mathop {\mathrm {d}p} \\ f(p) &= \frac {\ln \left (b p -a \right )}{a}-\frac {\ln \left (p \right )}{a}+ c_1 \\ \end{align*}

Where \(c_1\) is constant of integration. Substituting result found above for \(f(p)\) into equation (3) gives \(\phi \)

\[ \phi = t +\frac {\ln \left (b p -a \right )}{a}-\frac {\ln \left (p \right )}{a}+ c_1 \]

But since \(\phi \) itself is a constant function, then let \(\phi =c_2\) where \(c_2\) is new constant and combining \(c_1\) and \(c_2\) constants into the constant \(c_1\) gives the solution as

\[ c_1 = t +\frac {\ln \left (b p -a \right )}{a}-\frac {\ln \left (p \right )}{a} \]

Solving for the constant of integration from initial conditions, the solution becomes

\begin{align*} t +\frac {\ln \left (b p-a \right )}{a}-\frac {\ln \left (p\right )}{a} = \frac {\operatorname {t0} a +\ln \left (\operatorname {p0} b -a \right )-\ln \left (\operatorname {p0} \right )}{a} \end{align*}

Solving for \(p\) gives

\begin{align*} p &= \frac {a \operatorname {p0}}{-{\mathrm e}^{-t a +\operatorname {t0} a} b \operatorname {p0} +{\mathrm e}^{-t a +\operatorname {t0} a} a +\operatorname {p0} b} \\ \end{align*}

Summary of solutions found

\begin{align*} p &= \frac {a \operatorname {p0}}{-{\mathrm e}^{-t a +\operatorname {t0} a} b \operatorname {p0} +{\mathrm e}^{-t a +\operatorname {t0} a} a +\operatorname {p0} b} \\ \end{align*}
Solved using Lie symmetry for first order ode

Time used: 0.551 (sec)

Writing the ode as

\begin{align*} p^{\prime }&=-b \,p^{2}+a p\\ p^{\prime }&= \omega \left ( t,p\right ) \end{align*}

The condition of Lie symmetry is the linearized PDE given by

\begin{align*} \eta _{t}+\omega \left ( \eta _{p}-\xi _{t}\right ) -\omega ^{2}\xi _{p}-\omega _{t}\xi -\omega _{p}\eta =0\tag {A} \end{align*}

To determine \(\xi ,\eta \) then (A) is solved using ansatz. Making bivariate polynomials of degree 1 to use as anstaz gives

\begin{align*} \tag{1E} \xi &= p a_{3}+t a_{2}+a_{1} \\ \tag{2E} \eta &= p b_{3}+t b_{2}+b_{1} \\ \end{align*}

Where the unknown coefficients are

\[ \{a_{1}, a_{2}, a_{3}, b_{1}, b_{2}, b_{3}\} \]

Substituting equations (1E,2E) and \(\omega \) into (A) gives

\begin{equation} \tag{5E} b_{2}+\left (-b \,p^{2}+a p \right ) \left (b_{3}-a_{2}\right )-\left (-b \,p^{2}+a p \right )^{2} a_{3}-\left (-2 b p +a \right ) \left (p b_{3}+t b_{2}+b_{1}\right ) = 0 \end{equation}

Putting the above in normal form gives

\[ -b^{2} p^{4} a_{3}+2 a b \,p^{3} a_{3}-a^{2} p^{2} a_{3}+b \,p^{2} a_{2}+b \,p^{2} b_{3}+2 b p t b_{2}-a p a_{2}-a t b_{2}+2 b p b_{1}-a b_{1}+b_{2} = 0 \]

Setting the numerator to zero gives

\begin{equation} \tag{6E} -b^{2} p^{4} a_{3}+2 a b \,p^{3} a_{3}-a^{2} p^{2} a_{3}+b \,p^{2} a_{2}+b \,p^{2} b_{3}+2 b p t b_{2}-a p a_{2}-a t b_{2}+2 b p b_{1}-a b_{1}+b_{2} = 0 \end{equation}

Looking at the above PDE shows the following are all the terms with \(\{p, t\}\) in them.

\[ \{p, t\} \]

The following substitution is now made to be able to collect on all terms with \(\{p, t\}\) in them

\[ \{p = v_{1}, t = v_{2}\} \]

The above PDE (6E) now becomes

\begin{equation} \tag{7E} -b^{2} a_{3} v_{1}^{4}+2 a b a_{3} v_{1}^{3}-a^{2} a_{3} v_{1}^{2}+b a_{2} v_{1}^{2}+2 b b_{2} v_{1} v_{2}+b b_{3} v_{1}^{2}-a a_{2} v_{1}-a b_{2} v_{2}+2 b b_{1} v_{1}-a b_{1}+b_{2} = 0 \end{equation}

Collecting the above on the terms \(v_i\) introduced, and these are

\[ \{v_{1}, v_{2}\} \]

Equation (7E) now becomes

\begin{equation} \tag{8E} -b^{2} a_{3} v_{1}^{4}+2 a b a_{3} v_{1}^{3}+\left (-a^{2} a_{3}+b a_{2}+b b_{3}\right ) v_{1}^{2}+2 b b_{2} v_{1} v_{2}+\left (-a a_{2}+2 b b_{1}\right ) v_{1}-a b_{2} v_{2}-a b_{1}+b_{2} = 0 \end{equation}

Setting each coefficients in (8E) to zero gives the following equations to solve

\begin{align*} -a b_{2}&=0\\ 2 b b_{2}&=0\\ -b^{2} a_{3}&=0\\ 2 a b a_{3}&=0\\ -a b_{1}+b_{2}&=0\\ -a a_{2}+2 b b_{1}&=0\\ -a^{2} a_{3}+b a_{2}+b b_{3}&=0 \end{align*}

Solving the above equations for the unknowns gives

\begin{align*} a_{1}&=a_{1}\\ a_{2}&=0\\ a_{3}&=0\\ b_{1}&=0\\ b_{2}&=0\\ b_{3}&=0 \end{align*}

Substituting the above solution in the anstaz (1E,2E) (using \(1\) as arbitrary value for any unknown in the RHS) gives

\begin{align*} \xi &= 1 \\ \eta &= 0 \\ \end{align*}

Shifting is now applied to make \(\xi =0\) in order to simplify the rest of the computation

\begin{align*} \eta &= \eta - \omega \left (t,p\right ) \xi \\ &= 0 - \left (-b \,p^{2}+a p\right ) \left (1\right ) \\ &= b \,p^{2}-a p\\ \xi &= 0 \end{align*}

The next step is to determine the canonical coordinates \(R,S\). The canonical coordinates map \(\left ( t,p\right ) \to \left ( R,S \right )\) where \(\left ( R,S \right )\) are the canonical coordinates which make the original ode become a quadrature and hence solved by integration.

The characteristic pde which is used to find the canonical coordinates is

\begin{align*} \frac {d t}{\xi } &= \frac {d p}{\eta } = dS \tag {1} \end{align*}

The above comes from the requirements that \(\left ( \xi \frac {\partial }{\partial t} + \eta \frac {\partial }{\partial p}\right ) S(t,p) = 1\). Starting with the first pair of ode’s in (1) gives an ode to solve for the independent variable \(R\) in the canonical coordinates, where \(S(R)\). Since \(\xi =0\) then in this special case

\begin{align*} R = t \end{align*}

\(S\) is found from

\begin{align*} S &= \int { \frac {1}{\eta }} dy\\ &= \int { \frac {1}{b \,p^{2}-a p}} dy \end{align*}

Which results in

\begin{align*} S&= \frac {\ln \left (b p -a \right )}{a}-\frac {\ln \left (p \right )}{a} \end{align*}

Now that \(R,S\) are found, we need to setup the ode in these coordinates. This is done by evaluating

\begin{align*} \frac {dS}{dR} &= \frac { S_{t} + \omega (t,p) S_{p} }{ R_{t} + \omega (t,p) R_{p} }\tag {2} \end{align*}

Where in the above \(R_{t},R_{p},S_{t},S_{p}\) are all partial derivatives and \(\omega (t,p)\) is the right hand side of the original ode given by

\begin{align*} \omega (t,p) &= -b \,p^{2}+a p \end{align*}

Evaluating all the partial derivatives gives

\begin{align*} R_{t} &= 1\\ R_{p} &= 0\\ S_{t} &= 0\\ S_{p} &= -\frac {1}{p \left (-b p +a \right )} \end{align*}

Substituting all the above in (2) and simplifying gives the ode in canonical coordinates.

\begin{align*} \frac {dS}{dR} &= -1\tag {2A} \end{align*}

We now need to express the RHS as function of \(R\) only. This is done by solving for \(t,p\) in terms of \(R,S\) from the result obtained earlier and simplifying. This gives

\begin{align*} \frac {dS}{dR} &= -1 \end{align*}

The above is a quadrature ode. This is the whole point of Lie symmetry method. It converts an ode, no matter how complicated it is, to one that can be solved by integration when the ode is in the canonical coordiates \(R,S\).

Since the ode has the form \(\frac {d}{d R}S \left (R \right )=f(R)\), then we only need to integrate \(f(R)\).

\begin{align*} \int {dS} &= \int {-1\, dR}\\ S \left (R \right ) &= -R + c_2 \end{align*}

To complete the solution, we just need to transform the above back to \(t,p\) coordinates. This results in

\begin{align*} \frac {\ln \left (b p-a \right )-\ln \left (p\right )}{a} = -t +c_2 \end{align*}

Which gives

\begin{align*} p = -\frac {a}{{\mathrm e}^{c_2 a -t a}-b} \end{align*}

Solving for the constant of integration from initial conditions, the solution becomes

\begin{align*} p = -\frac {a}{{\mathrm e}^{\operatorname {t0} a +\ln \left (\frac {\operatorname {p0} b -a}{\operatorname {p0}}\right )-t a}-b} \end{align*}

Summary of solutions found

\begin{align*} p &= -\frac {a}{{\mathrm e}^{\operatorname {t0} a +\ln \left (\frac {\operatorname {p0} b -a}{\operatorname {p0}}\right )-t a}-b} \\ \end{align*}

Maple step by step solution
\[ \begin {array}{lll} & {} & \textrm {Let's solve}\hspace {3pt} \\ {} & {} & \left [\frac {d}{d t}p \left (t \right )=a p \left (t \right )-b p \left (t \right )^{2}, p \left (\mathit {t0} \right )=\mathit {p0} \right ] \\ \bullet & {} & \textrm {Highest derivative means the order of the ODE is}\hspace {3pt} 1 \\ {} & {} & \frac {d}{d t}p \left (t \right ) \\ \bullet & {} & \textrm {Solve for the highest derivative}\hspace {3pt} \\ {} & {} & \frac {d}{d t}p \left (t \right )=a p \left (t \right )-b p \left (t \right )^{2} \\ \bullet & {} & \textrm {Separate variables}\hspace {3pt} \\ {} & {} & \frac {\frac {d}{d t}p \left (t \right )}{a p \left (t \right )-b p \left (t \right )^{2}}=1 \\ \bullet & {} & \textrm {Integrate both sides with respect to}\hspace {3pt} t \\ {} & {} & \int \frac {\frac {d}{d t}p \left (t \right )}{a p \left (t \right )-b p \left (t \right )^{2}}d t =\int 1d t +\mathit {C1} \\ \bullet & {} & \textrm {Evaluate integral}\hspace {3pt} \\ {} & {} & -\frac {\ln \left (p \left (t \right ) b -a \right )}{a}+\frac {\ln \left (p \left (t \right )\right )}{a}=t +\mathit {C1} \\ \bullet & {} & \textrm {Solve for}\hspace {3pt} p \left (t \right ) \\ {} & {} & p \left (t \right )=\frac {{\mathrm e}^{\mathit {C1} a +t a} a}{-1+{\mathrm e}^{\mathit {C1} a +t a} b} \\ \bullet & {} & \textrm {Use initial condition}\hspace {3pt} p \left (\mathit {t0} \right )=\mathit {p0} \\ {} & {} & \mathit {p0} =\frac {{\mathrm e}^{\mathit {C1} a +a \mathit {t0}} a}{-1+{\mathrm e}^{\mathit {C1} a +a \mathit {t0}} b} \\ \bullet & {} & \textrm {Solve for}\hspace {3pt} \textit {\_C1} \\ {} & {} & \mathit {C1} =\frac {-a \mathit {t0} +\ln \left (-\frac {\mathit {p0}}{-b \mathit {p0} +a}\right )}{a} \\ \bullet & {} & \textrm {Substitute}\hspace {3pt} \textit {\_C1} =\frac {-a \mathit {t0} +\ln \left (-\frac {\mathit {p0}}{-b \mathit {p0} +a}\right )}{a}\hspace {3pt}\textrm {into general solution and simplify}\hspace {3pt} \\ {} & {} & p \left (t \right )=\frac {a \,{\mathrm e}^{a \left (t -\mathit {t0} \right )} \mathit {p0}}{\mathit {p0} \,{\mathrm e}^{a \left (t -\mathit {t0} \right )} b -b \mathit {p0} +a} \\ \bullet & {} & \textrm {Solution to the IVP}\hspace {3pt} \\ {} & {} & p \left (t \right )=\frac {a \,{\mathrm e}^{a \left (t -\mathit {t0} \right )} \mathit {p0}}{\mathit {p0} \,{\mathrm e}^{a \left (t -\mathit {t0} \right )} b -b \mathit {p0} +a} \end {array} \]

Maple trace
`Methods for first order ODEs: 
--- Trying classification methods --- 
trying a quadrature 
trying 1st order linear 
trying Bernoulli 
<- Bernoulli successful`
 
Maple dsolve solution

Solving time : 0.073 (sec)
Leaf size : 29

dsolve([diff(p(t),t) = a*p(t)-b*p(t)^2, 
       op([p(t0) = p0])],p(t),singsol=all)
 
\[ p = \frac {a \operatorname {p0}}{\left (-\operatorname {p0} b +a \right ) {\mathrm e}^{-a \left (t -\operatorname {t0} \right )}+\operatorname {p0} b} \]
Mathematica DSolve solution

Solving time : 0.801 (sec)
Leaf size : 39

DSolve[{D[p[t],t]==a*p[t]-b*p[t]^2,p[t0]==p0}, 
       p[t],t,IncludeSingularSolutions->True]
 
\[ p(t)\to \frac {a \text {p0} e^{a t}}{b \text {p0} \left (e^{a t}-e^{a \text {t0}}\right )+a e^{a \text {t0}}} \]