# Complex differential equations to find functions [TRIED]

1. Apr 24, 2013

### NZBRU

1. The problem statement, all variables and given/known data

I need to solve two differential equations to find a population function P(t). I am able to do this with problems like newtons law of cooling:

dT/dt=-k(T-Ta) solves to:
dT=-k(T-Ta) dt
∫1/(T-Ta)dT=∫-k dt
Ln(T-Ta)=-kt
e-kt=T-Ta
T=Ta+E-kt

However I have been presented with two hard problems which I can not do:

1. dP/dt=kP-AP2
2. dP/dt=kP(M-P)

using P=Po at t=0 find P(t) for both.

2. Relevant equations

^As above, no other equations where provided, it is pretty much calculus and algebra

3. The attempt at a solution

dP=kP-AP2 dt
dP=P(k-AP) dt
1/P dP = k-AP dt
∫1/P dP = ∫k-AP dt
Ln(P)=t(k-AP)
Ln(P)=tk-APt
etk-APT=P
loge(tk-APt)=P
eP=tk-APt

From there it just loops around. I can not think of anything else to do with it. As you can not (that I am aware of, unless you used unreals, factorise kP-AP2.

Thanks for reading this, I am not giving up and will continue to work on it now.

2. Apr 24, 2013

### LCKurtz

$$\frac{dP}{P(k-AP)} = \frac {-1} A \frac {dP}{P(P-\frac k A)}$$Use partial fractions.

3. Apr 25, 2013

### NZBRU

Thanks a lot, I have now come down to: XP2- XPk/A - AY=1 (Instead of using A and B for partial fractions I used X and Y as those variables were not already used). The questions we have done in class involve something like: x-3=Ax-A+Bx+B and we just split them up into terms which contain x and terms not containing X to solve for A and B. Would you split it up into terms containing P and not P or terms not containing P or k or A?

We have not done this type of question containing two unknown variables (apart from those used for the partial fractions of course) yet. I apologize that I do now know how to use MathsJax, I am just using the quick symbols.

EDIT: Should I have used three fractions and used X,Y,Z as P(k-AP) could be factorized to:

-A times P times P - k/a. Then split the the final line into variables containing each one (somehow, some might contain two variables but I suppose they could be eliminated when finding the values for X, Y and Z). I will try it now...

Last edited: Apr 25, 2013
4. Apr 25, 2013

### LCKurtz

Just call the P's x's and call -k/A "c" and you will feel right at home$$\frac 1 {x(x-c)}$$with a -1/A out in front.

5. Apr 25, 2013

### NZBRU

That makes a lot more sense, I am doing it now. I assume the -1/A can be simply integrated to -Ln(A) as you just simplified -1/A to -1 times 1/A. I will post my results once I finish, thank you a lot by the way. I would be unable to do this without your help.

6. Apr 25, 2013

### NZBRU

This is my working:

∫1/(Pk- AP2) dP
= ∫-1/A times p(p-k/a) dP
∫-1/A dP can be solved
= -1P/A (this could be incorrect)
now back to the other part (I know this setting out is terrible)
∫ p(p-k/a) dP

let P=x and -k/A=c

∫ x(x-c) dx
∫ A/x +B/(x-c) dx
∫ A(x-c)/x(x-c) +Bx/x(x-c) dx
∫ A(x-c)+Bx / x(x-c) dx
∫ Ax-Ac+Bx / x(x-c) dx

Therefore Ax-Ac+Bx / x(x-c) = 1
Split up into terms containing x and terms not containing x

X
A+B=0
B=-A

Other
-Ac=1
-A=1/c
A=-1/c

Therefore B= 1/c

-1/c / x + 1/c / (x-c) = 1 / Pk-AP2
Sub C and P back in...
A=-1/c
A=-1/(-k/A)
A =A/k

B=1/c
B=1/(-k/A)
B=-A/k

So you get:

∫-1/A times [A/k / P + -A/k / (P + k/A) ] dP

7. Apr 25, 2013

### LCKurtz

Why would you assume that? -1/ A is just a constant out in front. The variable of integration is P (or x if you renamed it).

8. Apr 25, 2013

### NZBRU

Oh, that makes sense. My bad, it was lake when I typed that. Is my working for the A and B values correct, I will try to differentiate the final line now.