{"license": "CC BY 4.0", "license_url": "https://creativecommons.org/licenses/by/4.0/", "word": {"id": "W-0136", "n": 12, "length": 522736406, "sha256": "6bf1ef85a2cc52add9238329a7c3129e06ef9c0fd76a8dc9d3215a33441a1558", "is_record": true, "tie": false, "letters_saved": 3, "repeated_occurrences": 177523, "credited": [{"name": "Tholsh", "github_username": "Tholsh"}], "date": "2026-11-22T01:45:34Z", "date_precision": "day", "received_at": "2026-11-22T01:45:34Z", "source": "site", "source_url": null, "note": "# A superpermutation of length 522,736,406 on 12 symbols\r\n\r\nFound with the help of ChatGPT\r\n\r\nWe improve the 522,736,409-letter benchmark from Halfar's E selection by three letters, using Pantone's completion construction with a modified native selection. We optimize selection, monodromy, opening phase and placement jointly, rather than minimize charge before arrangement.\r\n\r\n## Finding the selection\r\n\r\nFor 12 symbols, the native selection occupies 9! = 362,880 cyclic classes on ten symbols. Each active row has a visible grade v and contributes charge 10-v. Completing the selection produces closed trails through the required permutations. Writing F3 = 12! + 11! + 10! = 522,547,200, the literal length is F3 + Q + J, where Q is the native charge and J is the net cost of opening and joining the completed trails. A selection with lower Q need not yield a shorter word: many independent trails can impose incompatible overlaps.\r\n\r\nWe lift the fiber construction used at n=11 into 504-class packets at n=12. The small packets are screened using charge, closed-walk monodromy and a global Kraft-trie model of compatible boundary overlaps. The trie prices help reject false winners whose apparent charge advantage disappears during completion. This is a restricted screening model, not a proof of the unrestricted optimum. Candidate selections are completed and assessed using literal overlaps.\r\n\r\nE contains 48 independently closed residual fibers and an interconnected core spanning 672 fibers. The independent fibers admit occupation-preserving alphabet relabelings, but the core cannot be changed one fiber at a time without breaking closure. We therefore treat complete closed-walk footprints and groups of interacting walks as compound fibers. Balanced successor exchanges preserve the occupied cyclic classes while changing how the row walks close and how their ports compose under completion.\r\n\r\nThe first successful core selection has charge 182,632 and 2,904 completed trails. We then examine 1,306 balanced exchange alternatives. Two compound replacements, each involving five original closed walks, change 28 row assignments in total. They add 80 units of charge but remove 72 completed trails. When evaluated against the actual arrangement, their joint placement and opening phases reduce the length from 522,736,550 to 522,736,530. The final selection has Q = 182,712 and 2,832 trails, of which 2,352 are rowless and 480 are active.\r\n\r\n## Arranging the completed trails\r\n\r\nFor each trail we retain a library of legal opening phases, including cuts at steps of weights 3, 2 and 1. A state s determines the opened word W(s), its extra cyclic overhang, and its incoming and outgoing literal keys. For a fixed order, a min-plus dynamic program computes the exact optimum over the enumerated states:\r\n\r\nD_i(s) = |W_i(s)| + min_t [D_(i-1)(t) - overlap(W_(i-1)(t), W_i(s))].\r\n\r\nPrefix/suffix indexes replace the quadratic comparison of every pair of cut states. The indexes support overlaps through 15 symbols, although the useful matches depend on the actual word. The outer search changes the order; each move is evaluated with phase choices reopened around its affected boundaries. Several separated cuts divide the path into segments. We construct a phase-aware connection-cost matrix, solve an assignment on these segments and patch subtours to obtain one connected path. Directed three-edge moves, four-edge exchanges and bounded searches over longer alternating successor cycles improve the patched assignment. Forced kicks disrupt existing connections, and temporary increases in length permit escape from local minima. We also test multiple-path intermediates and alternate path endpoints before rejoining.\r\n\r\nSPRA provides a compact representation of the word and accelerates repeated construction and inspection. A repeat audit identifies redundant permutation windows inside trails and enables additional legal opening states. The final arrangement passes 522,736,495, 479, 472, 467, 443 and 423, then ties 409 before a last reconnection reaches 406.\r\n\r\n## Where the three letters come from\r\n\r\nRelative to E (Q = 182,112, J = 7,097, 3,648 completed trails), the modified selection spends 600 extra letters in native charge but saves 603 letters in cuts and joins. It eliminates 816 completed trails. Thus the final literal length is\r\n\r\n522,547,200 + 182,712 + 6,494 = 522,736,406.\r\n\r\nAn independent literal scan finds all 479,001,600 distinct permutations in 479,179,123 clean windows, with zero missing and 177,523 repeated occurrences. The SPRA archive decodes to the identical literal word.\r\n\r\nThis is a computational improvement within Pantone's construction, building on Halfar's E selection, generalized row grades and trail arrangement techniques. The result is an upper bound, not a claim of optimality. AI-assisted exploration, implementation and search are used throughout.", "url": "https://superpermutations.com/w/W-0136", "permutation_windows": 479179123, "check_elapsed_seconds": 17.381807, "deletable_letters": null, "begins": "0123456789AB0123456789A0B123456789A01B23456789A012B3456789A0123B456789A01234B56789A012345B6789A0123456B789A01234567B89A0", "checkers": {"classcheck": {"source_sha256": "fe9c2f7fd612f3311543038c96bfda84d9d81d84229417d35bb44102da78848f", "seconds": 2.9907243605703115}, "bitmapcheck": {"source_sha256": "98e62368f912a3a0735910b924314104681dc2ea55f283c32eb66d52748bf1f0", "seconds": 1.9498230163007975}, "wordhash": {"source_sha256": "cb47f567daa6634a3ebeb81f2d9eb7fb5c19659441fbb973bf29a36a784a1c95", "seconds": 2.688875279389322}, "compiler": "rustc 1.89.0 (29483883e 2025-08-04)"}, "file": {"name": "W-0136.detour", "compression": "detour", "size": 42000, "encoded_sha256": "297d0c3dfda45a8ccecda32b576e5191a72c9d08ce65a5831ebb4a3b373bd944", "metadata": {"schema_version": 1, "format": "detour", "encoded_sha256": "297d0c3dfda45a8ccecda32b576e5191a72c9d08ce65a5831ebb4a3b373bd944", "encoded_size": 42000, "word_length": 522736406, "word_sha256": "6bf1ef85a2cc52add9238329a7c3129e06ef9c0fd76a8dc9d3215a33441a1558", "detour": {"version": 1, "n": 12, "alphabet": "0123456789AB", "length": 522736406, "sha256": "6bf1ef85a2cc52add9238329a7c3129e06ef9c0fd76a8dc9d3215a33441a1558", "tokens": 1067102, "starts": 1, "literal_bytes": 0, "steps_by_weight": [439262290, 36282785, 3631221, 1214, 277, 1091, 64, 41, 97, 29, 11, 2], "detours_by_weight": [1, 33, 1065148, 304, 274, 1095, 66, 41, 96, 30, 11, 2]}}, "text_download": null, "download": "https://superpermutations.com/w/W-0136/download"}}}