Ln|0|=kx+c? DE problem

kanki

Another DE problem i've encoutered...

A contagious disease spreads at a rate directly proportional to the product of the number of population infected and the remaining population that is not infected. Initially, one-half of the population is infected and if the rate of infection is kept constant, the whole population will be infected in 24 days. Find the proportion of the population that will be infected after 12 days.

ok i got the differential equation:
$$\frac{dx}{dt}=k(x)(1-x)$$ (x is the proportion of the population)

$$\int \frac{dx}{x(1-x)} = \int k dt$$

and change it into partial fraction:

$$\int [\frac {1}{x} + \frac {1}{1-x}]dx = \int k dt$$

$$ln|x|-ln|1-x|=kt+c$$

After i substitute the t=0, x=0.5, and got

$$ln|\frac{0.5}{1-0.5}|=k \cdot 0 + c$$

$$ln 1 = c$$

$$c = 0$$

$$\therefore ln|\frac {x}{1-x}|=kt$$

The problem is when i tried to find the constant k, as i substituted t=24 and x=1, i got:

$$ln|\frac{1}{0}|=24k$$

So, how to solve $$\frac{1}{0}=e^{24k}$$?

:uhh: thanks for your time here.

Last edited:
Related Differential Equations News on Phys.org

AKG

Homework Helper
You might not have done the rest of it right, but 1 - 0.5 is not 0, and kt + c is not equal to kt when k = 0.

marlon

But is k a function of x or do you just mean $$k (x-x^2)$$ ?

I hope it is the second one, otherwise there is a problem.

Eitherway, the calculated integral is incorrect.

marlon

dextercioby

Homework Helper
Nope, "k" is a constant.It was a misuse of round brackets, that's all.

Daniel.

Last edited:

kanki

I've edited the post to add some working inside.
Please correct me if my integral is not correct.
Did i miss something when i change it into partial fraction?

HallsofIvy

Homework Helper
Your calculations are all correct. The problem you have is that, given that the "rate of infection" is a constant, as stated, the continuous function solution will never equal 1- it approaches 1 in the limit as t goes to infinity. In particular, you can never have x(24)= 1 which is required by your problem. Of course, population is integer valued so the continuous solution can't be true anyway. If you knew the actual population, you might use the statistician's "half-integer" correction- treat "entire population" as "within 1/2 person of entire population". That is set x(24)= (population- 1/2)/population.

If you don't know the actual size of the population, you should be able to get a good approximation by setting x(24)= 0.99 or some other number close to 1. For example, if x(24)= 0.99, then your equation becomes ln(.99/.01)= ln(99)= 24k so that k= ln(99)/24= 0.191. Then the answer to "proportion infected after 12 days" requires solving ln(x/(1-x))= (0.191)(12)= 2.30 so that x/(1-x)= e2.30= 9.95.
Then x= 9.95- 9.95x so x= 9.95/10.95= 0.91 or 91% of the population.

If instead you use 0.95, you get ln(.95/.05)= ln(19)= 24k so that k= ln(19)/24= 0.123. Now to find "proportion infected after 12 days", solve ln(x/(1-x))= (0.123)(12)= 1.47. 1/(1-x)= e1.47= 4.36 so x= 4.36- 4.36x. x= 4.36/5.36= 0.81 or 81% of the population. Those are not the same answer but they are not wildly off.

kanki

HallsofIvy said:
treat "entire population" as "within 1/2 person of entire population". That is set x(24)= (population- 1/2)/population.
I don't understand how to treat "entire population" as 1/2 person of entire population.
So there's no solution to this question? Because the rate is constant and the disease is not spread to whole population?

mustafa

kanki said:
and if the rate of infection is kept constant, the whole population will be infected in 24 days.
The question means that if rate of infection is kept constant, ie dx/dt is constant and equal to dx/dt at t=0, the entire population will be infected in 24 days.
Substituting x=0.5 and t=0, the value of dx/dt at t=0 is 0.25k
So taking x=0.25kt+0.5 (x=0.5 at t=0) and substituting x=1 at t=24, we get k=1/12

However dx/dt is not constant and as obtained by you
$$ln|\frac {x}{1-x}|=kt$$
Substituting k=1/12 and t=12
$$ln|\frac {x}{1-x}|=1$$
x/1-x=e
x=e/e+1

Therefore the proportion infected after 12 days will be e/e+1

kanki

oh... mustafa u solved the question, the answer is e/e+1 after i checked with my book.
Oh, i missed the word if. So the initial rate of infection is kept constant, whole population will be infected in 24 days. Therefore i just have to use this to solve the value of k right?

Thanks!

HallsofIvy

Homework Helper
That's a very strange interpretation! You're interpreting the problem as a "logistic equation" problem but then interpreting "rate of infection is kept constant" to mean linear increase in order to find the k used in the logistic equation! If that is what the book meant then I am amazed.

kanki

The teachers asked us to skip the question.
But i'm curious whether i can solve the problem, so i post it here.
I'm not expert in maths, so is this the book's problem?

Physics Forums Values

We Value Quality
• Topics based on mainstream science
• Proper English grammar and spelling
We Value Civility
• Positive and compassionate attitudes
• Patience while debating
We Value Productivity
• Disciplined to remain on-topic
• Recognition of own weaknesses
• Solo and co-op problem solving