suppose I have 6$\{0,1,2,3,4,5\}$ numbers.I should generate following 4 pairings of numbers where there will be 3 pairs in each pairing s.t
each number should be in one pair and also every number should be paired
a pair(like 0-1) should be present in only one of the pairing. and also every possible pair should be present somewhere
i) 0-1 , 2-3 ,4-5
ii) 0-4 , 1-2 ,3-5
iii) 0-3 , 1-4 ,2-5
iv) 0-2 , 1-5 ,3-4
v) 0-5 , 1-3 ,2-4
similarly if I have N numbers. I need $(N-1)$ pairing of numbers s.t in each pairing there are $N/2$ pairs.
essentially this is grouping $\binom{n}{2}$ combinations into $n-1$ groups s.t each number is present exactly once in each group
[(0, 1), (2, 3), (4, 5)]
, though you could just as well start with[(0, 1), (2, 4), (3, 5)]
or[(0, 1), (2, 5), (3, 4)]
. Depending on your first choice, the other choices are restricted. Does that matter? $\endgroup$