pipedream

🚰 Interactive hydrodynamic solver for pipe and channel networks

View the Project on GitHub mdbartos/pipedream

Overview

    â€¢ Governing equations
    â€¢ Model structure

Examples

    â€¢ Flow on hillslope
    â€¢ Simulation context manager
    â€¢ Contaminant transport on hillslope
    â€¢ Uncoupled overland flow
    â€¢ Coupled overland flow
    â€¢ Simple dynamic control example
    â€¢ Adaptive step size control
    â€¢ Validation with real-world network
    â€¢ Kalman filtering with holdout analysis

Reference

    â€¢ Hydraulic solver API reference
    â€¢ Infiltration solver API reference
    â€¢ Water quality solver API reference
    â€¢ Model inputs
    â€¢ Hydraulic geometry reference

Hydraulic model structure

Primary computational elements

The hydraulic model consists of four primary computational elements:

The image below shows a stormwater network consisting of 6 superjunctions and 6 superlinks. Each superlink consists of 5 internal junctions and 4 internal links.

png

Control volumes

Within the hydraulic solver, a staggered-grid discretization scheme is used, in which the continuity equation is applied around each junction and the momentum equation is applied around each link.

Control volume for continuity equation

Note that the left and right edges of the continuity control volume coincide with the midpoints of the upstream and downstream links, respectively.

Control volume for momentum equation

Note that the left and right edges of the momentum control volume coincide with the edges of the upstream and downstream junctions, respectively.

Indexing schemes

There are four primary indexing schemes used by the hydraulic solver, corresponding to the four primary computational elements.

Indexed by superjunction (j)

State variables that are indexed by superjunction include:

For the network shown above, an array corresponding to the superjunction indexing scheme would be of length 6, and appear as:

[f_1  f_2  f_3  f_4  f_5  f_6]

State variables that are indexed by superlink include:

For the network shown above, an array corresponding to the superlink indexing scheme would be of length 6, and appear as:

[f_1  f_2  f_3  f_4  f_5  f_6]

Indexed by junction (Ik)

State variables that are indexed by junction include:

For the network shown above, an array corresponding to the superlink indexing scheme would be of length 30, and appear as:

[ f_1,1  f_2,1  f_3,1  f_4,1  f_5,1
  f_1,2  f_2,2  f_3,2  f_4,2  f_5,2
  f_1,3  f_2,3  f_3,3  f_4,3  f_5,3
  f_1,4  f_2,4  f_3,4  f_4,4  f_5,4
  f_1,5  f_2,5  f_3,5  f_4,5  f_5,5
  f_1,6  f_2,6  f_3,6  f_4,6  f_5,6 ]

Where the first index corresponds to I, the internal junction index, and the second index corresponds to k, the superlink index. Note the above array is one-dimensional (read from left to right, then top to bottom).

State variables that are indexed by junction include:

For the network shown above, an array corresponding to the link indexing scheme would be of length 24, and appear as:

[ f_1,1  f_2,1  f_3,1  f_4,1
  f_1,2  f_2,2  f_3,2  f_4,2
  f_1,3  f_2,3  f_3,3  f_4,3
  f_1,4  f_2,4  f_3,4  f_4,4
  f_1,5  f_2,5  f_3,5  f_4,5
  f_1,6  f_2,6  f_3,6  f_4,6 ]

Where the first index corresponds to i, the internal link index, and the second index corresponds to k, the superlink index. Note the above array is one-dimensional (read from left to right, then top to bottom).