Tank Problem with Differential Equations (concentration output starts at a different t than the initial t)

calculusordinary differential equations

Problem: Consider a tank of $350$lts with $100$lts of pure water at $t=0$. At $t=0$, the tank begins to fill with a saline concentration that has $10$gr per lt, at a rate of $5$ lts$/$min. It continues to fill for $20$ minutes when suddenly a leak opens at the bottom of the tank where $2$ liters of contents per minute leak out. Calculate the salt concentration in the tank at the moment it reaches its maximum capacity.

My Solution: For $0\leq t \leq 20$ it is clear that the differential equation that models the salt concentration is:

$$\frac{dQ}{dt} = \frac{10 \cdot 5}{100+5t}$$

For $t \geq 20$ I proposed the following equation:

$$\frac{dQ}{dt} = \frac{10\cdot 5 – 2Q}{200+3(t-20)}$$

Here the explanation of this equation:

Salt rate in: $10gr/lt \cdot 5lt/min$

Salt rate out: $Q \cdot 2lt/min$

Volume (at $t=20$): $100+5\cdot 20 = 200$

Volume (after $t=20$): $200+(5-2)(t-20)$ because in $t=0$ I want to obtain $200lt$

Since the change of concentration is (rate in – rate out)/V(t), then:

$$\frac{dQ}{dt} = \frac{10\cdot 5 – 2Q}{200+3(t-20)}$$

However, my professor told me that there is a problem with this second differential equation and I don't realize what is the error.

Best Answer

Since the change of concentration is (rate in - rate out)/V(t)

I think this is the issue. If $q(t)$ is the mass of solute (salt in this case), and $V(t)$ is the volume of solution, then $$ Q(t) = \frac{q(t)}{V(t)} $$ If $V(t)$ is constant, then $Q'(t) = q'(t)/V(t)$, and your equation is satisfied. But if $V(t)$ is not constant, then $Q'(t)$ is a more complicated expression involving $q'(t)$ and $V'(t)$.


It always seems easier for me to work with the mass of the solute instead. If you need concentration, divide by the volume. For $t > 20$, there is salt entering and leaving the tank. The mass of salt going in is $50$ g/min. Assuming that the solution is well-mixed (and this assumption is usually stated in the problem), the mass of salt going out is the concentration of salt in the solution, times the rate at which solution is leaving the tank. So $$ \frac{dq}{dt} = 50 - \frac{q(t)}{200 + 3(t-20)}(2) $$ The initial condition is $q(20) = 1000$. You want to know $Q(t_*) = \frac{q(t_*)}{350}$ at the moment $t_*$ where $V(t_*) = 350$.