1 / 27

Combinatorial generation via permutation languages

Combinatorial generation via permutation languages. Torsten Mütze ( joint work with Liz Hartung, Hung P. Hoang , and Aaron Williams). Introduction. In computer science, we frequently encounter different kinds of combinatorial objects. Examples : binary trees permutations

ktinker
Download Presentation

Combinatorial generation via permutation languages

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Combinatorial generationvia permutation languages Torsten Mütze (jointworkwith Liz Hartung, Hung P. Hoang, and Aaron Williams)

  2. Introduction • In computer science, we frequently encounter differentkinds of combinatorial objects • Examples: • binarytrees • permutations • binarystrings • setpartitions • spanningtrees • … {1234} {123}{4} {12}{34} {12}{3}{4} 000 001 011 1234 1243 1423 • Common tasks: counting + randomsampling + exhaustive generation

  3. Exhaustive generation • Goal:generate all objects of a combinatorialclassefficiently[Knuth, The Art of Computer Programming Vol. 4A] • ultimately: eachnewobject in constanttime • consecutiveobjectsdifferonlyby`smallchanges‘ Gray code • Examples: • binarytreesbyrotations [Lucas, van Baronaigien, Ruskey 93] • permutationsbyadjacenttranspositions(Steinhaus-Johnson-Trotteralgorithm [Johnson 63], [Trotter 62]) • binarystringsbybitflips(binaryreflected Gray code [Gray 53]) • setpartitionsbyelementexchanges [Kaye 76]

  4. Exhaustive generation • manytailormadealgorithms, fewgeneralapproaches [Li, Sawada 09], [Ruskey, Sawada, Williams 12] • cf. generatingfunctionsforcounting[Flajolet, Sedgewick 09] • cf. Markovchainsforrandomsampling • Thiswork: A general framework for exhaustive generation • Results: all aforementionedalgorithms as specialcases+ manynewresultsforotherfamilies of objects • Idea: Encode objects as a subset of permutations of length

  5. Jumps • Jump := move an entry in the permutationacrosssomeneighboringsmallerentries (right orleft) 4 51 3 2 6 4 1 3 2 5 6 • leftjump • right jump

  6. Algorithm J Algorithm J attempts to generate a set of permutations • start with an initialpermutationfrom • in the current permutation, perform a minimal jump of the largest possible value, so that a previously unvisited permutation from is created. • Minimal jump: no shorterjump of the samevalueproduces a permutation in 4 51 3 2 6 7 8

  7. Algorithm J Algorithm J attempts to generate a set of permutations • start with an initialpermutationfrom • in the current permutation, perform a minimal jump of the largest possible value, so that a previously unvisited permutation from is created. {1243,1423,4123,4213,2134} • Example: • minimal jumps • not minimal 1243 1243 4213

  8. Algorithm J Algorithm J attempts to generate a set of permutations • start with an initialpermutationfrom • in the current permutation, perform a minimal jump of the largest possible value, so that a previously unvisited permutation from is created. Stop, if no jump is possible or jump direction is ambiguous. {1243,1423,4123,4213,2134} • Example: 1243 1243 4213 4213 1423 2134 1423 1423 • directionambiguous 4123 4123 • no jumppossible 4213 4213 2134

  9. Algorithm J Algorithm J • If every permutation from is visited and no ambiguityarises, we say that Algorithm J generates(visiting twice is impossible) attempts to generate a set of permutations • start with an initialpermutationfrom • in the current permutation, perform a minimal jump of the largest possible value, so that a previously unvisited permutation from is created. Stop, if no jump is possible or jump direction is ambiguous. • Question: When does Algorithm J generate ?

  10. Tree of permutations • root := emptypermutation • given a permutation of length , itschildrenareobtainedbyinsertingintoeverypossibleposition symbol at leftmostorrightmostposition else depth = allpermutationsof length

  11. Zigzaglanguages • wemayprunesubtreesifftheirrootis • given any such pruned tree, a set of permutationsin depth is called zigzag language symbol at leftmostorrightmostposition else depth = allpermutationsof length

  12. Zigzaglanguages • wemayprunesubtreesifftheirrootis • given any such pruned tree, a set of permutationsin depth is called zigzag language • Examples: • prunenothing: • pruneeverythingpossiblepermutationswithoutpeaks

  13. Zigzaglanguages • wemayprunesubtreesifftheirrootis • given any such pruned tree, a set of permutationsin depth is called zigzag language Theorem:Algorithm J generates any zigzag language, using the identitypermutation for initialization. Proof: Induction over the depth. Remark: The number of zigzag languages is enormous

  14. Examples permutationswithoutpeaks 234 1234 4123 4312 3124 3214 4321 4213 2134 000 001 011 010 110 111 101 100 1234 12431423 4123 4132 1432 1342 1324 3124 3142 3412 4312 4321 3421 3241 3214 2314 2341 2431 4231 4213 2413 2143 2134 BinaryreflectedGray code (BRGC)![Gray 53] to the right of smallerentries to the left of smallerentries Steinhaus-Johnson-Trotter![Johnson 63][Trotter 62] • not a sublist

  15. General approach Set of permutations Combinatorialobjects • Run Algorithm J List = Algo J( ) List • DirectlyinterpretAlgorithm J under the bijection Algo J Algo J Minimal jumps ‚Small changes‘

  16. Examples permutationswithoutpeaks 234 1234 4123 4312 3124 3214 4321 4213 2134 000 001 011 010 110 111 101 100 BinaryreflectedGray code (BRGC)![Gray 53] List List Algo J Algo J • start with the all-0 string • flip the rightmost bit that creates a new string

  17. „Interesting“ zigzaglanguages • Applications of ourframework • pattern-avoidingpermutations • latticecongruences of the weak order on

  18. Pattern-avoidingpermutations • Def: A permutationcontains a pattern , ifcontains a substring of entries in the same relative order as .Otherwiseavoids . contains 123 534216 avoids 123 654321

  19. Pattern-avoidingpermutations • Def: A permutationcontains a pattern , ifcontains a substring of entries in the same relative order as .Otherwiseavoids . • set of permutationsavoiding . • A patterniscalledtame, if the largestsymbolis not at the leftmostorrightmostposition. 231 123 Theorem:If are all tame patterns, then is a zigzag language.

  20. Pattern-avoidingpermutations Tamepatterns Combinatorialobjects Catalanfamilies 231 • binarytreesbyrotations • triangulationsbyedge flips • Dyck paths by hill flips 231 Set partitions by element exchanges Binarystringsbybitflips (BRGC) 231,132 vincularpattern: positionsmustbeadjacent Diagonal rectangulationsbyflips 2413,3142 Baxter permutations

  21. Baxter permutations Tamepatterns Combinatorialobjects • In addition to classical and vincularpatterns: • bivincularpatterns[Bousquet-Mélou et al. 10] • barredpatterns[West 90] • meshpatterns[Brändén, Claesson 11] • monotone gridclasses[Huczynska, Vatter 06] • geometricgridclasses [Albert et al. 13] • etc. Diagonal rectangulationsbyflips 2413,3142 Baxter permutations

  22. Latticecongruences • Def:weak order on • Inversion set of a permutation:= all pairsforwith • order permutationsbycontainment of inversionsets • cover relations= adjacenttranspositions • the weak order forms a lattice join meet

  23. Latticecongruences • Def: A latticecongruenceis an equivalencerelationrespectingjoins and meets • Latticequotient := latticeinducedbyequivalenceclasses • Remark: The number oflattice congruences on theweak order is enormous • Tamari lattice, boolean lattice, Cambrian lattices [Reading 06]permutreelattices [Pilaud, Pons 18], etc.

  24. Latticecongruences Theorem: For any lattice congruence,there is a set of representatives that formsa zigzag language. Moreover, the resulting jumpordering is a Hamilton path inthe cover graph of the quotient.

  25. Latticecongruences Theorem: For any lattice congruence,there is a set of representatives that formsa zigzag language. Moreover, the resulting jumpordering is a Hamilton path inthe cover graph of the quotient. • [Pilaud-Santos 19] realized those cover graphsas polytopes, called quotientopes.They generalize permutahedra,associahedra, hypercubes etc. Corollary: Every quotientope has a Hamilton path.

  26. Efficient algorithms • greedyalgorithm in itsstated form isveryinefficient(store and look-upexponentiallymanypreviouspermutations) • canmakeitmemoryless • running time in eachstepgivenbymembershiptests in • givespolynomial-timealgorithmforgeneratingpattern-avoidingpermutations • withmoreeffort: evenlooplessalgorithms

  27. Thankyou! • tree of permutations • Gray codefor diagonalrectangulations • Torsten • Liz • Aaron

More Related