[GAP Forum] Combination of n objects taken r at a time

Levie Bicua lee_bkua at yahoo.com
Sat Apr 18 23:38:24 BST 2009


Dear forum,
Suppose I have a list of n objects and from this I want to get a new list whose elements are
the combinations of n objects taken r at a time. How will I be able to use gap for this?
Specifically, let S:=[(1,2), (1,3),(2,3)]. If I want to get a list of combinations of these 3
elements taken 2 at a time I must obtain the set T:=[ [(1,2),(1,3)], [(1,3),(2,3)], [(1,2),(2,3)]].
Of course for a larger set it's not easy to do this. Any help? thanks.
 
Levi


      


More information about the Forum mailing list