AJ Designer

Capsule Calculator

Volume equals pi r squared h plus four-thirds pi r cubed

The straight middle section only — total tip-to-tip length is L = h + 2 r.

Solution

Share:

Calculate Capsule Volume from Radius and Cylinder Height

Use this form when you know the capsule's radius and the cylinder-section height (the straight middle, between the two hemispherical end caps). It is the standard formula for sizing pressure vessels, gel-capsule volumes, and any pill-shaped tank.

V = π r² h + (4/3) π r³

Calculate Capsule Surface Area

Use this form when you need the total external surface area of a capsule — the curved cylinder side plus both hemispherical caps. Common for paint, coating, insulation, and material takeoff on capsule-shaped pressure vessels and storage tanks.

S = 2π r h + 4π r²

Calculate Cylinder-Section Height from Volume and Radius

Use this rearrangement when the target volume and the fixed radius are known, and you need the straight-section length between the two end caps. Common when laying out a capsule tank to hit a target capacity at a given shell diameter.

h = (V − (4/3) π r³) / (π r²)

How It Works

This capsule calculator solves the two forward formulas V = π r² h + (4/3) π r³ (enclosed volume) and S = 2π r h + 4π r² (total external surface area), plus the inverse h = (V − (4/3) π r³) / (π r² ) for the cylinder-section height. A capsule is a right circular cylinder of radius r and straight-section height h with a hemispherical cap of the same radius on each end; the two caps together contribute the full sphere terms, so the cylinder lateral area and a full sphere's surface area add up to the external surface. Pick the unknown, enter the remaining values in any supported length, area, or volume units, and the page returns the full set of derived quantities — volume V, surface area S, radius r, cylinder height h, total tip-to-tip length L = h + 2r, and diameter d = 2 r.

Example Problem

A pressure vessel has an inside radius of 1 m and a cylinder-section length (between the two hemispherical heads) of 4 m. What is the enclosed volume?

  1. Identify the measured dimensions: r = 1 m for the radius shared by the cylinder and both hemispherical heads, and h = 4 m for the cylinder-section length between them.
  2. Choose the unknown: we want the enclosed volume, so use V = π r² h + (4/3) π r³.
  3. Cylinder term: π r² h = π · (1)² · 4 = 4π ≈ 12.566 m³.
  4. Combined hemispheres term (two halves equal one whole sphere): (4/3) π r³ = (4/3) π · (1)³ ≈ 4.189 m³.
  5. Add the two terms: V = 4π + (4/3) π = 16π/3 ≈ 16.755 m³.
  6. State the result with a useful secondary unit: 16.755 m³ ≈ 16,755 liters — a practical fill volume for a small horizontal storage capsule. Total tip-to-tip length L = h + 2 r = 4 + 2 = 6 m.

Round-trip check: from V ≈ 16.755 m³ and r = 1 m, the inverse formula h = (V − (4/3) π r³) / (π r²) recovers h = 4 m. The check fails (h goes negative) only if the requested volume is smaller than the just-spheres capacity (4/3) π r³ — in that case the capsule with the given radius cannot exist.

When to Use Each Variable

  • Solve for Volumewhen the radius and cylinder-section height are known and you need the enclosed volume of a capsule-shaped tank, pressure vessel, or pharmaceutical capsule.
  • Solve for Surface Areawhen you need to estimate paint, coating, insulation, or shell-material area for the entire external surface of a capsule — both heads plus the cylinder side.
  • Solve for Cylinder Heightwhen a target volume and a fixed radius are known, and you need the straight-section length between the two hemispherical heads.

Key Concepts

A capsule (also called a stadium of revolution, discorectangle in 3D, spherocylinder, or simply a pill shape) is built by gluing a right circular cylinder to two hemispherical caps of the same radius — one on each end. Because the two hemispheres share the same radius as the cylinder, they meet the cylinder seamlessly with no exposed flat end disks, and together they form one full sphere of radius r. That structure makes the volume V = πr²h + (4/3)πr³ and the external surface area S = 2πrh + 4πr² — the cylinder volume plus a full sphere, and the cylinder lateral area plus a full sphere's surface area. The total tip-to-tip length is L = h + 2r, which is what you measure with calipers. When h = 0 the cylinder section vanishes and the capsule degenerates to a sphere; when r is small relative to h the shape approaches a slender rod with rounded ends. Capsule geometry is the standard idealization for horizontal pressure vessels, gel-cap pharmaceuticals, athletic-field stadium tracks (in 2D), and many storage and process tanks where pure cylinders are difficult to seal against internal pressure.

