In the mathematics of shuffling playing cards, the Gilbert–Shannon–Reeds model is a probability distribution on riffle shuffle permutations that has been reported to be a good match for experimentally observed outcomes of human shuffling, and that forms the basis for a recommendation that a deck of cards should be riffled seven times in order to thoroughly randomize it. It is named after the work of Edgar Gilbert, Claude Shannon, and J. Reeds, reported in a 1955 technical report by Gilbert and in a 1981 unpublished manuscript of Reeds. A riffle shuffle permutation of a sequence of elements is obtained by partitioning the elements into two contiguous subsequences, and then arbitrarily interleaving the two subsequences. For instance, this describes many common ways of shuffling a deck of playing cards, by cutting the deck into two piles of cards that are then riffled together. The Gilbert–Shannon–Reeds model assigns a probability to each of these permutations. In this way, it describes the probability of obtaining each permutation, when a shuffle is performed at random. The model may be defined in several equivalent ways, describing alternative ways of performing this random shuffle: Most similarly to the way humans shuffle cards, the Gilbert–Shannon–Reeds model describes the probabilities obtained from a certain mathematical model of randomly cutting and then riffling a deck of cards. First, the deck is cut into two packets. If there are a total of cards, then the probability of selecting cards in the first deck and in the second deck is defined as . Then, one card at a time is repeatedly moved from the bottom of one of the packets to the top of the shuffled deck, such that if cards remain in one packet and cards remain in the other packet, then the probability of choosing a card from the first packet is and the probability of choosing a card from the second packet is . A second, alternative description can be based on a property of the model, that it generates a permutation of the initial deck in which each card is equally likely to have come from the first or the second packet.