Skip

Probability and statistical mechanics · 12 manuscript(s)

Optimal logarithmic mixing of the Thorp shuffle

Verified by Lean
Open on GitHub

1 · The essentials

How many times must the Thorp shuffle be repeated before a deck is nearly random? For decks whose size is a power of two, this family of manuscripts gives matching answers for how that number grows. The required number of shuffles grows in proportion to the logarithm of the number of cards, rather than to the number of cards itself. The result concerns the order of the entire deck, not merely where each card might end up. It also holds regardless of the starting order. The main manuscript shows that, for a deck of cards, shuffles make the difference from a perfectly random ordering tend to zero as grows. A complementary lower bound establishes that the logarithmic growth rate cannot be improved, and the main optimal-order result has a Lean formalization.

A picture to help (an imperfect image, not to be taken literally)

As an imperfect image, imagine checking a seating lottery: each guest having a plausible seat does not by itself guarantee that the whole seating plan is random. These results assess the whole plan at once, rather than checking guests one by one.

Why it matters

The family establishes the optimal growth order of the Thorp shuffle’s mixing time for power-of-two deck sizes. Its guarantee is strong in two respects: it covers the complete ordering and the worst starting deck. The companion manuscripts also describe ways to turn information about only part of a permutation into control of the whole permutation.

2 · Going further

Write the deck size as . The problem is to determine how many physical Thorp shuffles are needed for the full permutation law to approach the uniform law in total variation, uniformly over initial orderings. The main manuscript shows convergence after complete shuffles as , while a support count gives a lower bound of . Together these establish the optimal order ; they do not identify an exact leading constant.

A recurring route in the abstracts is to control partially observed permutations and then transfer that control to the full law. Manuscript 2 uses random coordinate frames and gives a bound, improved to when its fixed-list estimate is combined with the companion Fourier transfer. Manuscript 3 supplies a precise transfer statement: as tends to infinity through multiples of eight, if the images of a uniformly chosen labels approach the uniform injection law in average total variation, and the sign mean tends to zero, then the product of two independent permutations with that law approaches uniform on .

Other companions condition on revealed card paths. Manuscript 4 controls the endpoints of further cards, averaged over observed paths, provided a fixed positive fraction of labels lies outside both lists; with a Fourier transfer, it yields a bound. Manuscript 5 reveals the trajectories of half the labels and shows that the conditional permutation of the remaining labels approaches uniform after an absolute number of coordinate sweeps. Across the family, a fixed number of sweeps yields a constant multiple of physical shuffles.

The remaining companions develop contraction, moment, and density estimates for sweeps. Manuscript 8 shows a total-variation bound of after an absolute number of sweeps, while Manuscript 10 shows convergence in squared distance. Manuscript 12 uses a permanent inequality for laws on sufficiently close to uniform and with exactly uniform coordinate marginals. Manuscripts 6, 9, and 11 are marked Lean-formalized; the last passes from a conditional Schatten-moment bound for suitable coordinate sweeps to binary sweeps by analytic transfer.

Useful notions

  • Powers of two and logarithms
  • Permutations and uniform randomness
  • Probability distributions
  • Conditioning on observed information
  • Asymptotic upper and lower bounds

What was known before / what is new

Before

The supplied source does not give a historical sequence of earlier mixing bounds or identify a previously posed open problem. It does identify the support-count lower bound against which the upper bounds are compared. The partial-information transfer and conditional-sweep estimates are presented as results of companion manuscripts, not as an account of prior literature.

New

The central result is optimal-order full-permutation mixing in physical shuffles for , from the worst initial ordering. The family provides several routes to that conclusion, including partial-permutation transfer, conditioning on trajectories, and sweep contraction estimates. It also includes explicit upper bounds and, in Manuscript 8, a quantitative error bound tending to zero.

Limits and assumptions

The Thorp results stated here concern power-of-two deck sizes; the source supplies no extension to arbitrary sizes. Optimal order does not mean an exact optimal constant, and the stated convergence guarantees are asymptotic as the deck size grows. The transfer in Manuscript 3 requires both its partial-image hypothesis and vanishing sign mean, and applies to a product of two independent permutations. Other intermediate results have their own restrictions, including unobserved-label fractions, near-uniform line laws, or exactly uniform coordinate marginals. The main optimal-order result has a Lean formalization, and Manuscripts 6, 9, and 11 are explicitly marked Lean-formalized; this does not establish formal verification of every companion claim or numerical constant. The source does not specify further open problems.

Mini glossary

Full permutation law
—
The probability distribution of the entire ordering of the labeled deck.
Total-variation distance
—
A measure of the difference between two probability laws, with distance tending to zero expressing convergence here.
Mixing time
—
The number of shuffle steps needed for the deck’s ordering law to become close to uniform.
Optimal order
—
A growth rate supported by matching upper and lower bounds up to constant factors.
Uniform injection law
—
The law that assigns equal probability to each placement of the selected labels into distinct positions.
Conditional permutation law
—
The distribution of a permutation after specified information, such as some card trajectories, has been revealed.

