This set practises the counting behind the lecture’s hand table, the derivation and use of the Kelly criterion, and the risk-of-ruin formula for a poker bankroll.
Problem 1
Problem 6.1 (Counting the high-card table).Use the definition of a high-card hand from the module (five different ranks, no straight, not a flush).
- Show that every set of five different ranks has exactly 1020 non-flush suit patterns, and that there are 1277 non-straight rank sets. Conclude that there are 1,302,540 high-card hands.
- Compute the table entries for top card K and top card 7 from first principles.
- Explain why the ace row subtracts two rank sets from
while the king row subtracts only one. - Explain why the bottom-card column is the top-card column read upside down.
- In early poker there were no straights or flushes, so every hand with five different ranks counted as a no-pair hand. Recount the ace-high row and the total under those rules. Does the share of ace-high hands change much?
- What fraction of all 2,598,960 five-card hands are high-card hands?
Solution
- Each of the 5 cards can take any of 4 suits independently, giving
patterns; exactly 4 of them put all five cards in one suit. That leaves . There are sets of five different ranks, of which 10 are straights (the nine runs from 2-3-4-5-6 up to 10-J-Q-K-A, plus the wheel A-2-3-4-5). So there are non-straight rank sets and high-card hands. - Top card K: the other four ranks come from the 11 ranks 2 through Q, giving
sets; one of them, K-Q-J-10-9, is a straight. So . Top card 7: the other four come from 2 through 6, giving sets; one, 7-6-5-4-3, is a straight. So . Both match the table. - As a set of ranks, a hand is assigned to the row of its highest rank, with the ace counted high. Two straights contain an ace: A-K-Q-J-10 and the wheel A-2-3-4-5. Both have the ace as their highest rank, so both fall in the ace row. Every other row contains exactly one straight, the run of five ending at that rank (and the rows 2 through 5 contain none at all, because there are too few ranks below them).
- Relabel ranks by
(A to 2, K to 3, and so on). This reverses the order, so the top card of a set becomes the bottom card of its image, and it maps choices “below the top card” to choices “above the bottom card”. The nine ordinary straights map to ordinary straights. The wheel maps to {2, J, Q, K, A}, which is not a straight, while {2, J, Q, K, A} maps to the wheel. Both of these sets have top card A and bottom card 2, so counting rows by top card in one picture and by bottom card in the other loses one set from the A row and one from the 2 row in both pictures. The counts therefore agree row by row. - Without straights and flushes, all
suit patterns and all rank sets count. The ace row has hands and the total is . The ace-high share is , compared with under modern rules: almost no change. The inversion of the rarity principle is a property of ranking by the top card, not of straights or flushes. . Just over half of all five-card poker hands contain nothing.
Problem 2
The equities for part 3 come from the course tool:
$ rust/target/release/poker equity AA KK --exhaustive
hand/range equity % win % tie %
---------- -------- ------- ------
AA 81.9461 81.7147 0.2314
KK 18.0539 17.8226 0.2314
mode: exhaustive samples: 61642944Problem 6.2 (Kelly with ties, and a large edge).A bet pays even money. It wins with probability
, loses with probability and ties (stake returned) with probability .
- Write down the long-run growth rate
when a fraction of wealth is staked each time, and show that it is maximised at . - Show that the quadratic approximation
, with and the mean and second moment of the per-unit return, gives exactly the same for this bet, but not the same maximal growth. - You may bet repeatedly at even money that
AAbeatsKKall-in preflop. Using the tool output above, compute, the growth rate at , and the growth rate at half Kelly. What share of the maximal growth does half Kelly keep, and why is it not the 75% predicted in the module? - A friend says: “AA wins 82% of the time, so I should bet 90% of my wealth.” Compute his growth rate.
Solution
- Each bet multiplies wealth by
(win), (loss) or (tie). By the law of large numbers the average log return per bet tends to Then
and , so is concave. Setting gives , that is .
The per-unit return
is , or with probabilities , , , so and . The parabola peaks at , the exact . Its peak value is , which differs from because the higher-order terms of are not small when is large. With
and : . Stake 64% of wealth per bet. The growth rate is per bet, so wealth multiplies by about per bet in the long run. At half Kelly ( ) the growth is , which is of the maximum. The 75% rule comes from the quadratic approximation, whose peak value here is instead of ; with an edge this large the approximation is visibly off. The qualitative message is unchanged: half Kelly keeps most of the growth.
per bet, about half of the Kelly growth, with far larger swings: every loss wipes out 90% of his wealth. At the growth is negative ( ) despite the 82% win rate, and he goes broke in the long run.
Problem 3
Problem 6.3 (Risk of ruin: exact and approximate).
- A bettor wins one unit with probability
and loses one unit with probability , starting with units and never stopping. Find with for one step , and use the martingale argument of the module to show that the probability of ever going broke is exactly . Why is there no overshoot correction here? - Take
and . Compare the exact risk with and with the second-order version . Explain the ordering. - A poker player has
bb/100 and bb/100. What bankroll gives a 1% risk of ruin at fixed stakes? - The same player moves to a game with the same win rate but
bb/100. What bankroll is now needed for 1%?
Solution
- For one step,
. Setting this to and writing gives , with roots and . The positive is . Then is a martingale. Stopping at or at a target , , and letting (with ) gives . Because every step is exactly one unit, the walk hits exactly; it cannot jump past it, so at ruin is exactly and the argument has no error. - Exact:
. Here and . The first approximation gives ; the second gives . The exact exponent is , between and . With a 20% edge the second-order expansion of is no longer accurate, and the simple formula, which drops even the term, understates the risk. For poker, where is around , the three numbers agree closely. - From
: bb, about 62 buy-ins of 100 bb. - The required bankroll is proportional to
, so it grows by : bb. A third more volatility needs 78% more bankroll for the same safety.
Problem 4
Problem 6.4 (Fractional Kelly for a poker bankroll).A player estimates
bb/100 and bb/100 and has a bankroll of $8,000.
- Find the Kelly bankroll in big blinds and the big blind at which the player’s $8,000 is exactly a full-Kelly and a half-Kelly bankroll.
- Using the fractional-Kelly proposition of the module, find the probability that wealth ever falls to half, and to a quarter, of its current value under full Kelly, half Kelly and one-third Kelly. What share of the maximal growth does each keep?
- The estimate
came from 40,000 hands. Compute its standard error and the relative error . What is the best fraction of the estimated Kelly stake, and what share of the attainable growth does full Kelly on the estimate keep on average?
Solution
bb. Full Kelly: , a $5 big blind. Half Kelly: the bankroll should be bb, so the big blind is , that is $2.50. - The probability of ever falling to a fraction
is and the growth share is .
Fraction Ever lose half Ever lose three quarters Growth share 1 1/2 1/4 100% 1/2 1/8 1/64 75% 1/3 1/32 1/1024 56% Halving the stakes from full Kelly gives up a quarter of the growth and cuts the chance of ever halving the bankroll from one in two to one in eight.
- With
blocks, bb/100, so : the estimate is as uncertain as it is large. The expected growth share for a multiple of the estimated Kelly stake is , which is largest at , where it equals . Full Kelly on the estimate gives : on average, no growth at all. Half Kelly is not timidity here; it is the optimum given what the player knows.
Problem 5
Problem 6.5 (Who pays the winners).A six-handed online table collects 6 bb of rake per 100 hands in total. All six players play every hand.
- What is the sum of the six players’ win rates? What is the average win rate?
- Alice wins 5 bb/100 and Bob 2 bb/100. What is the average win rate of the other four players?
- Six players of exactly equal skill sit down. Explain why all of them are losing players, and use the lecture’s account of poker networks to explain why games like this nevertheless kept running.
Solution
- Chips only move between players or to the house, so the win rates sum to
bb/100. The average is bb/100. - The other four must sum to
bb/100, an average of bb/100 each. Two winners need four players to lose more than three times the average loss. - With equal skill, symmetry gives every player the same expected win rate, and the six rates sum to
, so each is bb/100. Money alone cannot explain why anyone plays. Brown’s account is that players got other things from the game: entertainment, company, and in the networks he described, credit, contacts and access to services traded among the players. The players’ losses are then a price paid for those goods, as an insurance premium is the price of risk transfer in a market.