Generate permutations of a set of vectors under flag control. The flags are 'all' (n factorial), even', 'odd', 'cycles', 'signs'. Combinations can be used. The flag 'unique' will remove duplicate entries. This file is a compatible extension of MATLAB perms(vec) where vec is a row vector. See also uniqueperms FEX # 18918.
Bill McKeeman (2021). perms (https://www.mathworks.com/matlabcentral/fileexchange/10237-perms), MATLAB Central File Exchange. Retrieved .
This function does not seem to run on current Matlab versions anymore (Matlab R2019b on OSX 10.14.6).
I managed to make it run with some very slight code adjustments only. Although, I cannot validate whether it is working perfectly as intended now.
In general, the use of nested functions and pseudo global variables is bad style and very difficult to read.
The version of perms has a bug. It sometimes gives the even permutations instead of the odd permutations and vice versa. It has been corrected and reissued as FX32978. This version, FX10237 should soon be deleted.
can you please teach me about the dmperm function which calculate the permulation of adajancy matrix.
Please explain this function with example.
Find the treasures in MATLAB Central and discover how the community can help you!Start Hunting!