Changed variable name from perm_key to permutation_key