For example, the water traveling along a tunnel or pipeline to a turbine in a hydroelectric generating station may be slowed suddenly if a valve in the path is closed too quickly. If there is 14 km (8.7 mi) of tunnel of 7.7 m (25 ft) diameter full of water travelling at 3.75 m/s (8.4 mph),[21] that represents approximately 8,000 megajoules (2,200 kWh) of kinetic energy. This energy can be dissipated by a vertical surge shaft into which the water flows[22] which is open at the top. As the water rises up the shaft its kinetic energy is converted into potential energy, avoiding sudden high pressure. At some hydroelectric power stations, such as the Saxon Falls Hydro Power Plant In Michigan, what looks like a water tower is in fact a surge drum.[23]

where V is the fluid velocity inside pipe, ρ {\displaystyle \rho } is the fluid density, B is the equivalent bulk modulus, and f is the Darcy–Weisbach friction factor.[32]

In residential plumbing systems, water hammer may occur when a dishwasher, washing machine or toilet suddenly shuts off water flow. The result may be heard as a loud bang, repetitive banging (as the shock wave travels back and forth in the plumbing system), or as some shuddering.

where ΔP is the magnitude of the pressure wave (Pa), ρ is the density of the fluid (kg/m3), a0 is the speed of sound in the fluid (m/s), and Δv is the change in the fluid's velocity (m/s). The pulse comes about due to Newton's laws of motion and the continuity equation applied to the deceleration of a fluid element.[28]

Water hammers have caused accidents and fatalities, but usually damage is limited to breakage of pipes or appendages. An engineer should always assess the risk of a pipeline burst. Pipelines transporting hazardous liquids or gases warrant special care in design, construction, and operation. Hydroelectric power plants especially must be carefully designed and maintained because the water hammer can cause water pipes to fail catastrophically.

Column separation is a phenomenon that can occur during a water-hammer event. If the pressure in a pipeline drops below the vapor pressure of the liquid, cavitation will occur (some of the liquid vaporizes, forming a bubble in the pipeline, keeping the pressure close to the vapor pressure). This is most likely to occur at specific locations such as closed ends, high points or knees (changes in pipe slope). When subcooled liquid flows into the space previously occupied by vapor the area of contact between the vapor and the liquid increases. This causes the vapor to condense into the liquid reducing the pressure in the vapor space. The liquid on either side of the vapor space is then accelerated into this space by the pressure difference. The collision of the two columns of liquid (or of one liquid column if at a closed end) causes a large and nearly instantaneous rise in pressure. This pressure rise can damage hydraulic machinery, individual pipes and supporting structures. Many repetitions of cavity formation and collapse may occur in a single water-hammer event.[33]

The Alhambra, built by Nasrid Sultan Ibn al-Ahmar of Granada beginning 1238, used a hydram to raise water. Through a first reservoir, filled by a channel from the Darro River, water emptied via a large vertical channel into a second reservoir beneath, creating a whirlpool that in turn propelled water through a much smaller pipe up six metres whilst most water drained into a second, slightly larger pipe.[4]

Although it was prefigured in work by Thomas Young,[12][11] the theory of water hammer is generally considered to have begun in 1883 with the work of German physiologist Johannes von Kries (1853–1928), who was investigating the pulse in blood vessels.[13][14] However, his findings went unnoticed by civil engineers.[15][16] Kries's findings were subsequently derived independently in 1898 by the Russian fluid dynamicist Nikolay Yegorovich Zhukovsky (1847–1921),[1][17] in 1898 by the American civil engineer Joseph Palmer Frizell (1832–1910),[18][19] and in 1902 by the Italian engineer Lorenzo Allievi (1856–1941).[20]

Hence, we can say that the magnitude of the water hammer largely depends upon the time of closure, elastic components of pipe & fluid properties.[30]

In 1772, Englishman John Whitehurst built a hydraulic ram for a home in Cheshire, England.[5] In 1796, French inventor Joseph Michel Montgolfier (1740–1810) built a hydraulic ram for his paper mill in Voiron.[6] In French and Italian, the terms for "water hammer" come from the hydraulic ram: coup de bélier (French) and colpo d'ariete (Italian) both mean "blow of the ram".[7] As the 19th century witnessed the installation of municipal water supplies, water hammer became a concern to civil engineers.[8][9][10] Water hammer also interested physiologists who were studying the circulatory system.[11]

