Game Simulator

GameSim is a tool/framework for simulating gambling sessions.

JAR gamesim.jar
Java Web Start gamesim.jnlp
Linux/UNIX gamesim.tar.gz
Mac OS X gamesim.dmg
Windows gamesim.zip

Applet cannot be run. Install JRE 6.0+ or try another browser.

Roulette Wheel

We created a simple applet to chart the success of a theoretical Martingale bettor. The casual observer will note that the strategy is usually successful for a small number of 'spins' coupled with a high 'max' bet. As the ratio between these two numbers shrinks, the house always wins. The applet and web start versions of the tool are memory constrained; download the client and run with VM passthrough parameters (e.g. -J-Xmx256m) to support longer simulations.

Everything progresses according to plan...
Off to a good start
Lookin' good
Can't lose

...until it doesn't.
Oops

The following graph makes it clear that lower maximum bets actually favor the gambler. Seemed like a good idea at the time
Note that the rate at which money is lost is reduced by smaller bets.

In retrospect, all of this should be obvious. For any given point in an infinite series, a string of losses of length 'n' is a bit more than half as likely as a run of length 'n - 1'. Consequently, doubling both the sample size and the max bet keeps the odds of reaching a debt limit relatively similar. Since the odds favor the house for any single spin, an unbounded number of turns spells certain disaster.