What Moore's rule needed that Bouton's did not
Assumes: The step nobody took for thirty-four years · Taking from several heaps at once
Between Bouton’s paper of 1901 and the theorem of 1935 there is exactly one step, and it has been isolated: Bouton says a Nim position is lost when its heap sizes exclusive-or to nothing, and Sprague and Grundy say a sum of any impartial games is lost when the heaps’ Grundy values do. Same operation, different quantity. The essay that isolated the step ended on a question about the other complete solution of that decade:
Replace the heap sizes in Moore’s criterion by some per-heap quantity and ask whether any assignment makes it exact on a game it was not written for … If some assignment does, then the 1910 paper was one substitution from a theory of a family of games rather than of one.
The obvious assignment is the one that worked in 1935, and the answer to it is clean. Moore’s criterion with Grundy values substituted is exact on precisely the games in which no move can raise a Grundy value, and wrong on every other game tested. The family exists. It is the family of games that behave like Nim measured in a larger unit — which is to say that 1910 was one substitution away from a theory of its own game in disguise, and of very little else.
The rule, the game, and the substitution
Moore’s Nim lets a player take counters from as many as heaps in one move, any amount from each, at least one counter in all. Moore proved in 1910 that the player to move loses exactly when the heap sizes, written in binary and stacked, have every column summing to a multiple of . At that is Bouton’s rule, since a column sum divisible by two is an even one.
To ask the substitution question the game has to be widened first, because the question is about other games. The Moore compound of some component games is played like this: a move chooses between one and of the components and makes a legal move in each of the chosen ones. With Nim heaps as components it is Moore’s game. With heaps of a subtraction game — take one or two counters, say — it is a game Moore never considered, and it has a perfectly good set of lost positions that a search can find.
The substituted criterion is Moore’s test with each heap’s size replaced by its Grundy value in its own game: write the values in binary, stack them, and call the position lost when every column sum is divisible by . At the Moore compound is the ordinary disjunctive sum and this is the Sprague–Grundy theorem, exact on everything — the first row of the figure is a control, and it passes on all 127 games.
The two other rows are the finding. At two heaps a move and four heaps in the position, and at three a move and five heaps, the substituted criterion agrees with search on every position of 34 games and disagrees somewhere in each of the other 93. Not one game in the census lies between. The 34 are the games in which no move from any heap reaches a heap of larger Grundy value; the 93 are the games in which some move does.
What “never climbs” means in a range of heaps
A climb is a legal move from a heap of value to a heap of value greater than . The mex rule forbids a move to the same value and guarantees one to every smaller value, and about larger values it says nothing. In most games they are there: in take one or two, whose values run , a heap of three is worth nought and moves to a heap of one worth one.
Bouton’s own transplant counted these chances and found Nim the only game of five that never takes one. The census above does the same per game, and one caution belongs to it before any of its numbers are quoted. Heaps run to eight, and a game cut off at heap eight is itself a game — heaps only shrink — so the count of 34 is a count of games that never climb in that range. Twenty-four of them are any-take-but games, which never climb at any size; ten are finite take-sets such as take 5 or take 4 or 5, which climb by heap twice their largest take and have simply not reached it by eight. Inside the range both kinds behave identically, and the criterion treats them identically. That is the right result rather than a loophole: the claim being tested is about the game played, and the game played stops at eight.
The one fact Moore’s proof used about a heap
Why should climbing matter? Because Moore’s own proof uses one fact about heap sizes that is true of sizes and false of most Grundy values, and nobody reading the proof about Nim could tell it was being used.
The proof has two halves, as Bouton’s does.
From a lost position, every move leads to a won one. A move changes at most heaps. Look at the highest binary column in which any changed heap differs. Every changed heap that differs there has decreased, so each has gone from a one to a nought in that column; the column sum has dropped by at least one and at most , which cannot be a multiple of . So the column is no longer divisible, and the position is not lost.
From any other position, some move leads to a lost one. Work down the columns from the top, choosing at most heaps to lower so that every column comes out divisible. The choice needs each chosen heap to be lowerable to whatever smaller size the arithmetic asks for, and a Nim heap can be.
Substitute Grundy values and read the halves again. The second survives untouched: the mex rule guarantees a move from any heap to every smaller value, which is exactly what the construction asks of a heap. The first survives too, provided every changed heap’s value goes down. That is the word the proof leaned on — decreased — and it is not a property of a Grundy value. It is the property of never climbing.
So one direction is a proof, and it is short. If a game never climbs, Moore’s criterion on its Grundy values is exact at every and every number of heaps, because both halves of Moore’s 1910 argument go through word for word. And the same holds for a position mixing several games, as long as none of them climbs, since the argument only ever looks at one heap at a time.
A move the binary columns cannot see
The other direction needs a position where the criterion fails, and climbing supplies one by a construction small enough to hold in the hand.
In take one or two with four heaps and up to two changed a move, take the heaps . Their values are , and the column of ones sums to three: divisible by three, so the criterion calls the position lost. Now make one move in two heaps at once — empty one of the heaps of one, and take two from the heap of three. The values become . They are the same four numbers in a different order, so the columns have not changed and the criterion calls this position lost as well.
Two lost positions cannot be joined by a move; that is what lost means. So the criterion is wrong about one of them, and search says which: is won, and the move just described wins it.
What makes the move invisible is that it is a swap. One heap drops from value to value and another climbs from to , and the multiset of values, which is all the criterion reads, comes out where it started. Two ingredients are needed. A climb from to , which is what the game has to supply. And the freedom to change two heaps in one move, which is what Moore’s rule supplies at every .
From that the general statement takes one more line. Given any climb from to , set out heaps of value and heaps of value . Every column sum is a multiple of , so the criterion calls it lost; and the swap — the climb in one heap, a drop from to in another, which the mex rule guarantees — leads to the same multiset again. Every game that climbs anywhere defeats the substituted criterion at heaps. Together with the proof above, the substituted criterion is exact on exactly the games that never climb, at every of two or more.
Why the 1935 theorem never had to care
That raises a question about the theorem that did work. Sprague and Grundy substituted into Bouton’s criterion, the values climb in nearly every game, and the result is exact everywhere. Why is the same climb harmless there?
Because at a move changes one heap, and a swap needs two. A single heap’s value cannot change while the multiset of values stays fixed, so no move joins two positions with the same exclusive-or, climbing or not. The mex rule’s silence about larger values is never tested, because the rule of the disjunctive sum — one component per move — forbids the only manoeuvre that would test it.
This is the connection worth carrying away, because it runs against the usual account. The Sprague–Grundy theorem is usually described as working for all games, and so it does; but what it tolerates — values that go up as well as down — it tolerates because of the sum, not because of the values. The other ways of adding games, where one move may touch several components, have no value theory of this kind, and the swap is the smallest reason why. Moore’s parameter is a dial on the one feature of the sum that was protecting it, and turning the dial from one to two removes the protection at once.
Moore’s own game hides all of this, as Bouton’s hid the climbing values: a Nim heap’s value is its size, a size only goes down, and a proof written about Nim cannot reveal which of the two facts it rests on.
Safe below heaps, for any games
The construction needs heaps. The search finds the criterion wrong much sooner, and also finds a range in which nothing can go wrong whatever the games.
The lower edge of the error region is a theorem. With at most heaps, a column sum is at most , so divisibility by means every column is empty and the criterion reads every value is nought. With exactly heaps a column sum is divisible only at nought or , so the criterion reads every value is the same. In both cases no move stays inside the set: a move changes at most heaps, each changed heap’s value changes (the mex rule forbids a move to the same value), and with heaps at least one heap is left as it was. Once one value has moved, the values are no longer all equal, and with all values nought one of them has stopped being nought. And from outside the set, lowering every heap above the smallest value to that value takes at most heaps, which is a legal move. Climbing never enters.
So a position of up to components is decided by the substituted criterion for any games at all. With or fewer it is the selective compound’s rule — a position is lost when every component is lost. With exactly it is something less familiar: lost exactly when all the components have the same Grundy value.
The upper edge is a measurement. In take one or two the first errors come at heaps, four heaps at two a move and five at three, not at the six and eight the construction needs; and in the census every one of the 93 climbing games is already wrong at . A shorter swap explains the example — a climb from nought to , beside heaps of value , makes a criterion-lost position of heaps, and the swap leaves it lost — but not every climb starts at nought, and the general construction at needs the game to have heaps of the values and to fill the columns. That every climbing game fails at is measured on 127 games and not proved.
Three different games at once
The safe region is worth testing on its own terms, since its argument used nothing about the components being alike.
Take one heap of take one or two, one of take 1, 3 or 4 and one of any take but 2, and let a move change up to two of them. All three games climb. Of the 729 positions with heaps up to eight, 48 are lost, and they are exactly the 48 whose three Grundy values are equal. The same holds with a different triple, 54 of 729. Add a fourth game and allow three a move, and the lost positions are the 156 with all four values equal. Allow only two a move with the same four heaps, and the criterion is wrong on 378 positions.
That is a curious statement for a mixed compound, and it is checkable by hand on a small board: three unrelated take-away games on one table, a player allowed to move in any two of them, and the player to move loses exactly when the three heaps are worth the same. Nothing about the games’ rules appears in it except through their values, and the values climb freely.
Wrong in both directions
When the criterion fails past the safe region, it fails in a way that is worth contrasting with the failure Bouton’s criterion had.
Bouton’s 1901 criterion carried to a subtraction game was wrong in one direction only: it called some lost positions won and never the reverse, because the subtraction game’s values were a fixed part of the heap sizes and the old test could only refuse positions the true one accepted. That made it sound but incomplete, which is a usable thing to be.
The substituted Moore criterion has no such shape. In take one or two at five heaps it calls 82 lost positions won and 80 won positions lost; in take one or three, 42 and 238. Both kinds follow from the swap. A position the criterion accepts but which has a swap to another accepted position is a win called lost — the first panel of the move figure. And a position the criterion rejects can still be truly lost, once its true losing neighbours are no longer the ones the criterion names. Since half of Moore’s argument survives — every rejected position still has a move to an accepted one — the errors are not a matter of the criterion being too strict or too lenient. The accepted set is simply the wrong set, by a margin that grows with the number of heaps: 52 of 495 positions at four, 162 of 1,287 at five, 504 of 3,003 at six.
Nim in other units, and nothing else
So the family the question asked for exists. What is in it?
The census of games that never climb answered that before this question was asked. No game with a finite list of takes avoids climbing for ever — its values are bounded, and a bounded sequence cannot rise strictly along every chain of moves. Among games that allow every take except a finite list, many never climb, and every one of them has the Grundy sequence , where counts the smallest takes forbidden in an unbroken run: Nim with its heaps counted in units of .
In such a game a heap of value can move to every value below and to nothing else, which is exactly what a Nim heap of size can do. So its Moore compound is not merely decided by Moore’s criterion on the values. It is Moore’s own game, with each heap’s counters grouped into units and the remainder ignored. The figure checks that four such games, alone and mixed four to a position, obey Moore’s columns at two and at three heaps a move with no exception.
The substitution therefore buys two things over Moore’s original, and both are smaller than the 1935 one. It extends the 1910 rule to Moore’s game played in other units, which is a relabelling. And it decides every position of components or fewer, of any games at all, which is genuine but narrow. Past that, in every game that climbs, the Grundy value is not enough information to decide a Moore compound, and no rule built only on the values can be right.
The convention named
Everything here is under normal play: the player who cannot move loses. A move in the Moore compound chooses between one and components and makes a legal move of that component’s own game in each chosen one; for Nim heaps that is exactly Moore’s rule, take from up to heaps, and for other games it is the reading that keeps each component’s moves its own. Under misère play Moore’s game takes the same patch Bouton’s does, and nothing here was run under it.
The games are take-away games on single heaps — finite take-sets and any-take-but sets inside one to six — not octal games that split heaps, whose options are sums and whose values a single heap does not carry alone.
And the per-heap quantity tried is the Grundy value and nothing else. The question as it was left allowed any assignment, and the Grundy value is the obvious one because it is the one that worked in 1935. That no other assignment works on a climbing game is not shown here. What is shown is narrower and still decisive for the Grundy value: on a climbing game the outcome of a Moore compound is not a function of the heaps’ Grundy values at all, since the two ends of a swap share every value and differ in outcome.
What the census cannot show
Exhaustive search over heaps to eight, at most six heaps, and from one to three. The proofs cover every size: never climbing implies exactness everywhere, and a climb anywhere implies failure at heaps. The census adds two things the proofs do not — that 34 and 93 split the 127 games the way the proofs say, which is a check on the search rather than new information, and that failure arrives at heaps in every climbing game tried. The second is the one claim here that a larger range could overturn, and the place to look is a game whose only climbs start high and whose values are too few to fill the columns of a short swap.
The figures also show only that the criterion fails past heaps, and how often. They do not show what the lost positions of a climbing game’s Moore compound are. Bounded Moore’s Nim met the same wall from the other side — residues of heap sizes that could not determine the outcome at — and needed a statistic of the whole position rather than of each heap.
Who did what, and when
E. H. Moore published his game and its column rule in the Annals of Mathematics in 1910. R. P. Sprague and P. M. Grundy published the value theorem in 1935 and 1939. Compounds in which a move touches several components at once — conjunctive and selective — were studied by C. A. B. Smith in 1966 and are set out in Winning Ways. When is at least the number of components the Moore compound is the selective compound, and the rule above for heaps or fewer is that compound’s own. The intermediate family, at most components a move with more than on the table, is Moore’s rule widened to other games, and the census, the swap and the boundary above are computed here rather than quoted.
Still open: what a climbing heap has to report
The Grundy value is not enough for a Moore compound of a climbing game, and the swap says exactly what it misses: whether a heap can rise, and to where. A heap of take one or two worth nought that can reach a value of one is not the same component, under Moore’s rule, as a Nim heap of nought that can reach nothing.
So the natural next quantity is the value together with the set of larger values the heap can climb to. That pair determines everything the swap uses, and it is finite for every take-away game — a heap of a bounded game has finitely many options. Whether it is enough is a question with an exact answer on the same census: group each game’s heaps by the pair, and ask whether two positions that agree heap by heap on it ever differ in outcome. If they never do, Moore’s 1910 criterion was one table away from a theory of every take-away game, rather than one substitution away from a theory of Nim; if they do, a Moore compound needs to know something about a heap’s options that no summary of its values carries, which is a second way the theory runs out.
Part 9 of 9
One argument about Moores-nim. The parts either side of it:
The objects named here
The third axis, after the field and the series: the games, values and theorems themselves, and every essay that touches each one.
BoutonCounterexampleCriterionExhaustive searchGrundy valueMexMoores-nimNimSelective compoundSprague–GrundySubstitutionSubtraction game
- A chess problem that turned out to be an octal game exhaustive search, grundy value, mex, nim, sprague–grundy, subtraction game
- How long it lasts counterexample, exhaustive search, grundy value, mex, selective compound, subtraction game
- The sentence that solved the other convention bouton, counterexample, criterion, exhaustive search, grundy value, subtraction game
- A pass is not a move exhaustive search, grundy value, mex, nim, substitution
- A set with a short description bouton, criterion, exhaustive search, grundy value, subtraction game
- Four values, and the sequence is settled for ever exhaustive search, grundy value, mex, nim, subtraction game