Lexicographically next permutations