Gas networks
Network solver
Any topology — loops, multiple sources, compressors, regulators. Devices that run out of capability are reported rather than silently obeyed: a regulator whose upstream pressure has collapsed is wide open and no longer controlling, and saying so is the point.
Load a network
Typing four nodes is a demonstration; a real gathering system has fifty. JSON round-trips a whole case including gas properties. CSV takes one file with a `record` column marking each row as a node or a branch, which is what comes out of a spreadsheet.
The network
The schematic is the model: drag to arrange it, click a node or a pipe to edit it, double-click a node then click another to lay a pipe between them. Once it solves, node colour is pressure on one scale end to end, pipe width is flow, pipe colour is velocity against the erosional limit, and the flow marches at the gas's own speed.
Gas and correlation
Nodes
| ID | Name | Type | P (psia) | Demand | Elev (ft) | |
|---|---|---|---|---|---|---|
| 0 | ||||||
| 1 | ||||||
| 2 | ||||||
| 3 |
Demand is MMscfd withdrawn. A node with zero demand is a pure junction.
Branches
Set a device to turn a branch into control equipment. A compressor holds its setpoint as a discharge pressure; a regulator holds it downstream. Diameter and length are ignored for those.
| Name | From | To | Device | Ø in | mi | Setpoint | |
|---|---|---|---|---|---|---|---|