Sep 18 2010 | 1:26 pm

I'm trying to mathematically produce non redundant, sequential pairs in a list, so if the number is 2 it outputs the list: 1 2 (it would NOT output 1 1 1 2 2 1 2 2). If the incoming number is 3 it outputs: 1 2 1 3 2 3. If 4 output 1 2 1 3 1 4 2 3 2 4 3 4. See the pattern? I need to be able to do this to an incoming number of 52. For prototyping I've just been using coll and did the first 8 or so manually.

I just don't know enough math to understand what this is called, specifically so I can recognize the correct formula. I can build the external (or perhaps there's one or two objects that do the same), no problem. I'm just stuck on the math.

Thanks, would really appreciate any help.