Keywords : Thorp shuffle · Mixing time · Total variation

AI-generated explanation based on the manuscript. Unofficial. Refer to the manuscript for the authoritative version.

3 · Technical details and sources

Claim made in the manuscript (source text)

Proves that the Thorp shuffle randomizes labeled cards in physical shuffles, settling its optimal mixing order for power-of-two deck sizes. Convergence is in total variation from the worst initial ordering and concerns the entire permutation, not just individual card positions.

Verified by Lean: the Lean software checked the part of the reasoning described below, sometimes only part of the manuscript. This does not mean independent mathematicians have validated the result.

Scope of the Lean formalization (source text)

…

lean/docs/238.md

Manuscripts in this family

★

Optimal-order mixing of the Thorp shuffle

26/09/2026
To be verified

We prove that the Thorp shuffle on cards mixes in complete shuffles. The full permutation law after shuffles converges to uniform in total variation as , uniformly over the initial deck, while a support count gives a lower bound of .

2.

Random coordinate frames and partial permutation laws

26/09/2026
To be verified

For the Thorp shuffle on cards, we prove that the worst-start total-variation distance after physical shuffles tends to zero as . Combining our fixed-list estimate with the companion Fourier transfer improves this bound to shuffles. These results follow from bounds on partially observed permutation laws in random coordinate frames.

3.

From partial permutation information to Fourier bounds

26/09/2026
To be verified

We show how information about partial permutations controls full permutation laws. Let n tend to infinity through multiples of eight. If the images of a uniformly chosen labels approach the uniform injection law in average total variation, and the sign mean tends to zero, then the product of two independent permutations with the given law converges to uniform on Sn.

4.

Conditional information under deterministic coordinate sweeps

26/09/2026
To be verified

We bound the information remaining after paths of specified cards in the Thorp shuffle on cards have been observed. After a fixed number of deterministic coordinate sweeps, the joint endpoint law of further cards is close to uniform on the available positions, on average over the observed paths, provided a fixed positive fraction of labels lies outside both lists. Combined with a Fourier transfer, these bounds give full-deck mixing after physical shuffles.

5.

Conditional permutations in a revealed switching environment

26/09/2026
To be verified

Fix half the labels in a Thorp shuffle on positions and reveal their complete trajectories. We prove that, after an explicit absolute number of coordinate sweeps, the conditional permutation of the remaining labels approaches uniform in expected total variation as , uniformly in the initial layout. The resulting constructions give full-deck mixing in a constant multiple of d physical shuffles.

6.

Routing densities and representation contraction for Thorp sweeps

26/09/2026
Verified by Lean

For cards, we prove that an absolute number of coordinate sweeps of the Thorp shuffle brings the full permutation law to total-variation distance tending to zero from uniform. The mixing time therefore has optimal order in physical shuffles.

7.

Row–column symmetry and contraction of coordinate sweeps

26/09/2026
To be verified

We prove that the Thorp shuffle on labeled cards has full-permutation total-variation mixing time in physical shuffles. An absolute number of coordinate sweeps suffices for the upper bound.

8.

Random-subspace tests and trace smoothing for coordinate sweeps

26/09/2026
To be verified

We prove that an absolute number of coordinate sweeps of the Thorp shuffle on positions brings the full permutation to total-variation distance at most from uniform, uniformly over the initial deck. Thus physical shuffles suffice, which is optimal in order.

9.

Compatibility entropy and the spectrum of a Thorp sweep

26/09/2026
Verified by Lean

We prove that the Thorp shuffle on cards mixes in physical shuffles. After a sufficiently large fixed number of coordinate sweeps, the total-variation distance of the full permutation from uniform tends to zero as .

10.

Signed tensor densities and diagram budgets for the Thorp shuffle

26/09/2026
To be verified

We prove that a fixed number of coordinate sweeps of the Thorp shuffle on cards makes the squared L2 distance of the full permutation density from uniform tend to zero as . In particular, the total-variation mixing time is physical shuffles.

11.

Conditional coordinate sweeps and analytic transfer

26/09/2026
Verified by Lean

For coordinate sweeps with near-uniform line laws and line sizes among powers of two in a suitable fixed interval, we prove a Schatten-moment bound after conditioning on any feasible collection of prescribed card trajectories. An analytic transfer to binary sweeps then shows that a fixed number of sweeps mixes the Thorp shuffle on cards in physical steps, matching the order of the support lower bound.

12.

A strict four-row permanent inequality and permutation moments

26/09/2026
To be verified

We prove a permanent inequality with exponent strictly below two for laws on S4 sufficiently close to uniform and with exactly uniform coordinate marginals. Applied to a four-row recursion, it shows that an absolute number of coordinate sweeps brings the full permutation of the Thorp shuffle on cards to total-variation distance tending to zero from uniform as . Thus the mixing time has the optimal order in physical shuffles.