Revamped the Morton ordering code completely to permit both bottom up and top down indexing.