Sloshing (Liquid Surface Fluctuation)
Theory: liquid in a container has natural periods
Overview
When I walk carrying a glass of water, it spills badly only at a certain pace. Is that sloshing too?
Exactly. Liquid in a container oscillates at natural periods set by the container size and liquid depth. If the external motion has a similar period it resonates and the surface rises dramatically. Your walking pace for a glass, braking and cornering for a tank truck, earthquakes for an oil tank, attitude control for a rocket — the scales differ but the mechanism is the same.
Natural frequency of a rectangular container
$L$ is the container length in the direction of motion and $h$ the liquid depth. This comes from linear potential theory (irrotational, small amplitude). $\tanh(kh)$ captures the depth effect: close to 1 for deep containers, smaller for shallow ones, lengthening the period.
Cylindrical containers
$R$ is the radius. 1.8412 is the first zero of the Bessel-function derivative $J_1'$, corresponding to the first sloshing mode of a cylinder (the surface rising on one side and falling on the other).
Long-period ground motion and tank fires
In the 2003 Tokachi-oki earthquake, oil tanks in Tomakomai — more than 200 km from the epicentre — sloshed violently, their floating roofs were damaged and fires broke out. Far from the source, short-period shaking weakens, but long-period motion of several seconds decays slowly and is amplified in plains with thick sediments. The natural periods of large tanks sat right in that band, which made the damage severe. The event led Japan to strengthen how long-period motion and sloshing are treated in seismic standards for tanks.
Worked examples
First natural period of various containers
| Container | Dimensions | First natural frequency | Period |
|---|---|---|---|
| Laboratory tank | L = 2 m, h = 1 m | 0.598 Hz | 1.67 s |
| Same tank, shallow | L = 2 m, h = 0.2 m | 0.345 Hz | 2.90 s |
| Tank truck (one compartment) | L = 10 m, h = 1 m | 0.154 Hz | 6.49 s |
| With baffles, three compartments | L = 3.33 m, h = 1 m | 0.415 Hz | 2.41 s |
| Water tower | D = 6 m, h = 5 m | 0.390 Hz | 2.57 s |
| Oil tank | D = 30 m, h = 12 m | 0.166 Hz | 6.04 s |
| Large oil tank | D = 60 m, h = 20 m | 0.113 Hz | 8.83 s |
Baffles shorten the period from 6.5 s to 2.4 s. Wouldn't a shorter period make it worse?
What matters is how it compares with the forcing period. Braking and lane changes excite the liquid at periods of a few seconds, and a long compartment's 6.5 s sits within easy reach of that. Shorter compartments move the natural period away and also reduce the liquid mass per compartment, so the force fed back to the vehicle is smaller. Holes in baffles throttle the flow to damp the motion.
Slosh height during an earthquake
A widely used approximation for the first mode of a cylindrical tank; $S_a(T_1)$ is the spectral acceleration at the first natural period. For a 30 m tank with $S_a = 0.1g$ the surface moves about 1.3 m up and down. Freeboard and floating-roof clearances are set from this value; actual designs follow the formula and coefficients of the applicable standard.
Assessment with CFD
Setting up a VOF analysis
- Free surface: the liquid–gas interface is usually handled with the VOF method. Refine the mesh where the interface travels, to a few percent of the wave height.
- Applying excitation: rather than moving the container, apply the acceleration as an inertial body force in a frame fixed to the container, so the mesh need not move.
- Time step: keep the Courant number below 1 (around 0.5 or less near the interface) so the interface does not cross more than one cell per step — typically several hundred steps per natural period.
- Turbulence and damping: sloshing decays through wall boundary layers and vortices at baffle holes. Excessive numerical diffusion makes the motion die out faster than in reality.
Verification procedure
- Release the liquid from a slight initial tilt, read the natural period from the surface-height history, and compare with the formula; within a few percent means the setup is sound.
- From the same run, extract the damping ratio from the amplitude decay and compare with test or published values.
- Refine mesh and time step to confirm period and damping no longer change, then move on to the real excitation.
In structural analysis, replace it with springs and masses
Seismic design of tanks rarely solves the whole liquid with CFD. Instead, an equivalent mechanical model splits the liquid into an impulsive mass that moves with the tank and a convective mass attached by a spring that sloshes. The approach was set out by Housner in the 1950s, and the spring is tuned to the sloshing period calculated with the formulas in this article. CFD is the tool for large motions or roof impacts that the simple model cannot represent.
Common mistakes
Mistakes and fixes
| Mistake | Effect | Fix |
|---|---|---|
| Dropping the depth factor (tanh) | Periods underestimated in shallow containers | Always include $\tanh(kh)$ |
| Using the wrong length | Large period errors | Use the inside length along the excitation |
| Coarse mesh near the interface | Waves smeared, damping overestimated | Refine where the interface travels |
| Using linear theory for large amplitudes | Breaking and roof impact are missed | Use CFD for large amplitudes |
| Ignoring higher modes | Response to short-period excitation missed | Check periods for $n = 2, 3$ as well |
I'd like to change the container size and see how it sloshes.
Use the sloshing simulator to change container length and depth and watch the period and motion change. Numerical treatment of free surfaces is covered in free-surface flow, and wave computation in VOF wave simulation.
Related Topics
Experience the theory firsthand with the interactive simulator for this field
All Simulators