runtime: function to compute number of discs needed to represent corridor for a path.