Calculate gallons per inch and tank volume in gallons from tank dimensions for vertical or horizontal cylinders and rectangular tanks, at any liquid depth.
Related Calculators
- Inches To Quarts Calculator
- Propane Gallons To Pounds Calculator
- Lbs To Liters Calculator
- L to kg Water Conversion Calculator
- All Unit Converters
Calculator Functions
| Function | What it does | What it requires |
|---|---|---|
| Vertical cylinder | Finds the US gallons held by each inch of depth in an upright round tank, and the volume at a given depth | Requires the internal diameter; the liquid depth is optional |
| Vertical rectangular tank | Finds the US gallons per inch of depth in a straight-sided rectangular tank, and the volume at a given depth | Requires the internal length and width; the liquid depth is optional |
| Horizontal cylinder volume | Finds the volume in a round tank lying on its side, where each inch of depth holds a different amount | Requires the internal diameter and length; the liquid depth is optional, and blank gives the full capacity |
| Horizontal depth from volume | Finds how deep a known volume sits in a horizontal cylinder | Requires the internal diameter, the internal length and the known liquid volume |
Dimensions can be entered in inches, feet, centimeters or meters, and the known volume in US gallons, liters or Imperial gallons. Results are in US gallons, with liters and Imperial gallons listed in the calculation details. The first three functions also take an optional liquid weight density in pounds per US gallon, which adds the weight of the liquid whenever a depth is entered.
Gallons Per Inch Formulas
| GPI | US gallons held by one inch of depth (gal/in) |
| A | Area of the liquid surface (inยฒ) |
| 231 | Cubic inches in one US liquid gallon, an exact figure [1] |
One inch of depth over an area of A square inches is A cubic inches of liquid, and dividing by 231 turns that into US gallons. In a tank with straight vertical sides the surface area never changes, so gallons per inch is one constant figure and the volume is that figure times the depth.
Vertical cylinder
D is the internal diameter in inches. A tank 36 inches across holds ฯ ร 18ยฒ รท 231 = 4.4064 gallons per inch, so 10 inches of liquid is 44.064 gallons. The result also gives liters per centimeter, which is GPI ร 3.785411784 รท 2.54.
Vertical rectangular tank
L and W are the internal length and width in inches. A tank 48 inches by 24 inches holds 1,152 รท 231 = 4.987 gallons per inch, and 12 inches of liquid is 59.844 gallons.
Horizontal cylinder volume
V is the volume in US gallons, L is the internal length, r is half the internal diameter and h is the liquid depth measured from the bottom, all in inches. S is the area of the liquid’s cross-section in square inches, a slice of the circle [2]. A tank 48 inches in diameter and 96 inches long holds 752.02 gallons when full and 147.02 gallons at a depth of 12 inches, which is a quarter of the height but under a fifth of the capacity.
Because the liquid surface is narrow near the bottom and top and widest at mid-height, gallons per inch is not constant in this tank. The calculation details give the figure at the entered depth, GPI = 2 ร L ร โ(h ร (D โ h)) รท 231, and the volume held between half an inch below and half an inch above that depth. A depth greater than the diameter is rejected.
Horizontal depth from volume
The horizontal cylinder formula cannot be rearranged to give h directly, so the depth is found by repeated halving: the calculator tests depths between empty and full until the volume matches the one entered. In the 48 inch by 96 inch tank, 150 gallons sits 12.172 inches deep. The result adds the depth in centimeters, the headspace above the liquid and the percentage full. A volume larger than the full capacity is rejected.
How to Calculate Gallons in a Tank
Measure the inside of the tank in inches, work out the volume of liquid in cubic inches, and divide by 231. For an upright round tank the volume is ฯ ร (D รท 2)ยฒ ร depth, and for a rectangular tank it is length ร width ร depth. A round tank 24 inches across filled to 30 inches holds ฯ ร 12ยฒ ร 30 รท 231 = 58.75 gallons. Use the full inside height as the depth to get the capacity of the tank. A round tank on its side needs the horizontal cylinder formula above, because its volume does not rise evenly with depth.
Limits of This Estimate
- All dimensions are internal. Outside measurements include the wall thickness and overstate the volume.
- Tanks are treated as uniform shapes with flat ends. Dished or domed heads, cone bottoms, sloped floors and internal fittings change the real volume, most of all on short horizontal tanks.
- A horizontal tank is assumed to be level. A tank that tilts along its length reads differently at each end.
- Gallons are US liquid gallons of 231 cubic inches. The Imperial gallon is about 20% larger, at 4.54609 liters against 3.785412 liters [3].
Sources
- NIST, Handbook 44 (2026), Appendix C, General Tables of Units of Measurement: 1 US gallon equals exactly 231 cubic inches
- Wolfram MathWorld, Horizontal Cylindrical Segment: volume of a horizontal cylinder filled to a given depth
- NIST, Guide for the Use of the International System of Units (SP 811), Appendix B.8: liters in a US gallon and in an Imperial gallon
