getNodeRanking function

Sorting of the nodes from upstream to downstream for RunModel and Calibration