Skip to content
Tutorials Center
My learning

Topics

Lesson 12 of 46 ยท Conservation Equations and Navier-Stokes

Continuity: Conservation of Mass in a Flow

Derive the continuity equation for a control volume and a small box, see why A1 v1 equals A2 v2 for incompressible flow and test whether a velocity field conserves mass.

Squeeze the end of a garden hose and the water leaves faster. You did not add water; you made the opening smaller, so the same water has to leave at a higher speed. That everyday observation is conservation of mass at work. Because mass can be neither created nor destroyed, whatever flows into a region must either flow out or accumulate inside. Written as an equation, this bookkeeping is the continuity equation, the first of the governing equations of fluid dynamics.

A pipe narrowing from 0.020 m2 to 0.005 m2 with a control volume sketch showing mass in minus mass out
Squeeze the pipe and the speed rises so that the volume flow rate stays constant; the control volume makes the bookkeeping explicit.

What you will learn

  • How to write the mass balance for a control volume.
  • The incompressible result Aโ‚vโ‚ = Aโ‚‚vโ‚‚ and its use for pipes and junctions.
  • The differential form โˆ‚ฯ/โˆ‚t + โˆ‡ยท(ฯu) = 0 and its incompressible version โˆ‡ยทu = 0.
  • How to find a missing velocity component from continuity.

Key terms

Control volume: a fixed region of space through whose boundary fluid can flow.

Mass flow rate แน = ฯ A v: kilograms per second crossing an area A at normal speed v.

Volume flow rate Q = A v: cubic metres per second.

Divergence โˆ‡ยทu: the net outflow of volume per unit volume per unit time.

Mass balance for a control volume

Draw a closed surface in space. The mass inside it is M. Mass can change only because fluid crosses the surface:

dM/dt = แน_in โˆ’ แน_out.

For a steady flow through a duct with one inlet (area Aโ‚, speed vโ‚, density ฯโ‚) and one outlet (Aโ‚‚, vโ‚‚, ฯโ‚‚), nothing accumulates, so แน_in = แน_out:

ฯโ‚ Aโ‚ vโ‚ = ฯโ‚‚ Aโ‚‚ vโ‚‚.

If the density is constant (liquids; gases at low Mach number), ฯ cancels:

Aโ‚ vโ‚ = Aโ‚‚ vโ‚‚ = Q.

The speed is inversely proportional to the cross-section area. Two corollaries: streamlines crowd together where the flow is fast; and at a junction, the incoming flow rates equal the sum of the outgoing: Qโ‚ = Qโ‚‚ + Qโ‚ƒ.

Worked example 1: a pipe contraction

Water enters a pipe of diameter Dโ‚ = 0.10 m at vโ‚ = 2 m/s. It narrows to Dโ‚‚ = 0.05 m. Areas: Aโ‚ = ฯ€ (0.05)ยฒ = 7.85ร—10โปยณ mยฒ, Aโ‚‚ = ฯ€ (0.025)ยฒ = 1.96ร—10โปยณ mยฒ. Flow rate: Q = Aโ‚vโ‚ = 1.57ร—10โปยฒ mยณ/s (15.7 L/s). Exit speed: vโ‚‚ = Q/Aโ‚‚ = 8 m/s. Halving the diameter quadruples the area ratio, so the speed increases by 4 ร— 2 = 8 m/s. Note: the factor is the square of the diameter ratio.

Worked example 2: a branching pipe

A main pipe carries Q = 30 L/s. It splits into two branches. Branch B takes 12 L/s. Branch C then carries 30 โˆ’ 12 = 18 L/s. If branch C has diameter 0.08 m (A = 5.03ร—10โปยณ mยฒ), its speed is 0.018 / 5.03ร—10โปยณ = 3.58 m/s.

Worked example 3: a filling tank

A tank of horizontal area A_t = 1 mยฒ receives 0.5 L/s and loses 0.3 L/s. The mass balance (constant ฯ) gives A_t dh/dt = Q_in โˆ’ Q_out = 0.2 L/s = 2ร—10โปโด mยณ/s, so dh/dt = 2ร—10โปโด m/s: 0.72 m per hour.

