Skip to main content

Section 3.4 Who Wins?

In this section, we prove that the Sprague-Grundy value of a position tells us whether it is an \(\cN\)-position or a \(\cP\)-position. We have seen some nice evidence that the Sprague-Grundy value is actually a generalization of the nim value. Indeed, our main result is analogous to TheoremĀ 2.3.2: we are in an \(\cN\)-position if and only if the Sprague-Grundy value is nonzero.

Our proof is a streamlined form of the proof of TheoremĀ 2.3.2. In that proof, we had an explicit formula for the nim sum, rather than a recursive definition that uses the values of the followers. Starting with that formula, we had to understand the behavior of the nim value, compared to the nim value of the followers. The recursive definition for the Sprague-Grundy value makes our general argument a breeze.

Let \(\cA = \{ X \in \cG \mid g(X)=0 \}\) and \(\cB = \{ Y \in \cG \mid g(X) \neq 0 \}\text{.}\) If \(X \in \cA\text{,}\) then no follower of \(X\) is in \(\cA\) (because otherwise \(g(X) \neq 0\)). In other words, every follower of \(X\) is in \(\cB\text{.}\) Meanwhile, if \(Y \in \cB\) then \(g(Y) \neq 0\text{.}\) This means that there is at least one follower of \(Y\) that is in \(\cA\text{.}\) By TheoremĀ 1.3.6, \(\cA\) is the set of \(\cP\)-positions and \(\cB\) is the set of \(\cN\)-positions.

In the next section, we will finally show that the nim value of a Nim position is identical to its Sprague-Grundy value. In other words, the Sprague-Grundy value is truly a generalization of the Nim value.