TOPICS
Search

In-Shuffle


An in-shuffle is a riffle shuffle in which a deck is divided into two equal halves whose cards are interleaved in their original order. Reading the shuffled deck from top to bottom, the first card comes from the bottom half. Using an in-shuffle, a deck originally arranged from top to bottom as 1 2 3 4 5 6 7 8 would become 5 1 6 2 7 3 8 4. The ordering of a deck of 52 cards after an in-shuffle is given by 27, 1, 28, 2, 29, 3, ... (OEIS A059952).

In general, in-shuffling a deck of 2n cards once moves card k to the position originally occupied by the (2k)th card (mod 2n+1) (Conway and Guy 1996). Therefore, in-shuffling a deck of 2n cards 2n times when 2n+1 is prime results in the original card order. This means that an ordinary deck of 52 cards is returned to its original order after 52 in-shuffles. The numbers of in-shuffles needed to return a deck of 2n=2, 4, ... cards to its original order are 2, 4, 3, 6, 10, 12, 4, 8, 18, 6, 11, ... (OEIS A002326), which is simply the multiplicative order of 2 (mod 2n+1).


See also

Out-Shuffle, Riffle Shuffle

Explore with Wolfram|Alpha

References

Conway, J. H. and Guy, R. K. "Fractions Cycle into Decimals." In The Book of Numbers. New York: Springer-Verlag, pp. 163-165, 1996.Sloane, N. J. A. Sequences A002326/M0936 and A059952 in "The On-Line Encyclopedia of Integer Sequences."

Referenced on Wolfram|Alpha

In-Shuffle

Cite this as:

Weisstein, Eric W. "In-Shuffle." From MathWorld--A Wolfram Resource. https://mathworld.wolfram.com/In-Shuffle.html

Subject classifications