Continuity at a point

Shrink the control volume to a tiny box with sides dx, dy, dz. Net mass outflow per unit time through its faces, divided by the box volume, is โˆ‡ยท(ฯu). The rate of change of mass per unit volume is โˆ‚ฯ/โˆ‚t. The local mass balance is therefore

โˆ‚ฯ/โˆ‚t + โˆ‡ยท(ฯu) = 0 (continuity equation, any fluid).

Expanding the divergence of a product gives Dฯ/Dt + ฯ โˆ‡ยทu = 0. A fluid particle's density changes only if the flow diverges or converges. For an incompressible flow, Dฯ/Dt = 0 and so

โˆ‡ ยท u = โˆ‚u/โˆ‚x + โˆ‚v/โˆ‚y + โˆ‚w/โˆ‚z = 0.

This is exactly the divergence test of the previous lesson: it says each fluid particle keeps its volume. It does not say that the density is uniform in space (layers of salt water of different density can coexist), only that it does not change following a particle.

Worked example 4: finding a missing component

In a 2D incompressible flow, u = 2x (fluid is stretched in x). What is v? From โˆ‚u/โˆ‚x + โˆ‚v/โˆ‚y = 0: 2 + โˆ‚v/โˆ‚y = 0, so v = โˆ’2y + f(x), where f(x) is an unknown function (it does not change โˆ‚v/โˆ‚y). If v = 0 at the wall y = 0, then f(x) = 0 and v = โˆ’2y. This is the stagnation flow seen earlier.

Common misconceptions

"Incompressible means constant density everywhere." It means constant density following each particle. A stratified ocean is incompressible but has density varying with depth.

"Continuity says the speed is the same everywhere." The opposite: continuity says the speed changes wherever the cross-section changes.

"Continuity is the same as Bernoulli." Continuity is conservation of mass and involves no forces. Bernoulli (chapter 4) comes from energy or momentum and links speed to pressure.

Try it

First, a duct whose radius dips to half its value at a throat. We apply v = Q/A along the duct and plot both the shape and the speed. At the throat the area has fallen to a quarter, so the speed is four times higher.

Python Speed along a throat

Press Run (or Ctrl + Enter) to see the result here.

Program input ยท what you'd type while the program runs

Type the answers before you press Run, one per line. Each time the program reads a line (with input()), it gets the next line from this box.

Second, an interactive pipe. Move the sliders to change the two diameters and the inlet speed; the numbers and the arrow lengths follow continuity.

Continuity calculator

Check your understanding

Quick check ยท 5 questions

of 5 answered You scored / 5 ยท perfect!

  1. 1. Water flows at 1.5 m/s in a pipe of cross-section 0.02 m2. It enters a section of 0.005 m2. The new speed is

    v2 = A1 v1 / A2 = 0.02 x 1.5 / 0.005 = 6 m/s.
  2. 2. If a pipe's diameter is halved, the speed of an incompressible flow in it

    Area scales with diameter squared, so halving the diameter reduces the area to a quarter and quadruples the speed.
  3. 3. The incompressible continuity equation says

    div u = 0: each fluid particle keeps its volume.
  4. 4. For a 2D incompressible flow with u = 3x, which v satisfies continuity and v = 0 at y = 0?

    du/dx = 3 requires dv/dy = -3, so v = -3y (+ f(x), zero by the boundary condition).
  5. 5. A main flow of 40 L/s splits into two branches. One carries 15 L/s. The other carries

    Q_in = Q_1 + Q_2, so Q_2 = 40 - 15 = 25 L/s.

Summary

  • Mass balance for a control volume: dM/dt = แน_in โˆ’ แน_out.
  • Incompressible steady flow in a duct: Aโ‚vโ‚ = Aโ‚‚vโ‚‚; junctions: flow in = flow out.
  • Differential form: โˆ‚ฯ/โˆ‚t + โˆ‡ยท(ฯu) = 0; incompressible: โˆ‡ยทu = 0.
  • Continuity determines a missing velocity component, but it says nothing about forces or pressure.

Next: Stress and Viscosity