Hydraulic shock (colloquial: water hammer; fluid hammer) is a pressure surge or wave caused when a fluid in motion is forced to stop or change direction suddenly: a momentum change. It is usually observed in a liquid but gases can also be affected. This phenomenon commonly occurs when a valve closes suddenly at an end of a pipeline system and a pressure wave propagates in the pipe.

This pressure wave can cause major problems, from noise and vibration to pipe rupture or collapse. It is possible to reduce the effects of the water hammer pulses with accumulators, expansion tanks, surge tanks, blowoff valves, and other features. The effects can be avoided by ensuring that no valves will close too quickly with significant flow, but there are many situations that can cause the effect.

On turbocharged internal combustion engines, a "gas hammer" can take place when the throttle is closed while the turbocharger is forcing air into the engine. There is no shockwave but the pressure can still rapidly increase to damaging levels or cause compressor surge. A pressure relief valve placed before the throttle prevents the air from surging against the throttle body by diverting it elsewhere, thus protecting the turbocharger from pressure damage. This valve can either recirculate the air into the turbocharger's intake (recirculation valve), or it can blow the air into the atmosphere and produce the distinctive hiss-flutter of an aftermarket turbocharger (blowoff valve).

As the speed of sound in a fluid is a = B ρ {\displaystyle a={\sqrt {\frac {B}{\rho }}}} , the peak pressure depends on the fluid compressibility if the valve is closed abruptly.

where P1 is the inlet pressure in psi, V is the flow velocity in ft/s, t is the valve closing time in seconds, and L is the upstream pipe length in feet.[29]

Rough calculations can be made using the Zhukovsky (Joukowsky) equation,[1] or more accurate ones using the method of characteristics.

When the valve is closed slowly compared to the transit time for a pressure wave to travel the length of the pipe, the elasticity can be neglected, and the phenomenon can be described in terms of inertance or rigid column theory:

Software packages vary in complexity, dependent on the processes modeled. The more sophisticated packages may have any of the following features:

Water hammer can be analyzed by two different approaches—rigid column theory, which ignores compressibility of the fluid and elasticity of the walls of the pipe, or by a full analysis that includes elasticity. When the time it takes a valve to close is long compared to the propagation time for a pressure wave to travel the length of the pipe, then rigid column theory is appropriate; otherwise considering elasticity may be necessary.[26] Below are two approximations for the peak pressure, one that considers elasticity, but assumes the valve closes instantaneously, and a second that neglects elasticity but includes a finite time for the valve to close.

When a valve with a volumetric flow rate Q is closed, an excess pressure ΔP is created upstream of the valve, whose value is given by the Joukowsky equation:

Steam hammer can occur in steam systems when some of the steam condenses into water in a horizontal section of the piping. The steam forcing the liquid water along the pipe forms a "slug" which impacts a valve of pipe fitting, creating a loud hammering noise and high pressure. Vacuum caused by condensation from thermal shock can also cause a steam hammer. Steam hammer or steam condensation induced water hammer (CIWH) was exhaustively investigated both experimentally and theoretically more than a decade ago because it can have radical negative effects in nuclear power plants.[24] It is possible to theoretically explain the 2 millisecond duration 130 bar overpressure peaks with a special 6 equation multiphase thermohydraulic model,[25] similar to RELAP.

Pressure Reducing Valves and Regulators are designed to protect residential and commercial water distribution systems by controlling excessive pressures. The valves are built for long reliable service with proven ASTM grade materials including a bronze body and stainless steel strainer.  Valves work by cutting down the amount of water which passes through a pipe. Water which is being forced through the pipes at high pressure before the valve will be slowed down after the valve.

Most water hammer software packages use the method of characteristics[28] to solve the differential equations involved. This method works well if the wave speed does not vary in time due to either air or gas entrainment in a pipeline. The wave method (WM) is also used in various software packages. WM lets operators analyze large networks efficiently. Many commercial and non-commercial packages are available.

Water flowing through a pipe has momentum. If the moving water is suddenly stopped, such as by closing a valve downstream of the flowing water, the pressure can rise suddenly with a resulting shock wave. In domestic plumbing this shock wave is experienced as a loud banging resembling a hammering noise. Water hammer can cause pipelines to break if the pressure is sufficiently high. Air traps or stand pipes (open at the top) are sometimes added as dampers to water systems to absorb the potentially damaging forces caused by the moving water.

In the 1st century B.C., Marcus Vitruvius Pollio described the effect of water hammer in lead pipes and stone tubes of the Roman public water supply.[2][3] Water hammer was exploited before there was even a word for it.