The guide
A closing valve turns moving water into a pressure wave, and the pipe decides how hard it hits
Why stopping flow suddenly makes a surge, why a stiffer pipe hits harder, why a slow closure is far gentler, and why the pressure can swing below zero after the first pulse.
- 1192.4 m/s wave speed in the worked steel pipe, not 1484.6 m/s
- 2.381 MPa Joukowsky rise for a 2 m/s stop, 23.81 bar
- 1.677 s critical time 2L/a for the 1,000 m pipe
- 199.6 kPa rigid-column estimate for a 10 s closure
- -2.381 MPa the low half of the swing after one round trip
Read the full guide Fold the guide
Close a tap quickly and the pipe behind it may bang. The sound is a pressure wave. The water that was moving had momentum, the valve took it away in a moment, and the energy had nowhere to go but into the water and the pipe wall.
The Hydraulic shock page, where “water hammer” redirects, describes it this way: a surge caused when a fluid in motion is forced to stop or change direction suddenly. It lists noise and vibration at one end and pipe rupture and collapse at the other. This essay works one example through, in plain numbers, so that you can see what sets the size of the blow.
The speed of the wave
The example is water in a steel pipe, 0.5 m inside diameter, 10 mm wall, 1,000 m long. The flow is 2 m/s and the valve stops it. Everything below can be reproduced on the page.
A pressure wave in a liquid moves at the speed of sound in that liquid, which is the square root of the bulk modulus divided by the density. For water with a bulk modulus of 2.2 GPa, the figure the Bulk modulus page lists for water, and a density of 998.2 kg/m^3, that gives 1484.6 m/s. The Speed of sound page quotes 1481 m/s for fresh water at 20 degrees Celsius. The small gap is because 2.2 GPa is itself rounded, and the page uses its own computed value.
But water in a pipe is not water in the open. The wall swells a little as the pressure passes, and that softens the system and slows the wave. The page uses the Korteweg form: the speed falls by the square root of one plus the pipe term, where the term is c K D / (E t). For steel, whose Young’s modulus the Young’s modulus page lists as about 200 GPa, and c set to 1.0, the term is 0.550 and the wave speed is 1192.4 m/s.
The constraint factor c deserves a comment. The Hydraulic shock page calls it a dimensionless parameter due to the pipe-constraint condition and marks the explanation as unclear. The tool therefore says plainly that 1.0 is an assumption, and lets you change it.
The page also prints the equivalent bulk modulus with an extra factor (1 + V/a). Applied to this example, with V taken as the 2 m/s velocity change, it lowers the wave speed to 1191.44 m/s, 0.084 percent below the Korteweg value. The tool uses the Korteweg form and shows the difference, so neither figure is hidden.
How hard it hits
For a valve that closes at once, the pressure rise is the density times the wave speed times the change in velocity. This is the Joukowsky equation, which the page names alongside Zhukovsky. Here: 998.2 x 1192.4 x 2 = 2,380,588 Pa, or 2.381 MPa. In other units that is 23.81 bar and 345.3 psi.
Using the unconfined sound speed of 1484.6 m/s instead would give 2.964 MPa, an overstatement of about a quarter. Mixing units is worse. One bar is 100,000 Pa, and the Pressure page lists bar among the units in common use, so a figure read in bar and used as pascals is wrong by five orders of magnitude.
A stiffer pipe hits harder because the wave is faster and the rise is proportional to it. Take the same pipe in a plastic with a hypothetical modulus of 3 GPa, a comparison value and not a data sheet. The pipe term climbs to 36.7, the wave speed falls to 241.9 m/s and the rise to 0.483 MPa, a fifth of the steel figure.
The Cylinder stress page helps explain why wall thickness matters in the term. It states the thin-wall assumption: a wall no thicker than about a tenth of the radius, where the wall can be treated as a surface. Within that limit a thinner wall swells more and slows the wave. The tool warns when a wall is thicker than that limit. Real pipes are usually specified by a nominal diameter and a schedule that sets the thickness, as the Pipe (fluid conveyance) page notes, so the wall is a number you look up, not a free choice.
One result surprises people: the rise does not depend on the pipe length. A short pipe and a long one see the same Joukowsky rise for the same change in velocity.
Fast and slow closures
What length changes is time. The pressure wave runs to the far end and back in 2L/a. For this pipe that is 2 x 1,000 / 1192.4 = 1.677 s, the critical time, and the period of the full cycle is 4L/a = 3.354 s.
If the valve closes in that time or less, the reflected wave has not yet returned to ease the pressure, and the full Joukowsky rise applies. If it closes more slowly, the wave from the reservoir comes back while the valve is still closing and cuts the peak.
The Hydraulic shock page gives the rigid-column form for slow closures: the density times the pipe length times the velocity change, divided by the closing time. For a 10 s closure, which is much longer than 1.677 s, that is 998.2 x 1,000 x 2 / 10 = 199,640 Pa, or 199.6 kPa. That is about a twelfth of the Joukowsky value.
Pipe length can turn the same closure from fast to slow. Shorten the pipe to 20 m and close the valve in 0.1 s. Now 2L/a is only 0.0335 s, the closure is three times longer than that, and the estimate is 399.3 kPa, about a sixth of the instant-closure rise.
The rule is rough, and the tool says so. At a closing time of exactly 2L/a it gives half the Joukowsky rise, which is a jump that no real valve produces. Between about 2L/a and a few times that, neither formula is reliable, and a transient solver is the honest answer.
The swing below zero
A pressure wave does not stop at the first pulse. When the rise reaches the reservoir it reflects with the opposite sign, because the reservoir holds its pressure. It returns to the closed valve after one round trip, 2L/a, and the pressure there falls by the same amount below its steady value.
A frictionless run of the method of characteristics shows the pattern. The Method of characteristics page describes the technique as reducing a partial differential equation to ordinary differential equations along characteristic curves. Here, with 200 reaches, a reservoir upstream and an instant closure downstream, the valve pressure rises by 2.381 MPa, swings to -2.381 MPa, and does so again each half period. The first fall appears at 1.681 s against 2L/a = 1.677 s. The 0.004 s difference is one step of the 200-reach grid.
That negative swing is the part chat answers forget. Water cannot hold less than its vapour pressure. The Water (data page) lists 2.336 kPa at 20 degrees Celsius. With a steady gauge pressure of 500 kPa and a standard atmosphere of 101.325 kPa, the room to fall is about 599 kPa. The swing of 2,381 kPa is far larger, so in this example the liquid column would separate.
The Hydraulic shock page describes what follows: vapour forms, the columns of liquid on either side are accelerated into the gap, and their collision causes a large and almost instantaneous rise in pressure. The tool warns when the swing exceeds the room and does not model separation itself.
What the sums leave out
Everything here is one straight elastic pipe, a frictionless fluid, constant properties and an idealised closure. Real systems have friction, air, pumps, branches and valves that do not close linearly. The Hydraulic shock page lists accumulators, expansion tanks, surge tanks and blow-off valves as ways to reduce the effects, and the Surge tank page describes a tank that absorbs sudden rises of pressure.
The same physics can also be put to work. The Hydraulic ram page describes a pump that uses the water hammer effect to lift part of its supply to a higher level.
For design, rating a pipe or choosing a safety device, this page is the wrong tool. It is educational and not advice, and it exists so that the size of a surge, and the reasons for it, are easy to see.
Sources
Every source consulted for this guide. Links checked November 15, 2026.
- Hydraulic shock Wikipedia (CC BY-SA)
- Speed of sound Wikipedia (CC BY-SA)
- Bulk modulus Wikipedia (CC BY-SA)
- Young's modulus Wikipedia (CC BY-SA)
- Water (data page) Wikipedia (CC BY-SA)
- Cylinder stress Wikipedia (CC BY-SA)
- Pipe (fluid conveyance) Wikipedia (CC BY-SA)
- Surge tank Wikipedia (CC BY-SA)
- Hydraulic ram Wikipedia (CC BY-SA)
- Method of characteristics Wikipedia (CC BY-SA)
- Pressure Wikipedia (CC BY-SA)