# Completely unique set in permutation

I have tried searching online for the answer and can't quite get one for my specific problem. My use of terminology is probably not helping (I don't study math). I think I know the answer but would like confirmation and possibly someone to point me to a website online/code/or technique that could achieve this.

I want to find each unique order of numbers from 1 to 12, out of all possible combinations. So, 12! means I can have a very large number of combinations. What I want to get are the ones that are completely unique to one another, i.e., they do not have any numbers that follow the same series in the set. For example,

1,2,3,4,5,6,7,8,9,10,11,12
2,4,6,8,10,12,1,3,5,7,9,11
3,6,9,12,2,5,8,11,1,4,7,10
4,8,12,2,6,10,3,7,11,1,5,9


All of these numbers are different permutations of the same series (1-12) but if you look at the second last two 1 follows from 11, in both cases. I want to avoid all instance of this.

If my thinking is correct (but please tell me if I'm wrong) out of all possible permutations, there will only be 12 sets of numbers that meet my requirements. As you'll know 12! is a very big number, I'm finding it challenging to write out the 12. I tried thinking of a systematic way to change how I write it out but I found a couple times there would be somewhere that repeated a small sequence (as above), I suspect my approach was slightly flawed and I need to change how I counted. I tried counting along by the value of first number in each row. So first row by 1, second by 2, and so on. I think it went wrong when I reached my maximum number (12) and had to got to the start of the series with the numbers left.

What I want to know is: 1. Am I correct in thinking there will only be 12 sets of numbers that meet what I'm looking for, and 2. is there anywhere online I can type the number to get those back/or maybe there is a technique to do it by hand like I tried.

Thanks

Here's one set of "completely" unique permutations $f_1, f_2, \ldots f_{12}$:

$$f_n(x) = n\cdot x \bmod 13$$

So we have:

 n=1:  1  2  3  4  5  6  7  8  9 10 11 12
n=2:  2  4  6  8 10 12  1  3  5  7  9 11
n=3:  3  6  9 12  2  5  8 11  1  4  7 10
n=4:  4  8 12  3  7 11  2  6 10  1  5  9
n=5:  5 10  2  7 12  4  9  1  6 11  3  8
n=6:  6 12  5 11  4 10  3  9  2  8  1  7
n=7:  7  1  8  2  9  3 10  4 11  5 12  6
...
n=12: 12 11 10  9  8  7  6  5  4  3  2  1


This only works because $12+1$ is a prime number, however.

For example, there is no set of 3 "completely unique" permutations of $\{1,2,3\}$. At most one of the permutations 123, 231, and 312 can appear, and at most one of the permutations 321, 213, and 132 can appear. But together these are all the possible permutations of $\{1,2,3\}$ so there's nowhere to get a third "completely unique" one from.

• Could you elaborate a bit more. It might be that I didn't make it clear. All I care is that the next number following from the previous isn't found anywhere else (which does seem to be what you show). It is specifically the last bit you post that confuses me. Can you not say 123, 213, 312 are three completely unique permutations? – user69247 Jun 26 '14 at 19:35
• @user69247: Not unless I'm misunderstanding what you mean by "completely unique", because two of your permutations has 1 followed by 2. – hmakholm left over Monica Jun 26 '14 at 19:58
• Sorry, I understand what you mean now. I know what you are on about. I made a mistake with my 123 example as well and then thought your next reply referred to my 1-12 example in my post. – user69247 Jun 26 '14 at 20:24