🎲

Board Games & Game Mathematics

Poker odds, blackjack strategy, the Monty Hall paradox, Elo ratings and Nash equilibria — explore the surprising mathematics hidden in every game.

6 simulations Probability · Game Theory Monte Carlo · Combinatorics

Simulations

Open any simulation — runs instantly in your browser

🤝
Popular★★☆ Moderate
Game Theory — Nash Equilibria
Prisoner's Dilemma, Battle of the Sexes, Matching Pennies. Visualise Nash equilibria, Pareto efficiency and mixed strategies of competing agents.
NashStrategyCanvas
🏆
★★☆ Moderate
Travelling Salesman (TSP)
Greedy nearest-neighbour, 2-opt local search and simulated annealing race to solve the NP-hard TSP. See tour length decrease over 1 000 generations.
CombinatoricsSAOptimisation
🧬
★★☆ ModerateNew
Genetic Algorithm
Evolution of strings, shapes and paths via crossover and mutation. Watch fitness increase generation by generation with live population histogram.
GAEvolutionCanvas
📊
★☆☆ Beginner
Sorting Algorithm Race
12 algorithms compete — bubble, merge, quick, heap, radix and more. Audio tones mark each comparison. Compare time complexity in practice.
AlgorithmsBig-OWeb Audio
🗺️
★☆☆ Beginner
Maze Pathfinding
A*, Dijkstra and BFS solve procedurally generated mazes. Paint walls and watch the algorithms explore — see why heuristics matter for speed.
A*DijkstraGraph
🏗️
★☆☆ BeginnerNew
Maze Generation
DFS backtracker, Prim's, Kruskal's and Wilson's algorithm grow mazes live. Watch the spanning tree expand and compare the resulting maze textures.
GraphMSTCanvas
🃏
★★☆ Moderate
Blackjack Strategy Simulator
Run 1 000 000 hands with basic strategy vs card counting. Expected value per hand, house edge, deck penetration and risk-of-ruin curves.
EVMonte CarloProbability
🎰
★★☆ Moderate
Monty Hall Paradox
Play millions of rounds with always-switch vs always-stay strategies. Watch the 66.7% vs 33.3% win rate converge before your eyes.
ProbabilityBayesParadox
🎂
★☆☆ Easy
Birthday Paradox
With just 23 people there is a 50% chance of a shared birthday. Run Monte Carlo simulations and watch the probability curve build live on a 365-day year ring.
ProbabilityMonte Carlo

Related Articles

Related Categories

About Game Mathematics Simulations

Vectors, collisions, physics engines, and geometry for game developers

Game mathematics simulations cover the core computational geometry and physics algorithms that power interactive video games. Bounding-volume collision-detection simulations compare AABB–AABB, sphere–sphere, and GJK algorithms, showing the contact manifold and response impulse for each approach. Raycasting simulations build a pseudo-3D corridor from a 2D map using the same ray-DDA technique used in Wolfenstein 3D and early Doom.

Quaternion rotation visualisers demonstrate the spherical-linear interpolation (SLERP) that produces smooth camera and character animation without gimbal lock. Spatial-hashing and quad-tree demos show how broad-phase collision detection scales from O(n²) to O(n) as object count increases. These are the mathematical foundations every game programmer must master, and seeing them animated makes the algebra of cross products, dot products, and determinants immediately geometric.

Each simulation in this category is built with accuracy and interactivity in mind. The underlying mathematical models are the same ones used in academic research and professional engineering — just made accessible through a web browser. Changing parameters in real time and observing the results is one of the most effective ways to build intuition for complex scientific and engineering concepts.

Key Concepts

Topics and algorithms you'll explore in this category

Nash EquilibriumDominant strategies and mixed-strategy equilibria
Monte Carlo MethodsProbability estimation through random sampling
Expected ValueEV calculations underlying beating-the-house strategies
Combinatorial Game TheorySprague-Grundy theorem and Nim-values
Markov ChainsProbability transitions in board and card games
Optimal StoppingSecretary problem and best-of-N betting strategies

Frequently Asked Questions

Common questions about this simulation category

What games and math topics are simulated?
Blackjack (basic strategy, card counting), poker hand equity, roulette statistics and gambler's ruin, Monopoly Markov chain, and combinatorial game theory including the secretary problem.
Does the blackjack simulation account for card counting?
Yes — you can enable Hi-Lo card counting to watch the true count change with each card dealt and see how betting strategy shifts when the deck is player-favorable.
What is the 'gambler's ruin' simulation?
It models successive bets where the player wins or loses a unit each round with fixed probability. The simulation shows that even with a nearly 50-50 game, a house edge guarantees eventual ruin over large numbers of trials.