Wolfram Function Repository
Instant-use add-on functions for the Wolfram Language
Function Repository Resource:
Test whether a permutation equals its inverse
ResourceFunction["PermutationInvolutionQ"][p] tests whether a permutation p equals its inverse. |
A permutation involution with 1↔2, 3↔4:
| In[1]:= |
| Out[1]= |
The permutation {2,3,1} is not an involution because 1↦2↦3≠1:
| In[2]:= |
| Out[2]= |
Test if a permutation in disjoint cyclic format is an involution:
| In[3]:= |
| Out[3]= |
These are the 10 involutive permutation on 4 elements, shown compactly:
| In[4]:= |
| Out[4]= |
This work is licensed under a Creative Commons Attribution 4.0 International License