Against all odds.
-by Nathan “Kasuras� Meijer
But suppose you throw a coin enough times... Suppose one day, it lands on its edge.
-Kain to Raziel, Soul Reaver IIIn the world of maths, there are a few distributions to calculate chances: normal distribution and Poisson distribution to name a few. But basically, there are 2 types of distribution: discrete and continuous. Discrete is when there is a set amount of probabilities, and continuous is when every number is possible. For example: flipping a coin is of a discrete type, because you either flip heads or tails. And filling a bottle would be a continuous distribution because the average is 33 centiliters, but it is also possible that the bottle gets filled with 33.01, 32.69 or perhaps 34 centiliters.
Because you cannot play with half a card, Magic’s odds are calculated by a discrete distribution. And because you draw cards, and do not put them back: the hypergeometric distribution is used. This is how that distribution works, according to Wikipedia:
A typical example is the following: There is a shipment of N objects in which D are defective. The hypergeometric distribution describes the probability that in a sample of n distinctive objects drawn from the shipment exactly k objects are defective.
In general, if a random variable X follows the hypergeometric distribution with parameters N, D and n, then the probability of getting exactly k successes is given by

The probability is positive when k is between max{ 0, D + n − N } and min{ n, D }.
A practical example would be the chance of drawing 1 Force of Will in your opening hand:
N = 60 (assuming you are playing 60 cards)
D = 4 (there are 4 FoWs in your deck)
k = 1 (you want to calculate the chance of drawing 1 FoW)
n = 7 (you draw 7 cards in your opening hand)

And that chance is 0.33628. Another example: the chance of drawing at least 1 FoW would be f(1;60,4,7) + f(2;60,4,7) + f(3;60,4,7) + f(4;60,4,7) = 0,3995. Note that this can also be calculated by 1 – the chance of drawing no FoW at all, which is 1-f(7;60,56,7).
But how this all work in the midst of a match? I think it is easily illustrated by an example of a critical decision in the Meandeck Tendrils deck: (This example is assuming the other player does nothing)
Board situation: Mox Sapphire tapped for Ancestral Recall.
In your hand: Brainstorm, Mox Jet, Dark Ritual, Tendrils of Agony, Sol Ring, Cabal Ritual, 2 Spoils of the Vault.
Turn: 1.
What would be the perfect play now? Passing the turn or try to go off this turn? And what would you Spoils for if you would try to go off this turn? And what would you discard if you were to pass the turn? Take a look whether you can go off this turn:
The current storm count is 2, and you have 8 cards in hands of which 1 is Tendrils of Agony; so you can theoretically kill the opponent with that. The problem however is that you cannot cast that Brainstorm with your current situation. So your only option is Spoils: naming a draw spell, hoping you draw into a mana source or naming a mana source itself. The problem is that your choices are quite limited, unless you are the suicidal type, by the nature of most of your mana sources: they are restricted! I will be eliminating all the possibilities one by one to make this clear.
Basically, you have 5 options: Land Grant, Darkwater Egg, Chromatic Sphere, Dark Ritual or Cabal Ritual. Note that your storm count after playing the Spoils and the card you found is 8 and that you have 1BBB in your manapool after playing Spoils and the rest that was in your hand except for the second Spoils, Brainstorm and Tendrils. Let’s start with the chance of finding the cards without losing your 20 life, which is of course equal to 1-the chance of not finding it:
-Land Grant = 1-f(20; 50, 46, 20) = 0,881003.
-Darkwater Egg = 1-f(20; 50, 46, 20) = 0,881003.
-Chromatic Sphere = 1-f(20; 50, 46, 20) = 0,881003.
-Dark Ritual = 1-f(20; 50, 47, 20) = 0,792857.
-Cabal Ritual = 1-f(20; 50, 47, 20) = 0,792857.
And what role do these statistics play when building a deck? One example has already been given earlier in the chance of drawing Force of Will in your opening grip. Let’s take a look at what the chance of drawing at least 1 land in that opening grip is if you were running 21 mana sources in your deck:
1-f(0;60,21,7) = 0,960174.
The problem is that you cannot really do that much with that knowledge; you need something to compare it with. So let’s say you are playing a deck where the optimal number of mana sources in your opening grip is 2. What would then be the optimal number of mana sources to play?
-16 Lands = f(2;60,16,7) = 0,337438
-17 Lands = f(2;60,17,7) = 0,338972
-18 Lands = f(2;60,18,7) = 0,337001
-19 Lands = f(2;60,19,7) = 0,331809
So it is clear that running 17 mana sources in your deck will give you the most chance of getting exactly 2 them in your first 7. Now a more advanced example: the optimal hand in a control deck would exist of a land and a Brainstorm or Ancestral Recall, 2 mana sources or 2 mana sources and Brainstorm or Recall. Let’s say you run 23 mana sources.
-Chance of 2 mana sources in opening grip = f(2;60,23,7) = 0,285551.
-Chance of 1 mana source and Brainstorm or Ancestral Recall = f(1;60,5,7)* f(1;60,23,7) = 0,051962.
-Chance of 2 mana sources and a Brainstorm or Ancestral Recall = f(1;60,5,7)* f(2;60,23,7) = 0,107171.
Total = 0,444684.
Yet again, those chances are not worth that much if you cannot compare them to anything else. So what if you are playing 24 mana sources?
-Chance of 2 mana sources in opening grip = f(2;60,24,7) = 0,269415.
-Chance of 1 mana source and Brainstorm or Ancestral Recall = 0,496354.
-Chance of 2 mana sources and a Brainstorm or Ancestral Recall = 0,644727.
Total = 1,410496
Another example: the chance of drawing 7 mana sources compared to the perfect hand in Gifts. I will be using the list as played by Carl Winter in the 4-30-05 Waterbury Tournament. A hand that would win the game the first turn would look something like this:
-Yawgmoth’s Will
-Time Walk
-Tinker
-Blue mana source
-Black Lotus
-Mana Crypt
-Ancestral Recall
And the chance of that happening is (f(1;60,1,7))^6*f(1;60,16,7) = 3,05221E-07. Compare this to the chance of drawing 7 mana sources in your first 7: f(7;60,25,7) = 0,000896. Indeed, quite a difference.
Oh, remember the example of Meandeck Tendrils where you had to make a decision which card to name? The named card turned out to be 34th in line.