ordered pairs

*To*: mathgroup at smc.vnet.net*Subject*: [mg7181] ordered pairs*From*: "w.meeussen" <w.meeussen.vdmcc at vandemoortele.be>*Date*: Wed, 14 May 1997 01:11:15 -0400 (EDT)*Sender*: owner-wri-mathgroup at wolfram.com

hi all, Is there a predefined function in Mma 3.0 to construct the complete set of ordered pairs of numbers 1 to n corresponding to the partitions of n in pairs? example: n=6 Partitions[6,2] {{2,2,2},{2,2,1,1},{2,1,1,1,1},{1,1,1,1,1,1}} for the first partition {2,2,2}, I would like all possible combinations: 12 34 56 ** 12 35 46 ** 12 36 45 13 24 56 ** 13 25 46 ** 13 26 45 14 23 56 14 25 36 ** 14 26 35 15 23 46 15 24 36 15 26 34 16 23 45 16 24 35 16 25 34 where each pair is ordered, and the pairs themselves are ordered according to the first element. and analogously for the other partitions. These are obviously not the Young Tableaux from DiscreteMath`Combinatorica`; that gives: Tableaux[{2,2,2}] {{{1,4},{2,5},{3,6}}, {{1,3},{2,5},{4,6}}, {{1,2},{3,5},{4,6}}, {{1,3},{2,4},{5,6}}, {{1,2},{3,4},{5,6}}} they are a small subset of what i want, marked with an asterix above. If there is no pre-defined (combination of) function(s), any hints as to the way how to tackle this procedurally? wouter. Dr. Wouter L. J. MEEUSSEN eu000949 at pophost.eunet.be w.meeussen.vdmcc at vandemoortele.be