discretize.utils.sub2ind

discretize.utils.sub2ind(shape, subs)[source]

From the given shape, returns the index of the given subscript