made permutations independent of how many points they fix
improved handling of the identity permutation