Skip to content
BetSim

The method

Betting Optimization Simulator does not simulate football matches. It simulates you: the decisions you make about which bets to take and how much to stake. Here is what happens under the hood.

1. Micro-agents in parallel worlds

Each simulation creates thousands of virtual bettors. For every bet opportunity we draw a true probability, an imperfect estimate of it (your noise) and the bookmaker price with margin. Every agent sees its own random results, but all strategies are run on the same random numbers (common random numbers), so differences between strategies come from the strategy, not from luck.

2. Value and expected value

A bet at decimal odds oo with true win probability pp has expected value per unit staked:

EV=p⋅o−1\mathrm{EV} = p \cdot o - 1

You only have value when p⋅o>1p \cdot o > 1. Because you never know pp exactly, the value filter works on your estimate p^\hat p and the simulation measures how often the filter is right (its precision).

3. Removing the margin (Shin model)

Bookmaker odds imply probabilities that sum to more than 100% — the overround. The naive method divides each implied probability by the total; the Shin model assumes part of the market consists of insiders and corrects the favourite–longshot bias:

pi=z2+4(1−z) πi2/Π  −  z2(1−z),πi=1oi,Π=∑jπjp_i = \frac{\sqrt{z^2 + 4(1-z)\,\pi_i^2/\Pi} \;-\; z}{2(1-z)}, \qquad \pi_i = \frac{1}{o_i},\quad \Pi = \sum_j \pi_j

4. Kelly, fractional Kelly and robust Kelly

The Kelly criterion maximises the long-run growth of the bankroll. For a single bet with net odds b=o−1b = o - 1:

f∗=b p−(1−p)b=p o−1o−1,g(f)=plog⁡(1+fb)+(1−p)log⁡(1−f)f^{*} = \frac{b\,p - (1-p)}{b} = \frac{p\,o - 1}{o - 1}, \qquad g(f) = p\log(1+fb) + (1-p)\log(1-f)

Full Kelly is extremely sensitive to errors in pp. Fractional Kelly (½, ¼) gives up a little growth for much lower volatility. Robust Kelly maximises growth under the worst plausible probabilities (a CVaR constraint), which is the game-theoretic answer to "what if I'm wrong?".

5. The bettor-versus-nature game

For a bet slip we treat the uncertain probabilities as an opponent that picks the least favourable scenario. The maximin (Nash) mixed allocation spreads weight over bets — and over the option NO BET. When the worst-case value is not positive, the optimal weight on NO BET is 100%, and Betting Optimization Simulator says so.

max⁡w≥0,  w0+∑iwi=1 min⁡p∈U ∑iwi (pi oi−1)\max_{w \ge 0,\; w_0 + \sum_i w_i = 1}\ \min_{p \in \mathcal{U}}\ \sum_i w_i\,(p_i\,o_i - 1)

6. Dynamic programming (Bellman)

Instead of a fixed rule, dynamic programming computes the best stake for every bankroll level and number of remaining bets, by working backwards from the end:

Vt(w)=max⁡0≤f≤fmax⁡[ p Vt+1(w(1+fb))+(1−p) Vt+1(w(1−f))],VT(w)=U(w)V_t(w) = \max_{0 \le f \le f_{\max}} \Big[\, p\,V_{t+1}\big(w(1+fb)\big) + (1-p)\,V_{t+1}\big(w(1-f)\big) \Big], \qquad V_T(w) = U(w)

With U(w)=log⁡wU(w) = \log w this gives growth-optimal staking; with U(w)=1U(w) = 1 if w≥w \ge target (and 0 below the ruin line) it maximises the probability of reaching a target before ruin.

7. Markov chains: calm and tilt

After a loss, a bettor in the calm state moves to tilt with probability α\alpha; from tilt they recover with probability β\beta. In tilt, stakes are multiplied. The long-run share of time spent in tilt is:

P=(1−qαqαβ1−β),πtilt=q αq α+βP = \begin{pmatrix} 1 - q\alpha & q\alpha \\ \beta & 1-\beta \end{pmatrix}, \qquad \pi_{\text{tilt}} = \frac{q\,\alpha}{q\,\alpha + \beta}

where qq is the probability of losing a bet.

So even modest tilt probabilities can inflate average stakes — and the risk of ruin — substantially.

8. Monte Carlo and confidence intervals

Each probability we report (profit, ruin) is a proportion over nn agents, so it carries sampling error. We report Wilson score intervals; with 1,000 agents a probability around 50% is known to within roughly ±3 percentage points.

p^+z22n±zp^(1−p^)n+z24n21+z2n\frac{\hat p + \frac{z^2}{2n} \pm z\sqrt{\frac{\hat p(1-\hat p)}{n} + \frac{z^2}{4n^2}}}{1 + \frac{z^2}{n}}

Limits of the model

Results are only as good as the assumptions you enter. Real markets move, limits get cut, and your estimates may be worse than you think. Treat every output as a stress test of your decisions, not as a forecast.

The method · Betting Optimization Simulator