Ma · Mathematics

How to Calculate the Partial Volume of a Capsule Tank

Published By the 9to5Science editorial team

At a glance

  1. 1. Set the dimensions

    Use r for the tank radius, L for the straight cylindrical length, and h for liquid depth measured upward from the bottom.

  2. 2. Find the circular segment

    Calculate the cross-sectional area filled in the cylindrical section at depth h.

  3. 3. Add the end volume

    For a horizontal capsule, add the submerged spherical-cap volume from the two hemispherical ends.

  4. 4. Check the limits

    The result should be zero when empty and equal the full capsule volume when h equals 2r.

A capsule tank is commonly modeled as a cylinder with a hemisphere attached at each end. For a horizontal tank filled to depth hh, the liquid occupies a circular segment along the cylindrical section and a spherical-cap-shaped portion across the two rounded ends.

Let rr be the inside radius and LL the length of the straight cylindrical section. The formula below gives volume for any fill depth from empty to full. If the tank is vertical, the calculation is different; that case is covered below.

Formula for a horizontal capsule tank

First calculate the area of the liquid segment in a circular cross-section of radius rr:

A(h)=r2arccos⁡(r−hr)−(r−h)2rh−h2.A(h)=r^2\arccos\left(\frac{r-h}{r}\right)-(r-h)\sqrt{2rh-h^2}.

The two hemispherical ends together make one sphere of radius rr. The volume of its portion below the liquid level is a spherical cap:

Vends(h)=πh2(r−h3).V_{\text{ends}}(h)=\pi h^2\left(r-\frac{h}{3}\right).

Therefore, the partial volume is

V(h)=L[r2arccos⁡(r−hr)−(r−h)2rh−h2]+πh2(r−h3),0≤h≤2r.V(h)=L\left[r^2\arccos\left(\frac{r-h}{r}\right)-(r-h)\sqrt{2rh-h^2}\right]+\pi h^2\left(r-\frac{h}{3}\right), \qquad 0\le h\le 2r.

Use consistent units throughout. For example, if rr, LL, and hh are in metres, the answer is in cubic metres.

Worked example

Suppose a horizontal capsule tank has radius r=1 mr=1\text{ m}, straight cylindrical length L=4 mL=4\text{ m}, and liquid depth h=0.5 mh=0.5\text{ m}.

The filled cross-sectional area of the cylindrical portion is

A(0.5)=arccos⁡(0.5)−0.50.75=π3−34≈0.6142 m2.\begin{aligned} A(0.5)&=\arccos(0.5)-0.5\sqrt{0.75}\\ &=\frac{\pi}{3}-\frac{\sqrt{3}}{4}\\ &\approx 0.6142\text{ m}^2. \end{aligned}

The cylindrical portion contains approximately 4(0.6141848)=2.4567 m34(0.6141848)=2.4567\text{ m}^3. The end portion contains

Vends=π(0.5)2(1−0.53)=5π24≈0.6545 m3.V_{\text{ends}}=\pi(0.5)^2\left(1-\frac{0.5}{3}\right)=\frac{5\pi}{24}\approx0.6545\text{ m}^3.

So the total liquid volume is approximately

V(0.5)=2.4567+0.6545=3.1112 m3.V(0.5)=2.4567+0.6545=3.1112\text{ m}^3.

The full capacity is πr2L+43πr3\pi r^2L+\frac{4}{3}\pi r^3, which is about 16.7552 m316.7552\text{ m}^3 for these dimensions. The example tank is therefore about 18.6% full.

If the tank is vertical

For a vertical capsule, the ends are at the bottom and top rather than at the sides. Let hh be the liquid height measured from the bottom, and keep LL as the straight cylindrical length. The total height is L+2rL+2r. The volume is piecewise:

V(h)={πh2(r−h3),0≤h≤r,23πr3+πr2(h−r),r<h≤r+L,23πr3+πr2L+πy(r2−y23),r+L<h≤2r+L,V(h)= \begin{cases} \pi h^2\left(r-\frac{h}{3}\right), & 0\le h\le r,\\[4pt] \frac{2}{3}\pi r^3+\pi r^2(h-r), & r<h\le r+L,\\[4pt] \frac{2}{3}\pi r^3+\pi r^2L+\pi y\left(r^2-\frac{y^2}{3}\right), & r+L<h\le 2r+L, \end{cases}

where y=h−(r+L)y=h-(r+L) in the final case. The three cases describe filling the lower hemisphere, then the cylindrical section, then the upper hemisphere.

Common mistakes

  • Using the overall tank length as LL. If the measured tip-to-tip length is DD, then the straight cylindrical length is L=D−2rL=D-2r.
  • Mixing units. Convert all lengths to the same unit before calculating; otherwise the volume will be inconsistent.
  • Measuring depth from the center. In the horizontal formula, hh is measured upward from the inside bottom, so it ranges from 00 to 2r2r.
  • Using a horizontal formula for a vertical tank. The amount of liquid in each end changes differently with height, so use the piecewise expression for a vertical orientation.

As a useful check, at half depth, h=rh=r, a horizontal capsule is exactly half full by symmetry. At h=0h=0 the formula gives zero, and at h=2rh=2r it gives the full capacity πr2L+43πr3\pi r^2L+\frac{4}{3}\pi r^3.

Spotted an error? Send a correction. Read how we write and check articles in our editorial policy.