Skip to content
Graphviz (DOT) templates

Pipe Network — Branching

Reservoir feeding a branched supply network with valves and demand nodes.

Template previewGraphviz (DOT)
Rendering…

Make it your own.

digraph pipe {
  rankdir=LR;
  graph [bgcolor=transparent];
  node [shape=box, style="rounded,filled", fontname=Inter, fontsize=10];

  R [label="Reservoir\nh = 50 m", shape=cylinder, fillcolor="#bae6fd"];
  P [label="Pump (15 kW)", fillcolor="#fef3c7"];
  V1 [label="Valve V1"];
  J1 [label="Junction J1", shape=circle, fillcolor="#dbeafe"];
  J2 [label="Junction J2", shape=circle, fillcolor="#dbeafe"];
  D1 [label="Demand 1\n40 L/s", fillcolor="#dcfce7"];
  D2 [label="Demand 2\n25 L/s", fillcolor="#dcfce7"];
  D3 [label="Demand 3\n15 L/s", fillcolor="#dcfce7"];

  R -> P -> V1 -> J1;
  J1 -> D1;
  J1 -> J2;
  J2 -> D2;
  J2 -> D3;
}