◀ THE FOLD0ROOT.AI // WORLD II · LOOT · THE-JACKPOT◆ .dlw.fold
THE FOLD / LOOT / THE-JACKPOT / THE MENAGE PROBLEM

THE MENAGE PROBLEM

couples seated so none sits by a partner
1 WHAT IT IS · WHAT IT DOES · FACT OR FICTION
The ménage problem asks: in how many ways can n couples be seated around a round table, men and women alternating, so that no one sits next to their own partner? Fix the men in alternate seats; the question becomes counting permutations σ of the women with σ(i) ≠ i and σ(i) ≠ i+1 (mod n) — each woman avoids the two men flanking her partner’s original spot. Touchard gave a closed form as an alternating sum of binomials, An = Σk (−1)k (2n/(2n−k)) C(2n−k, k) (n−k)!. The sequence 1, 0, 0, 1, 2, 13, 80, 579… is a classic of combinatorics.

LIT verified live: for n = 3 to 7, the Touchard closed-form ménage number equals a brute-force count of all valid seatings (window.__menage). FIG no framing; the closed-form formula and the exhaustive enumeration run in-browser.
2 HOW IT WAS WEAVED · AI + HUMAN
David (human) seated this at the-jackpot — the whole jackpot of valid seatings, counted at once by an alternating-sum formula. AVAN (AI) built the instrument: the Touchard closed form, the brute enumeration of forbidden-adjacency permutations, and their match.

Credit as content: Édouard Lucas (posed, 1891); Jacques Touchard (closed form, 1934). The weave: David names the jackpot; I confirm the closed form equals the exact count of alternating no-partner-adjacent seatings.
3 ONE DIMENSION
Men fixed in alternate seats; each woman must avoid the two men flanking her partner — the forbidden diagonals.
4 TWO DIMENSIONS · INTERACTIVE
Pick n; the closed-form ménage number equals a brute count of all valid alternating seatings.
5 THREE DIMENSIONS + AVAN’S INVERSE
The green forward object: the count of valid seatings.
AVAN’s addition (the inverse-companion): don’t list every seating — sum over the forbidden overlaps. The inverse of ‘enumerate valid arrangements’ is ‘an inclusion-exclusion over the two forbidden adjacencies per person — Touchard’s alternating binomial sum.’ Magenta is a forbidden seating; green is a valid one. Count by cancelling the forbidden.
LIT Genuine ménage problem (Édouard Lucas posed it, 1891; Jacques Touchard's closed form, 1934). Verified live: for n=3..7, the Touchard alternating-binomial formula A_n = Σ_k (−1)^k (2n/(2n−k)) C(2n−k,k) (n−k)! equals a brute-force count of permutations with σ(i)≠i and σ(i)≠(i+1) mod n (n=5 → 13) (window.__menage.matches).

FIG No framing: the closed-form formula and the exhaustive enumeration run in-browser. The AVAN inverse is honest — instead of listing every seating, one sums over the forbidden overlaps: an inclusion-exclusion over the two forbidden adjacencies per person, giving Touchard's alternating binomial sum. Magenta is a forbidden seating; green is a valid one. Count by cancelling the forbidden.
◆ sealed .dlw.fold → folded to ROOT_0 · a sphere of THE-JACKPOT · David Lee Wise (ROOT0), with AVAN