I am trying to find an accurate way of calculating the capacity of an underground tank at a given depth. The tank manufacturer has provided a strapping table for the tank which tells me the capacity at various depths.
Gauge Depth (cm) / Capacity (Liters)
2cm = 29.8 liters
12cm = 240.4 liters
...
66cm = 2372.8 liters
118cm = 4008.4 liters
However, I would like to find an equation for calculating the volume of liquid in the tank based on the liquid depth level.
They have provided the following dimensions for the tank:
1219mm Diameter
3785mm Long
3978 Liters Capacity
The tank is horizontal with hemispherical ends. It is safe to assume that the radius of the hemispherical ends is 1/2 of the diameter of the tank. Any help or direction would be greatly appreciated!
There are three parts to the tank: the two hemispherical ends and the middle cylinder. The two hemispherical ends add up to one whole sphere, so we'll just consider a sphere and a cylinder. Just to check the data you've given: at 1219mm diameter, the sphere has volume roughly 948.44 liters. The cylinder has diameter 1219mm and height (3785-1219)=2566mm. The volume is roughly then 2994.7 liters. So I'm guessing that there's either a typo on your data sheet (either the total tank capacity is closer 3948 liters, or the total length of the tank is closer to 3815mm), or a mis-description: the ends are not capped by exact hemispheres.
Never mind that, since we are on a mathematics site and who cares about plugging in real numbers /end_sarcasm
Assume your tank is composed of two hemispherical ends of radius $R$, and a central cylinder of radius $R$ and length $L$. The diameter would be $2R$ and total length $L + 2R$. We want to calculate volume as a function of water depth.
Since your tank is lying horizontally, the height of water, which we will call $h$, should be the same inside the cyclinder portion and inside the spherical portions. So we will compute the total volume as a sum of the volume inside the sphere (remember: two hemispheres make one whole sphere) and the volume inside the cylinder.
$$ V_{tot} = V_s + V_c $$
If you know calculus, you can compute the volume of the spherical cap of height $h$ by evaluating an integral. But the formula is well-known:
$$ V_s = \frac{\pi h^2}{3}(3R - h) $$
For the cylinder, the volume at height $h$ is equal to the length $L$ multiplied by the area of the circular segment of height $h$:
$$ V_c = L \times A = L \times \left[ R^2 \cos^{-1}\left(\frac{R-h}{R}\right) - (R - h) \sqrt{2Rh - h^2}\right] $$
with the formula for $A$ derivable by elementary geometry/trigonometry, or again through the evaluation of an integral. So putting it all together you have that
$$ V_{tot} = \frac{\pi h^2}{3}(3R - h) + L \times \left[ R^2 \cos^{-1}\left(\frac{R-h}{R}\right) - (R - h) \sqrt{2Rh - h^2}\right] $$
which gives