Nim #
In the game of nim o
, for o
an ordinal number, both players may move to nim a
for any a < o
.
This is an impartial game; in fact, in a strong sense, it's the simplest impartial game, as by the
Sprague-Grundy theorem, any other impartial game is equivalent to some game of nim. As such, many
results on Nim are proven in Game.Impartial.Grundy
.
We define nim
in terms of a Nimber
rather than an Ordinal
, as this makes the results
nim (a + b) ≈ nim a + nim b
and nim (a * b) ≈ nim a * nim b
much easier to state.
Nim game #
@[irreducible]
The definition of single-heap nim, which can be viewed as a pile of stones where each player can take a positive number of stones from it on their turn.
Equations
- One or more equations did not get rendered due to their size.