%% All Permutations of Complex Numbers

v = [1+1i 2+1i 3+1i];
P = perms(v)

% Copyright 2012 The MathWorks, Inc.