# Solving differential equation

• Mar 25th 2009, 01:34 AM
Craka
Solving differential equation
Trying to solve this differential equation by separating variables. Where c is a constant and K is the carrying capacity. P is population

$\frac{{dP}}{{dt}} = c\ln \left( {\frac{K}{P}} \right)P$

I started with this

$
\begin{array}{l}
\frac{{dP}}{{dt}} = c\ln \left( {\frac{K}{P}} \right)P \\
dP = c\ln \left( {\frac{K}{P}} \right)P.dt \\
\frac{{dP}}{P} = c\left( {\ln (K) - \ln (P)} \right)dt \\
\end{array}
$

than I'm not sure if I can do this.

$
\begin{array}{l}
\frac{{dP}}{P} - c\ln (P) = c\ln K.dt \\
\frac{1}{P} - c\ln (P)dp = c\ln K.dt \\
\end{array}
$

and if it allowed than I'm lost at this point anyhow. I'm really not liking these, I seem lost in the process.
• Mar 25th 2009, 03:09 AM
chisigma
The equation can be written as...

$\frac{dp}{dt}= c\cdot p\cdot (\ln k - \ln p)$ (1)

Separing the variables we obtain...

$\frac {dp}{p\cdot (\ln k - \ln p)}= c\cdot dt$ (2)

... and integrating...

$\int \frac {dp}{p\cdot (\ln k - \ln p)} = -\ln (\ln k - \ln p) = c\cdot t + \ln a$ (3)

... where $a>0$ is a constant. From (3) with little more work...

$\ln \frac{k}{p}= a\cdot e^{- c\cdot t} \rightarrow p= k\cdot e^{-(a\cdot e^{-c\cdot t})}$ (4)

Kind regards

$\chi$ $\sigma$
• Mar 25th 2009, 11:52 PM
Craka
Hi I would you mind going through how you integrated the left hand side of the equation? ie the part $\int {\frac{1}{{P\ln \left( {\frac{K}{P}} \right)}}} dp$ I'm a little confused to what occurred there. Thanks in advance.
• Mar 26th 2009, 12:12 AM
chisigma
Setting $\ln \frac {k}{p}= \ln k - \ln p$ the integral becomes...

$\int \frac {dp}{p\cdot \ln \frac{k}{p}} = \int \frac {dp}{p\cdot (\ln k - \ln p)}$ (1)

Now if you take into account that...

$\frac {d}{dp} (\ln k -\ln p) = - \frac {1}{p}$ (2)

... the integral (1) is...

$\int \frac {dp}{p\cdot (\ln k - \ln p)} = -\ln (\ln k - \ln p) + a$ (3)

... where $a$ is an 'arbitrary constant'...

Kind regards

$\chi$ $\sigma$
• Mar 26th 2009, 01:44 AM
Craka
Sorry, still a little confused, at equation (2).
$\frac {d}{dp} (\ln k -\ln p) = - \frac {1}{p}
$
• Mar 26th 2009, 02:36 AM
chisigma
Since $\ln k$ doesn't depend from $p$ is...

$\frac {d}{dp} (\ln k - \ln p) = - \frac {d}{dp} \ln p= - \frac {1}{p}$

Kind regards

$\chi$ $\sigma$