There are several numerical method to solve piping networks problems, they are theory linear method, newton-rhapson method, hardy cross method, gradient algorithma method and others.
Basicly, their algorithm are the same. The diffrence is each method use different equation (head equation, flow...