Applications

  • Pressure vessels: horizontal LPG / ammonia / air storage tanks use hemispherical (or near-hemispherical) heads because spherical surfaces handle internal pressure more efficiently than flat disks; the idealized capsule volume V = πr²h + (4/3)πr³ is the standard first-pass sizing formula
  • Pharmaceutical capsules: hard and soft gel capsules are nearly perfect capsule (spherocylinder) shapes — V = πr²h + (4/3)πr³ gives the fill volume from the body diameter and straight-section length specified on the capsule-size chart
  • Stadium-shaped athletic tracks and arena layouts: a 400 m running track is a 2D stadium (the same shape as a capsule's outline); the perimeter 2πr + 2h and area πr² + 2rh come from the same component breakdown
  • Industrial process tanks: blending, surge, and slurry tanks often use a capsule profile when codes require dished or hemispherical heads instead of flat ones — capacity and shell-area takeoffs both fall out of the capsule formulas

Common Mistakes

  • Confusing the cylinder-section height h with the total tip-to-tip length L — they differ by 2r (one full diameter), so a 4 m cylinder section on a 1 m radius capsule is 6 m long overall, not 4 m
  • Using diameter instead of radius in either term — both πr²h and (4/3)πr³ need the radius (half the diameter), so plug d/2 into r, not d
  • Adding the two end disks (2 · πr²) into the surface area — the hemispherical caps replace those disks rather than sit on top of them, so the correct surface area is 2πrh + 4πr², not 2πrh + 4πr² + 2πr²
  • Treating a hemispherical-head pressure vessel as a plain cylinder — ignoring the (4/3)πr³ term underestimates the capacity, and ignoring the 4πr² term underestimates the shell area, both by roughly 50 % for short squat capsules
  • Mixing length units between the radius and the cylinder height (for example r in cm and h in m) without converting first — the volume comes out wrong by orders of magnitude

Frequently Asked Questions

How do you calculate the volume of a capsule?

Use V = π r² h + (4/3) π r³, where r is the radius of the cylinder (also the radius of each hemispherical end cap) and h is the cylinder-section height between the two caps. For example, a capsule with r = 1 m and h = 4 m has V = 4π + (4/3)π = 16π/3 ≈ 16.755 m³.

What is the formula for capsule surface area?

External surface area is S = 2π r h + 4π r². The first term 2π r h is the curved cylinder side; the second term 4π r² is the surface area of one full sphere — the two hemispherical caps combined. There are no flat disk areas because the caps replace the cylinder's end disks rather than sit on top of them.

What is the difference between a capsule and a cylinder?

A cylinder has two flat circular end disks; a capsule replaces each disk with a hemispherical cap of the same radius. That makes a capsule longer than its cylinder by one full diameter (total tip-to-tip length L = h + 2 r) and gives it (4/3) π r³ more volume and 4π r² − 2π r² = 2π r² more surface area than the corresponding cylinder.

Why do pressure vessels use capsule shapes?

Hemispherical heads handle internal pressure more efficiently than flat ends — for a given material thickness, a sphere can hold roughly twice the pressure of a cylinder of the same radius. Putting hemispherical heads on a cylindrical shell (the capsule shape) is a common compromise that gets most of the pressure efficiency of a sphere with the easier fabrication of a cylinder.

Is a capsule the same as a pill shape?

Yes. The mathematical capsule (cylinder plus two hemispherical caps), the pharmaceutical hard-gel capsule, and the everyday "pill" shape are the same solid. In 2D cross-section it is also called a stadium or discorectangle and is the basic outline of a running track.

How do you find the cylinder-section height of a capsule from its volume and radius?

Rearrange V = π r² h + (4/3) π r³ to h = (V − (4/3) π r³) / (π r²). Subtract the sphere term from the total volume, then divide by the cylinder cross-section area π r². For example, a 16.755 m³ capsule with r = 1 m has h = (16.755 − 4.189) / π = 4 m.

What happens if the requested volume is too small for the radius?

If V is smaller than (4/3) π r³ — the volume of a sphere of radius r — then no capsule with that radius can hold that little, because even the just-the-hemispheres case already exceeds it. The calculator detects this and clears the result instead of returning a negative height. To fit a smaller volume, reduce the radius.

How is capsule volume expressed in liters or gallons?

One cubic meter is 1,000 liters or about 264.17 US gallons, so a 16.755 m³ capsule holds about 16,755 L or 4,427 US gal. The calculator's volume-unit dropdown converts the result into liters, US gallons, cubic feet, or whichever unit you pick — no manual conversion needed.

Reference: Weisstein, Eric W. "Spherical Cap." MathWorld — A Wolfram Web Resource. https://mathworld.wolfram.com/SphericalCap.html (capsule = cylinder + two spherical caps of half-angle π/2).

Worked Examples

Pressure Vessel

How do you calculate the volume of a horizontal LPG pressure vessel with hemispherical heads?

A horizontal LPG storage tank has an inside radius of 1 m and a cylinder-section length (the straight middle between the two hemispherical heads) of 4 m. Use V = π r² h + (4/3) π r³ to find the capacity in cubic meters and liters.

  • Knowns: r = 1 m, h = 4 m (cylinder section only)
  • Formula: V = π r² h + (4/3) π r³
  • Cylinder term: π · 1² · 4 = 4π ≈ 12.566 m³
  • Sphere term (two hemispheres combined): (4/3) π · 1³ ≈ 4.189 m³
  • V = 4π + (4/3) π = 16π/3 ≈ 16.755 m³ ≈ 16,755 L
  • Total tip-to-tip length: L = h + 2 r = 4 + 2 = 6 m

Volume ≈ 16.755 m³ (about 16,755 liters); overall length ≈ 6 m

For LPG service, design rules typically allow a maximum fill of about 85 % by volume at the reference temperature to leave room for liquid expansion. Use the inside dimensions for capacity and the outside dimensions for shell-area takeoff.

Pharmaceutical Capsule

What is the fill volume of a standard size-0 gel capsule?

A size-0 hard gelatin capsule has an outside body diameter of about 7.34 mm (radius ≈ 3.67 mm) and a cylinder-section length of about 11.0 mm between the two hemispherical end caps. Estimate the internal fill volume.

  • Knowns: r = 3.67 mm, h = 11.0 mm (cylinder section between the hemispherical ends)
  • Formula: V = π r² h + (4/3) π r³
  • Cylinder term: π · (3.67)² · 11.0 ≈ 465.4 mm³
  • Sphere term: (4/3) π · (3.67)³ ≈ 207.0 mm³
  • V ≈ 465.4 + 207.0 ≈ 672 mm³ ≈ 0.67 mL
  • Total tip-to-tip length: L = 11.0 + 2 · 3.67 ≈ 18.3 mm

Fill volume ≈ 0.67 mL (672 mm³); overall capsule length ≈ 18.3 mm

Manufacturer-published size-0 fill volume is typically quoted as 0.68 mL — close to this estimate. Real capsule bodies and caps are sized to telescope together, so the body's internal volume is slightly less than the external-shell volume computed here.

Inverse Solve

What cylinder-section height is needed for a 5,000-liter capsule of fixed radius?

A horizontal storage capsule must hold 5,000 L (5 m³). The shell diameter is fixed by available stock at 1.2 m (r = 0.6 m). Find the required cylinder-section height with h = (V − (4/3) π r³) / (π r²).

  • Knowns: V = 5 m³, r = 0.6 m
  • Formula: h = (V − (4/3) π r³) / (π r²)
  • Sphere term to subtract: (4/3) π · (0.6)³ ≈ 0.905 m³
  • Remaining cylinder volume: 5 − 0.905 ≈ 4.095 m³
  • Cylinder cross-section: π · (0.6)² ≈ 1.131 m²
  • h ≈ 4.095 / 1.131 ≈ 3.622 m; total length L = h + 2 r ≈ 4.822 m

Cylinder-section height ≈ 3.62 m; total tip-to-tip length ≈ 4.82 m

Real tanks need freeboard above the working volume — add 5–10 % to the calculated cylinder length for headspace and a vent allowance. If the requested volume is below (4/3) π r³ (the just-spheres case) for the chosen radius, no capsule of that diameter can fit it; pick a smaller radius.

Capsule Formulas

A capsule's geometry is fully determined by two dimensions: the radius r (shared between the cylinder and both hemispherical end caps) and the cylinder-section height h (the straight middle between the two caps). From those, the volume, surface area, tip-to-tip length, and diameter all follow:

Volume equals pi r squared h plus four-thirds pi r cubedSurface area equals two pi r h plus four pi r squaredCylinder height h equals the quantity V minus four-thirds pi r cubed, all divided by pi r squared
Capsule (cylinder with two hemispherical ends), with labeled radius r and cylinder-section height hrhL = h + 2r

Where:

  • V — enclosed volume (m³, L, gal, ft³, etc.)
  • S — total external surface area: cylinder side (2π r h) + one full sphere (4π r²); the two hemispherical caps replace the cylinder's end disks rather than sit on top of them
  • r — radius shared by the cylinder and both hemispherical end caps (m, cm, in, ft, yd)
  • h — cylinder-section height: the straight middle between the two end caps (same units as r)
  • L — total tip-to-tip length: L = h + 2 r, the dimension you measure with calipers
  • d — diameter (d = 2 r), commonly used to spec real-world capsules and pressure vessels

Related Calculators

  • Cylinder Calculatorcompute volume and surface area for a plain cylinder (flat end disks instead of hemispherical caps)
  • Hemisphere Calculatorfind volume, curved area, and total surface area of a single hemispherical cap
  • Sphere Calculatorcompute volume and surface area of a full sphere — the degenerate-cylinder (h = 0) case of a capsule
  • Circle Calculatorfind area, circumference, and diameter for a single circle (the cross-section of a capsule)
  • Volume Converterswitch between m³, L, gallons, ft³, and other volume units for capsule capacity

Related Sites