NimForge is a study hall for combinatorial game theory — the mathematics of two-player games with no chance and no hidden information, where perfect play is a theorem, not a guess. Play Nim against a bot that never errs, then turn the position over to the engine and ask the real question: who wins, and why?
For ages 15–18 (math-circle and competition-math flavour). Everything is computed on this device — the Nim-sum, Grundy values, and the exact win/loss of every small position — so nothing you type leaves your machine, and no AI is ever near the mathematics.
The one idea worth saying out loud
“Add the rows without carrying — leave your opponent a zero.”
That is the entire winning strategy for normal-play Nim: compute the Nim-sum (the bitwise XOR of the row sizes), and always move so that it becomes 0. If it is already 0 when it is your turn, the position is lost against perfect play — which is exactly why the classic (1, 2, 3) opening is a loss for whoever moves first.
What you can do here
Play — Nim or its misère twist, against a bot that always finds the winning move and explains the Nim-sum reasoning after each of its turns.
Solve — conjecture which positions win, then let the engine check every small position at once: the two-heap P/N map, Sprague–Grundy subtraction values, and Wythoff's golden-ratio cold squares.
Meet the cast
Each idea in NimForge is carried by a character whose one job IS that idea (the “cast is the curriculum”). No pictures here — at this age the mathematics is the star.
Nima — The Nim-sum — add the rows in binary with no carrying; the whole game lives in one number.
Bela — The balance (P-position) — you're safe exactly when the Nim-sum is zero, and every move breaks it.
Mirren — Symmetry — with two equal rows, copy the opponent and you cannot lose.
Gideon — The Sprague–Grundy value — every impartial game is secretly a single Nim heap.
Minu — The mex — a position’s value is the smallest number you cannot move to.
Sabra — Subtraction games — when you may only take from a fixed menu, the values fall into a period.
Iver — Misère — the twist where taking the last token loses; nearly the same rule, one careful exception.
Wyn — Wythoff's game — two heaps, a queen's move, and the golden ratio deciding who wins.
Hazel — Hackenbush — games that are worth fractions, where numbers themselves are born from play.
Professor Vera Kell — (Mentor) — sets the position and asks “who wins, and can you prove it?”
Honest note
NimForge builds intuition for winning positions and the beautiful bridge from a game to a number (mex, Grundy values, the golden ratio). It is a place to play and prove — not a test-prep guarantee, and not a claim about grades or IQ.
Reading Access
Make reading comfier. Saved on this device only — nothing leaves your device.