add new procedure SortPermutation and test