Calculator overview
Inputs and outputs
This summary comes from the calculator's published input and output contract.
Inputs
- Straight shell length
-
Unit ft Default 20 Range At least 0
About this input
The straight side length of a horizontal tank or the shell height of a vertical tank, in feet, not counting the curved heads.
- Orientation
-
Default Horizontal Allowed Vertical, Horizontal
About this input
Whether the tank sits horizontally on its side or stands vertically on its end. It sets which geometry and which head shapes apply.
- Head Type Conditional
-
Default Hemispherical Allowed Flat, Hemispherical
About this input
The end-cap shape of a horizontal tank, such as flat, hemispherical or elliptical. It sets the extra volume the two heads add beyond the cylinder.
- Diameter
-
Unit ft Default 8 Range At least 0
About this input
The inside diameter of the cylindrical shell, in feet.
- Fill Height
-
Unit ft Default 5 Range At least 0
About this input
The depth of liquid measured from the lowest inside point of the tank, in feet, used to find the partially filled volume.
Outputs
- Total Volume Cubic Feet
-
Unit ft3
About this output
The full capacity of the tank including its heads, in cubic feet.
- Total Volume Gallons
-
Unit gal
About this output
The full capacity of the tank, in US gallons, converted from the cubic-foot volume.
- Ullage
-
Unit ft3
About this output
The empty space remaining above the liquid, in cubic feet: total volume minus filled volume.
- Model Status
-
No unit declared
About this output
The overall check on your entries, shown above the results. It reads OK when the inputs are usable, NOT VALID with a reason when an entry makes the model meaningless, or CHECK with a reason when a result is valid but worth a second look. Read it before you trust the numbers below.
- Fill Percent
-
Unit percent
About this output
The filled volume as a percent of the total volume, showing how full the tank is.
- Filled Volume Cubic Feet
-
Unit ft3
About this output
The volume of liquid at the entered fill height, in cubic feet, from the partial-fill geometry for the orientation and head type.
- Filled Volume Gallons
-
Unit gal
About this output
The volume of liquid at the entered fill height, in US gallons.
What it is
The Tank Volume Calculator works out how much a cylindrical tank holds in total, and how much is in it at a given liquid depth. You give it the diameter, the straight-side length or shell height, whether the tank lies horizontally or stands vertically, the end-cap shape, and the measured depth, and it returns the full capacity, the filled volume, the ullage remaining, and the fill percentage.
Volumes come back in both cubic feet and US gallons; dimensions are in feet.
Use it to gauge tank contents from a dip measurement, or to check a tank's rated capacity. The horizontal case is the one worth having a calculator for, because the relationship between depth and volume is not linear.
Methodology
Purpose and model boundary
This model calculates total capacity, partial filled volume, ullage, and fill percent for a vertical cylindrical tank or a horizontal cylindrical tank with flat or paired hemispherical heads. It also produces a dip chart over fill height. It supports gauging and preliminary capacity checks from ideal dimensions. It does not use a certified strapping table, model deformed or tilted vessels, account for nozzles/internals, or determine safe working capacity.
Inputs and units
Orientation is vertical or horizontal. Diameter and fill height are in ft. Length_Or_Height is the shell height for a vertical tank and straight shell length for a horizontal tank; the workbook changes that label from the orientation. Head type is visible only for horizontal orientation and is flat or hemispherical. Volumes are calculated in ft³ and converted using 7.4805195 gal/ft³.
Governing relationships
Let D be diameter, R = D/2, L the straight shell length or vertical height, and h_c = max(0, min(h, tank height)) the capped fill height.
For a vertical cylinder:
V_filled = pi/4 × D² × h_c
V_total = pi/4 × D² × L
For a horizontal cylinder, circular-segment area is:
A_segment = R² × acos((R - h_c)/R) - (R - h_c) × sqrt(2Rh_c - h_c²)
The flat-head filled volume is A_segment × L. With paired hemispherical heads, the workbook adds the spherical-cap volume:
V_cap = pi × h_c² × (3R - h_c) / 3
At full height, the two hemispherical heads form one sphere, so horizontal total volume is piR²L + 4piR³/3; flat heads use piR²L. Ullage is V_total - V_filled, and fill percent is 100 × V_filled / V_total.
Calculation sequence
- Set the maximum fill dimension to vertical height or horizontal diameter according to orientation.
- Cap fill height to the physical range for geometry while retaining the original input for status.
- Calculate vertical-cylinder or horizontal circular-segment volume.
- Add a spherical cap for the paired hemispherical heads when horizontal; ignore head type when vertical.
- Calculate total capacity, ullage, percent full, and gallon conversions.
- Repeat the same geometry at 16 evenly spaced fill heights for the dip chart.
- Evaluate
Model_Statususing the uncapped inputs.
Outputs and interpretation
Total_Volume_Gallons and Filled_Volume_Gallons are the primary results. Cubic-foot equivalents, ullage, and fill percent provide supporting checks. The dip chart is linear for a vertical cylinder but nonlinear for a horizontal tank because equal depth changes do not contain equal circular-segment areas. A fill above the tank is capped to full volume and explicitly warned.
Validation and status logic
| Condition | Returned status |
|---|---|
| Diameter or length/height is zero or less | NOT VALID: diameter and length must be positive |
| Fill height is negative | NOT VALID: fill height cannot be negative |
Fill height exceeds the applicable tank height by more than 0.0000001 ft |
CHECK: fill height exceeds the tank; volume is capped at full |
| None of the preceding conditions applies | OK |
Invalid tank geometry precedes negative-fill validation. The overfill check uses the original input and a small workbook tolerance; the volume calculation itself uses the capped height.
Assumptions and limitations
- The shell is a perfect right circular cylinder with uniform inside dimensions and a level horizontal or vertical axis.
- Horizontal hemispherical selection represents two true hemispherical ends, together equal to one full sphere. Other head geometries such as 2:1 elliptical, torispherical, conical, or dished heads are not available.
- Vertical orientation always uses a plain cylinder; the hidden head selector has no effect on vertical results.
- Fill is level, and the tank has no tilt, deadwood, internal coils, baffles, wall thickness correction, thermal expansion, heel restrictions, nozzle volume, or calibration offset.
- The dip chart has 16 computed points and is not a certified high-resolution gauge table.
- Entered dimensions must be internal dimensions if the desired result is internal liquid capacity.
Restrictions and non-computing states
This calculator restricts orientation and head type to the declared options and rejects negative diameter, length/height, and fill height. The workbook requires positive diameter and length/height. A zero fill is valid and returns an empty tank. A fill exactly at the tank height is valid and full; a greater fill returns a CHECK while capping the computed volume at full. The head selector is dynamically hidden for vertical tanks.
Errors and warnings
An undeclared option or negative value outside its allowed range is rejected by the page before a workbook decision. Workbook NOT VALID means the physical tank or fill basis is unusable. Workbook CHECK means a full volume is still returned but the entered dip exceeds the physical tank. A connection failure is a service error and is not evidence of an empty or full vessel.
References
The workbook derives its relations rather than reproducing any table, chart or figure from a standard or agency publication. The volumes are elementary solid geometry: a cylinder, a sphere formed by two hemispherical heads, and the circular-segment area for a partially filled horizontal cylinder.
- National Institute of Standards and Technology. Circumference, area and volume reference. https://www.nist.gov/pml/owm/circumference-area-and-volume
- Wikipedia. Circular segment, the geometry behind the horizontal partial fill. https://en.wikipedia.org/wiki/Circular_segment
- CalculatorSoup. Tank volume calculator, for an independent cross-check. https://www.calculatorsoup.com/calculators/construction/tank.php
For tank gauging used in trade, a strapping table calibrated for the individual tank is the governing document and this calculation is not a substitute for one. No trademark or organisation name appearing here implies endorsement by its owner.
Additional source notes migrated from Methodology
The workbook uses exact cylinder, circular-segment, and spherical-cap geometry and reproduces no proprietary strapping table. The reviewer packet cites CalculatorSoup's tank-volume reference, Omni Calculator's tank-volume reference, and FIRGELLI's horizontal/vertical tank reference for independent comparison.
Frequently asked questions
Why is my horizontal tank not half full at half the depth?
Why does head type change the total volume so much?
Does head type matter for a vertical tank?
Can I use this to measure what is in my tank for a sale?
My calculated volume reads higher than what the tank actually holds. Why?
Which dimension is "length or height"?
Found a problem, or have an idea?
Tell us if a result looks wrong, a label is unclear, or something is missing. We read every message.
LogicCommons is in beta. If a result, label, or reference looks wrong, tell us here; we read every message.