what is the function that the same as perms however can used *n* more than 10? [on hold]

Multi tool use
what is the function that the same as perms however can used *n* more than 10? [on hold]
when i build a coding i used n less than 10, i used perms function.. then when get the correct coding the i test the coding in various size of n, which is n more than 10, however the length for perm is less than 10. what is the same function as perm, but can used for n more than 10?
the example of my coding
f=[ 0 1 2 2 3 4 4 5 3 5 6 7 8 9 7 8;
1 0 1 1 2 3 3 4 2 4 5 6 7 8 6 7;
2 1 0 2 1 2 2 3 1 3 4 5 6 7 5 6;
2 1 2 0 1 2 2 3 3 3 4 5 6 7 5 6;
3 2 1 1 0 1 1 2 2 2 3 4 5 6 4 5;
4 3 2 2 1 0 2 3 3 1 2 3 4 5 3 4;
4 3 2 2 1 2 0 1 3 1 2 3 4 5 3 4;
5 4 3 3 2 3 1 0 4 2 1 2 3 4 2 3;
3 2 1 3 2 3 3 4 0 4 5 6 7 8 6 7;
5 4 3 3 2 1 1 2 4 0 1 2 3 4 2 3;
6 5 4 4 3 2 2 1 5 1 0 1 2 3 1 2;
7 6 5 5 4 3 3 2 6 2 1 0 1 2 2 3;
8 7 6 6 5 4 4 3 7 3 2 1 0 1 1 2;
9 8 7 7 6 5 5 4 8 4 3 2 1 0 2 1;
7 6 5 5 4 3 3 2 6 2 1 2 1 2 0 1;
8 7 6 6 5 4 4 3 7 3 2 3 2 1 1 0 ];
d=[
0 3 4 6 8 5 6 6 5 1 4 6 1 5 4 5;
3 0 6 3 7 9 9 2 2 7 4 7 9 6 3 2;
4 6 0 2 6 4 4 4 2 6 3 6 5 6 2 6;
6 3 2 0 5 5 3 3 9 4 3 6 3 4 7 8;
8 7 6 5 0 4 3 4 5 7 6 7 7 3 3 3;
5 9 4 5 4 0 8 5 5 5 7 5 1 8 5 4;
6 9 4 3 3 8 0 6 8 4 6 7 1 8 5 6;
6 2 4 3 4 5 6 0 1 5 5 3 7 5 9 4;
5 2 2 9 5 5 8 1 0 4 5 2 4 5 4 5;
1 7 6 4 7 5 4 5 4 0 7 7 5 6 5 5;
4 4 3 3 6 7 6 5 5 7 0 9 6 5 1 8;
6 7 6 6 7 5 7 3 2 7 9 0 6 5 4 5;
1 9 5 3 7 1 1 7 4 5 6 6 0 5 7 4;
5 6 6 4 3 8 8 5 5 6 5 5 5 0 5 3;
4 3 2 7 3 5 5 9 4 5 1 4 7 5 0 8;
5 2 6 8 3 4 6 4 5 5 8 5 4 3 8 0];
[r,c]=size(f);
max_i= r;
max_j =r;
max_k= r;
max_n= r;
A=zeros(r,r);m=0;
ID=perms([1:r]);
x=zeros(r,r);
n=length(ID);
Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.
so does it mean that i cannot solve the problem above because of the large of n?
– shuthairah
Jul 3 at 5:53
@shuthairah you haven't told us what problem you're trying to solve, there may be a way to solve it without using this method
– Wolfie
Jul 3 at 10:43
Dear @wolfie i want to solve quadratic assignment problem.. the QAP dataset start with n=12...is there another way i can do ?
– shuthairah
Jul 8 at 12:55
the number of permutations is defined as n! / (n - r)! and for 10 it already 3628800, so it is likely to take too much memory for MATLAB in normal computer system ... stackoverflow has many examples of perms function in c-code ... this will help you.
– bhamadicharef
Jul 3 at 5:32