Hydraulic

Sizing a multi-branch pumping network solved by Newton-Raphson

In a network with one pump and several branches, the flow does not split the way you would expect: it settles on its own until the pressure at every take-off point is unique. Solving this requires Newton-Raphson, with mass conservation at the nodes and energy conservation along the pipes.

When to use

Use this when a single pump feeds several simultaneous demand points — cooling loops, industrial water distribution, drip irrigation, fire-fighting networks, multi-machine supply — and you need to know how much flow reaches each branch and what pressure is available at each take-off. Unlike a single-segment calculation, here the branch flow rates are interdependent: opening one affects all the others. The sizing determines the actual pump operating point, the flow rate of each branch, the pressure at each node, and how much local loss (orifice plate) must be added to balance the favored branches.

The branched-network problem

When a single pump feeds several demand points at once, a problem arises that sizing an isolated segment never captures: the branch flow rates are interdependent. Opening or closing one branch changes the pressure at the take-off node, and that change redistributes flow among all the others. There is no such thing as “the flow of branch 3” computable in isolation — there is an equilibrium state of the entire network that must be found all at once.

The common intuition — split the pump flow evenly, or in proportion to the pipe area — is wrong. Flow distributes according to the hydraulic resistance of each path: short, wide, low-elevation branches carry more; long, narrow, high ones carry less. What is equal among them is not the flow rate, it is the pressure at the point where they branch off.

The two physical principles

The solution rests on two classic pillars, the same ones used in water-supply network analysis:

  • Mass conservation at the nodes. At every internal node, the sum of the inflows equals the sum of the outflows (Σ Q_in = Σ Q_out). This is the hydraulic form of Kirchhoff’s first law. An incompressible fluid does not accumulate.
  • Energy conservation along the segments. Along each pipe, the piezometric head drops by the Darcy-Weisbach head loss: h_f = f·(L/D)·(v²/2g) + ΣK·(v²/2g). The friction factor f follows the Colebrook-White method (Serghides in the turbulent regime, laminar below Re 2000, cubic transition between them).

The catch complicates the problem: because h_f ∝ Q², the equations are nonlinear. There is no closed-form formula for the flow split. That is why an iterative method is required.

How Newton-Raphson solves the network

The solver assembles an unknown vector holding the flow rate of each segment and a residual vector F(Q) that gathers all the equations that must hold at equilibrium:

  1. Continuity residuals — one per internal node: Σ Q_in − Σ Q_out. When it is zero, mass is conserved there.
  2. Pressure residuals — one per leaf branch: H_node(Q) − (z + P_min). When it is zero, the consumer receives exactly the required pressure.

At each iteration, the algorithm:

  1. Propagates head from the pump: H_out = z_level + H_pump(Q_tot) − h_suction(Q_tot), and descends the network by subtracting the loss of each segment down to every consumer. The pump curve H_pump(Q) comes from a 3-point Lagrange fit of the catalog.
  2. Evaluates the residuals F(Q) with the current flow rates.
  3. Assembles the Jacobian J = ∂F/∂Q by central finite difference, perturbing each flow rate up and down.
  4. Solves the Newton step J·ΔQ = −F by Gaussian elimination with partial pivoting and updates the flow rates.
  5. Damps the step (line search): if the full step does not reduce the residual norm, the factor is shrunk until it does — ensuring robustness when the initial guess is far off.

The iteration stops when ‖F‖ < 1e-7, which usually happens in 5 to 15 steps. Because Q_total is one of the unknowns, the pump slides along its own curve during convergence: the actual operating point is not imposed, it emerges from the joint solution of pump and network.

Unreachable branches and balancing

Not every branch receives flow. If a consumer sits too high or too far for the available head, the solution would tend toward a negative flow rate — physically impossible. The solver detects these branches (flow dropping to near zero), marks them as unreachable, and recomputes the equilibrium with the remaining branches, instead of producing a meaningless result. In practice this signals that the pump is undersized or that the point needs its own booster.

At the other extreme is the favored branch, which “steals” flow from the rest. The fix is hydraulic balancing: insert a deliberate local loss — an orifice plate or balancing valve — in the favored branch, sized (via its K) to dissipate the excess pressure and push flow back to the disadvantaged branches. The result is a network where each point receives the design flow, not whatever the accident of geometry would deliver.

Practical design considerations

  • The bottleneck sets the TDH. The pump’s total head is governed by the most unfavorable branch (high, long, narrow), not by the average. Size the pump to guarantee minimum pressure there.
  • Reference velocities: keep the main line between 1.5 and 3.0 m/s and the branches between 1.0 and 2.5 m/s — this controls head loss, noise, and water hammer.
  • The main-line loss is shared: it depends on the sum of the branch flows. That is why you cannot size branch by branch independently.
  • Elevation matters as much as length: two branches with identical piping but different elevations receive different flow rates — the geometric energy enters the balance directly.
  • Re-evaluate when the configuration changes: switching branches on/off changes Q_total, shifts the pump operating point, and redistributes everything. The calculation must be redone, not scaled.

