Skip to main content

Network Flow

Learn Network Flow (Graphs, Advanced DSA) with worked examples, diagrams and interview questions. Free on JavaSchoolLab.

Network Flow: Capacities and Flow A flow network is a directed graph where each edge has a capacity , with a source s and a sink t . A flow sends an amount along each edge so that: (1) capacity : 0 ≤ flow(u,v) ≤ capacity(u,v) ; (2) conservation : at every vertex except s and t, what flows in equals what flows out. The value of the flow is what leaves s. Pipes, traffic and data networks are all flow problems.

More lessons in Graphs