Formulas for each tank shape
A vertical tank fills evenly, so the liquid volume is simply the base area times the depth: πr²h for a round tank and L × W × h for a rectangular one.
A horizontal cylinder is harder because the wetted cross-section is a circular segment. With radius r and liquid depth h, its area is A = r²·acos((r − h)/r) − (r − h)·√(2rh − h²), and the liquid volume is A × L. At h = 0 the area is zero, at h = r it is half the circle and at h = 2r it is the full circle πr².
Capsule tanks add two hemispherical ends, which together make a sphere. In a horizontal capsule the ends hold a spherical cap of volume πh²(3r − h)/3. An elliptical tank is a circle stretched sideways, so its wetted area is the circular segment of the vertical semi-axis b scaled by a/b.
| Shape | Total volume |
|---|---|
| Vertical or horizontal cylinder | πr² × height or length |
| Rectangular tank | L × W × H |
| Capsule (cylinder + hemispherical ends) | πr² × straight length + 4/3·πr³ |
| Horizontal elliptical tank | π × a × b × L |
| Cone-bottom or cone-top tank | πr² × cylinder height + πr² × cone height ÷ 3 |
| Frustum (bottom radius R, top radius r) | πH(R² + Rr + r²) ÷ 3 |
Worked example: a horizontal tank 2 m across
A horizontal cylindrical tank is 2 m in diameter and 5 m long, with 0.5 m of liquid in it. The radius is 1 m, so the wetted area is 1²·acos(0.5) − 0.5 × √(1 − 0.25) = 1.0472 − 0.4330 = 0.6142 m².
Multiplying by the 5 m length gives 3.071 m³, or 3,070.92 litres (811.25 US gallons). The full tank holds 15,707.96 litres, so the tank is 19.55% full by volume even though the liquid reaches a quarter of the height.
Assumptions and limits
Use inside dimensions. The calculator assumes ideal shapes, so wall thickness, sumps and dished or torispherical heads (common on pressure vessels and fuel tanks) are not modeled; for those, the tank maker's strapping chart is the reference. Conical bottoms, conical roofs and tapered tanks are covered by the cone and frustum shapes.
US gallons use the exact definition of 231 cubic inches, which is 3.785411784 litres. Imperial gallons are larger, at 4.54609 litres.
Cone-bottom, cone-top and frustum tanks
A cone-bottom tank is a vertical cylinder standing on a cone whose point faces down, as in a hopper or silo. Up to the cone height c, the liquid forms a smaller cone with surface radius r·h/c, so V = π(r·h/c)²·h/3. Above the cone, add πr² for each unit of extra height.
A cone-top tank is a cylinder with a conical roof. Liquid above the cylinder fills a frustum (a cone with its tip cut off), and its volume is πd(R² + R·r′ + r′²)/3, where d is the depth into the cone and r′ is the radius at the surface.
A frustum tank tapers from a bottom diameter to a different top diameter. The radius at height h is R + (r − R)·h/H, so the filled volume is πh(R² + R·r_h + r_h²)/3. For example, a 2 m tall frustum 2 m across at the bottom and 1 m at the top holds 7π/6 ≈ 3.665 m³ (3,665 L).