In short: sizing a multi-branch network means finding the equilibrium state in which mass is conserved at every node and energy is conserved in every pipe, simultaneously. Newton-Raphson delivers that state — the flow of each branch, the pressure at each node, and the pump’s actual operating point — and reveals where balancing is needed so the design does what it promises.

Formulas and fundamentals

Mass conservation at a node (Kirchhoff's first law, hydraulic form) Σ Q_in(node) − Σ Q_out(node) = 0

At every internal take-off node, the sum of the inflows equals the sum of the outflows (incompressible fluid, no accumulation). For a network with N internal nodes, this yields N continuity equations. It is the first family of residuals in the nonlinear system.

Energy conservation along a segment (Darcy-Weisbach) H_upstream − H_downstream = h_f = f·(L/D)·(v²/2g) + ΣK·(v²/2g)

The piezometric head drops along each pipe through the distributed loss (friction factor f) plus the local loss (fittings and plates, ΣK). Since h_f grows with v² (≈ Q²), the relationship between flow rate and head loss is nonlinear — the root of the problem. f comes from Colebrook-White, solved by the Serghides estimator in the turbulent regime.

Pressure equality at the demand point H_node(Q) = z_consumer + P_min_required

At each leaf branch, the piezometric head that the solver propagates to the consumer must equal the elevation z plus the required minimum pressure (in mH2O). This residual closes the system: it sets how much flow each branch 'draws' so that its delivery pressure is exactly the one required.

Head propagation from the pump H_pump_out = z_level + H_pump(Q_tot) − h_suction(Q_tot)

The head at the pump discharge point is the suction-level elevation plus the head delivered by the pump at total flow Q_tot, minus the loss in the suction line. From that node onward, H propagates into the network by subtracting the head loss h_f of each segment. H_pump(Q) comes from a 3-point Lagrange fit of the catalog curve.

Nonlinear system and the Newton-Raphson step F(Q) = 0 → Q_(k+1) = Q_k − J⁻¹·F(Q_k)

Gathering the continuity and pressure equations, the residual vector F(Q) is assembled with one unknown per segment. Newton-Raphson linearizes via the Jacobian J = ∂F/∂Q (computed by central finite difference) and solves J·ΔQ = −F at each iteration (Gaussian elimination), converging when ‖F‖ < 1e-7.

Standards & methods

  • ABNT NBR 12218 (design of water distribution networks for public supply)
  • ABNT NBR 10844 / NBR 5626 (building services — reference pressures and velocities)
  • Hardy Cross / Newton-Raphson method (steady-state hydraulic network analysis)
  • Colebrook-White (Serghides estimator) — reference head loss and friction factor model
  • Darcy-Weisbach equation with the Serghides estimator on Colebrook-White

Typical reference values

Quantity Typical range Note
Velocity in the main line (discharge) 1.5 to 3.0 m/s Above ~3 m/s, head loss and water hammer grow; below ~1 m/s there is a risk of sedimentation.
Velocity in the take-off branches 1.0 to 2.5 m/s Smaller branches tolerate slightly higher velocity; watch the local loss of the fittings.
Minimum pressure at the demand point 5 to 30 mH2O Depends on the equipment served; sprinklers and showers require the manufacturer's own range.
Convergence tolerance (‖residual‖) < 1e-7 A mix of m³/h (continuity) and mH2O (pressure); the vector norm drops below this limit in a few iterations.
Typical Newton-Raphson iterations 5 to 15 With a reasonable initial guess and damping (line search); the internal cap is 200.
Acceptable imbalance between branches ± 5% to ± 10% of Q_target Beyond that, balance with an orifice plate on the favored branch(es).

Worked example

Pump feeding 3 branches with simultaneous demand

Inputs

Branch A — length / DN
40 / 50 m / mm
Branch B — length / DN
120 / 50 m / mm
Branch C — length / DN
120 / 40 m / mm
Target flow per branch
10 m³/h
Minimum pressure at the consumer
15 mH2O
Pump curve (3 points)
45 / 38 / 28 @ 0 / 20 / 40 mH2O @ m³/h

Results

Total flow at the operating point
≈ 31.5 m³/h
Flow in branch A (favored)
≈ 13.8 m³/h
Flow in branch C (bottleneck)
≈ 8.1 m³/h
Pressure at the take-off node
≈ 33.5 mH2O
Balancing plate on branch A
ΣK ≈ 9

Without balancing, the three branches do not each receive 10 m³/h: branch A, the shortest, carries about 13.8 m³/h, while branch C — longer and narrower — settles around 8.1 m³/h, below target. This happens because the pressure at the take-off node is unique (≈ 33.5 mH2O) and each branch carries as much as its resistance allows while still arriving with the required 15 mH2O. Newton-Raphson finds this equilibrium in a few iterations. To equalize the flows, an orifice plate is inserted in branch A (local loss equivalent to ΣK ≈ 9) that dissipates the excess pressure and pushes flow toward the disadvantaged branches. Branch C is the bottleneck and is the one that dictates the minimum head the pump must deliver.

Run your own calculation Create a free account and get this for your own inputs in seconds.

Common mistakes

  • Splitting the total flow 'equally' among the branches, or by pipe cross-sectional area — the actual flow is set by the pressure balance, not by a fixed ratio.
  • Adding branch head losses independently: the segments share the main line, and its loss depends on the sum of all branch flows.
  • Sizing the pump for the sum of the nominal flows without checking whether there is enough head for the highest/farthest branch — usually the bottleneck that sets the total head (TDH).
  • Ignoring that the most favorable branch (short, low, wide) 'steals' flow from the others; without a balancing plate it receives far more than intended.
  • Forgetting the geometric elevation of each consumer: two branches of identical length but different elevations receive different flow rates.
  • Treating the pump operating point as fixed: when the branch configuration changes, Q_total changes, the pump slides along its curve, and every pressure shifts.

Frequently asked questions

Why can't I simply divide the pump flow by the number of branches?

Because the flow does not split by a fixed ratio. At each take-off node the pressure is unique, and each branch carries exactly the flow rate whose head loss consumes that pressure by the time it reaches the consumer at the required minimum. Short, wide, low branches offer less resistance and 'draw' more flow; long, narrow, high ones receive less. Only a coupled network calculation, conserving mass and energy, gives the true split.

What is the Newton-Raphson method and why is it needed here?

It is an iterative method for solving systems of nonlinear equations. Head loss grows with the square of the flow rate (h_f ∝ Q²), so the network equations are nonlinear and have no closed-form solution. Newton-Raphson starts from an initial guess, linearizes the system through the Jacobian (the matrix of residual derivatives) and corrects the flow rates at each step, until mass and pressure conservation are satisfied within tolerance. It typically converges in 5 to 15 iterations.

How does the calculation guarantee mass and energy conservation at the same time?

They are two families of equations solved together. Mass conservation requires that, at each internal node, the inflow equals the outflow. Energy conservation requires that the piezometric head drop along each pipe by the Darcy-Weisbach loss and that, at the end of each branch, it equal the elevation plus the minimum pressure. The solver gathers both sets of residuals into a single vector F(Q) and drives them to zero simultaneously.

Why does one branch receive much more flow than the others, and how do I fix it?

The favored branch — shorter, larger in diameter, or at a lower elevation — has lower resistance, so it carries more flow for the same pressure drop at the node. The fix is hydraulic balancing: a deliberate local loss (orifice plate, balancing valve) is inserted in the favored branch, sized to dissipate the excess pressure and redistribute flow to the disadvantaged branches, equalizing the deliveries.

How many branches does the tool solve and what limits that number?

The network accepts one pump, the main line, and up to 20 branches, which can even be hierarchical (a parent branch grouping sub-branches). The limit is practical: each segment adds an unknown and the Jacobian grows, but the Gaussian elimination at each iteration solves systems of that size instantly. Branches that cannot get enough pressure are detected as unreachable and flagged, rather than producing physically meaningless negative flow.

How does the pump enter the network calculation?

The pump is represented by its H×Q curve, fitted with a 3-point Lagrange polynomial from the catalog. The head at the pump discharge point is the suction-level elevation plus H_pump(Q_total) minus the suction loss. Since Q_total is the sum of all branch flows — one of the unknowns — the pump 'slides' along its curve during iteration: the actual operating point emerges from the joint convergence of pump and network.

Glossary

Node (junction)
A point in the network where pipes meet or branch off. Internal nodes impose mass conservation; demand nodes impose the required minimum pressure.
Branch
A pipe segment leading from the main line (or from another branch) to a demand point. Each branch has its own length, diameter, roughness, elevation, and fittings.
Piezometric head (H)
Energy per unit weight of fluid at a point, in mH2O. It is what propagates through the network from the pump, dropping at each segment by the head loss.
Jacobian
The matrix of partial derivatives of the residuals with respect to the flow rates (∂F/∂Q). In the solver it is computed numerically by central finite difference and used for the Newton step.
Residual
How far each equation (continuity at a node or pressure at a branch) is from zero for a given flow estimate. The solution is found when the norm of the residual vector drops below the tolerance.
Balancing plate
An orifice plate or restriction inserted in a favored branch to create a deliberate local loss, dissipate the excess pressure, and redistribute flow among the branches.