Any Errors in My Differential Equation for a Leaking and Refilling Container?

  • Thread starter Thread starter SidVicious
  • Start date Start date
  • Tags Tags
    Container Ode
SidVicious
Messages
4
Reaction score
0
I have to set up a differential equation for a leaking cylindrical container that is being refilled at a constant rate. Its leaking from the bottom, refilled from the top, and starts empty.
Wondered if someone could check if what i have done so far is right..?
h=height of water
A=cylinder cross section
a=hole cross section
v=speed of water out = Sqrt(2gh) using Torricelli’s Law
b=rate of water going in

Rate of change of volume dV/dt= -av+b = A*dh/dt
Sub in v = Sqrt(2gh):
A*dh/dt=-a*sqrt(2gh)+b -----> dh/dt = (-a*Sqrt(2gh)+b)/A

Any errors?!
Thanks!
 
Physics news on Phys.org
Seems fine to me. As long as the formula for v is correct.

Torquil
 
Thanks Torquil.
I have to solve this using Eulers method:
yn+1 = yn + hf(xn,yn)
xn+1 = xn + h
where h is a step in x, to be chosen.
y=height of water(original h)
x=t
f(x,y) = dh/dt

As there is no t on the rhs of the differential equation will this formula work?

n=o : yn=0(t=o)=0
n=1 : yn=1 = (yn=0) + h((-a*Sqrt(2g(yn=0))+b)/A)
n=2 : yn=2 = (yn=0) + h((-a*Sqrt(2g(yn=0))+b)/A) + h((-a*Sqrt(2g(yn=1))+b)/A)
etc..

I want to make a plot of y against x (height water vs time) at the end, can i do that using this method as there is no t on rhs...?!

Thanks again!
 
Yes that seems correct. To plot the height vs time, plot the points y_n vs h*x_n, for all values of n. Try doing everything for various small values of h to determine if the result has converged. Maybe you can even perform the integral analytically and get an exact result to compare with your computer simulation.

Torquil
 
Are there any good visualization tutorials, written or video, that show graphically how separation of variables works? I particularly have the time-independent Schrodinger Equation in mind. There are hundreds of demonstrations out there which essentially distill to copies of one another. However I am trying to visualize in my mind how this process looks graphically - for example plotting t on one axis and x on the other for f(x,t). I have seen other good visual representations of...
Back
Top