Functions | |
if (n==1) A | |
A (Bidx, 1:n-1) | |
A (k+Bidx, i+1:n) | |
endfor | A (k+Bidx, 2:n) |
Variables | |
function | A |
endif | v = v(:) |
n = length (v) | |
else | B = perms (v(1:n-1)) |
Bidx = 1:size (B, 1) | |
k = size (B, 1) | |
for | i |
A | ( | k+ | Bidx, | |
i+1:n | ||||
) |
A | ( | Bidx | , | |
1:n- | 1 | |||
) |
if | ( | n | = =1 |
) |
A |
Initial value:
perms (v) if (nargin != 1) print_usage ()
n = length (v) |
endif v = v(:) |