Grundy-number and nim-sum conjecture for amalgamation Nim with restriction

About 13 years old · traced to

A position is a triple (x,y,z)(x,y,z) of nonnegative integers, and its Grundy number is the Sprague–Grundy value of that position; write x⊕y⊕zx\oplus y\oplus z for the bitwise nim-sum. For n∈Z≥0n\in\mathbb{Z}_{\geq 0}, the conjecture concerns the relationship between the Grundy number and this nim-sum. Grundy-number and nim-sum conjecture. If the Grundy number of a position (x,y,z)(x,y,z) is 2n2n, then x⊕y⊕z=2nx\oplus y\oplus z=2n or x⊕y⊕z=2n+1x\oplus y\oplus z=2n+1; if the Grundy number is 2n+12n+1, then x⊕y⊕z=2nx\oplus y\oplus z=2n or x⊕y⊕z=2n+1x\oplus y\oplus z=2n+1. The conjecture would give an elegant mathematical structure for the variant of amalgamation Nim studied in the paper; no resolution is supplied here.

References

Primary source

Hikaru Manabe, “An Amalgamation Nim with Restriction”, arXiv:2411.14488 (2024).

Additional references

3 papers in this index state this conjecture (2013–2024). The statement above is taken from the most recent of them; the others are arXiv:1511.00537, arXiv:1312.6503.

Progress summary

Refreshed
Claimed progress

The published paper leaves the conjecture open, while an unverified submitted proof claims an explicit formula that would settle it.

The conjecture concerns the restricted three-heap game of Manabe’s paper: it predicts that the Grundy value and ordinary nim-sum always lie in the same consecutive pair, namely {2n,2n+1}\{2n,2n+1\}. The paper presents this as Conjecture 1 without proving or disproving it.

Community submission (unverified)

A submitted proof argues that, writing xi=2ui+εix_i=2u_i+\varepsilon_i, the exact value is G(X)=(x1⊕x2⊕x3)⊕δ(X)\mathcal G(X)=(x_1\oplus x_2\oplus x_3)\oplus\delta(X), where δ(X)\delta(X) depends on the number of disjoint-bit edges among the positive uiu_i. If correct, this proves the conjecture; the submission is not independently verified.

Current status (as of August 2026): The conjecture remains unverified; the only reported resolution is an unverified community submission claiming an explicit Grundy formula.

Sources

Solutions 1

ProofThis solution needs a summarySee full solutionHide full solution

An explicit Grundy formula for restricted amalgamation Nim

Hikaru Manabe, An Amalgamation Nim with Restriction, arXiv:2411.14488, Conjecture 1, asks whether the Grundy value of every three-heap position belongs to the same consecutive even-odd pair as its ordinary nim-sum. We prove the conjecture by obtaining the full Grundy value explicitly.

The legal moves are those of Definitions 4 and 5 of the source: decrease one heap by any positive amount, or merge two heaps when each contains at least two stones. Thus a merge replaces heaps xi,xj≥2x_i,x_j\geq2 by xi+xjx_i+x_j and 00.

The formula

For a position X=(x1,x2,x3)X=(x_1,x_2,x_3), write

xi=2ui+εi,ui≥0,εi∈{0,1}.(1)x_i=2u_i+\varepsilon_i, \qquad u_i\geq0, \qquad \varepsilon_i\in\{0,1\}. \tag{1}

Here ⊕\oplus denotes bitwise exclusive-or and &\mathbin{\&} denotes bitwise conjunction. Form a simple graph HXH_X on the three heap indices by declaring

ij∈E(HX)⟺ui>0,uj>0,ui&uj=0.(2)ij\in E(H_X) \quad\Longleftrightarrow\quad u_i>0,\quad u_j>0,\quad u_i\mathbin{\&}u_j=0. \tag{2}

Let e(X)=∣E(HX)∣e(X)=|E(H_X)|, and define

δ(X)={1,e(X)=1 or e(X)=2,0,e(X)=0 or e(X)=3.(3)\delta(X)= \begin{cases} 1,&e(X)=1\text{ or }e(X)=2,\\ 0,&e(X)=0\text{ or }e(X)=3. \end{cases} \tag{3}

Then the exact Sprague--Grundy value is

G(x1,x2,x3)=(x1⊕x2⊕x3)⊕δ(X).(4)\boxed{ \mathcal G(x_1,x_2,x_3) =\bigl(x_1\oplus x_2\oplus x_3\bigr)\oplus\delta(X). } \tag{4}

In particular, restricted amalgamation changes the ordinary nim-sum exactly when the compatibility graph has one or two edges, and then changes only its least significant bit.

Proof by the mex characterization

Put

q(X)=u1⊕u2⊕u3,η(X)=ε1⊕ε2⊕ε3,h(X)=η(X)⊕δ(X).(5)q(X)=u_1\oplus u_2\oplus u_3, \qquad \eta(X)=\varepsilon_1\oplus\varepsilon_2\oplus\varepsilon_3, \qquad h(X)=\eta(X)\oplus\delta(X). \tag{5}

The proposed value in (4) is equivalently

F(X)=2q(X)+h(X).(6)F(X)=2q(X)+h(X). \tag{6}

We induct on the strictly decreasing game rank

rk⁡(X)=x1+x2+x3+∣{i:xi>0}∣.(7)\operatorname{rk}(X) =x_1+x_2+x_3+ \bigl|\{i:x_i>0\}\bigr|. \tag{7}

A heap reduction decreases the number of stones, while a merge preserves that number and decreases the number of nonempty heaps. Hence every legal follower has strictly smaller rank, and we may assume its Grundy value equals FF.

First, fix any integer q′q' with 0≤q′<q(X)0\leq q'<q(X). The standard nim move on the half-heaps gives an index ii and an integer ui′<uiu_i'<u_i such that

u1⊕⋯⊕ui′⊕⋯⊕u3=q′.(8)u_1\oplus\cdots\oplus u_i' \oplus\cdots\oplus u_3=q'. \tag{8}

Both replacements

xi⟼2ui′,xi⟼2ui′+1(9)x_i\longmapsto 2u_i', \qquad x_i\longmapsto 2u_i'+1 \tag{9}

are legal, because ui′<uiu_i'<u_i. Their half-heaps and compatibility graphs agree, while their least significant bits are opposite. Consequently their proposed values are precisely

2q′and2q′+1.(10)2q' \quad\text{and}\quad 2q'+1. \tag{10}

Thus every integer smaller than 2q(X)2q(X) occurs among the Grundy values of the followers.

We next classify the followers satisfying q(Y)=q(X)q(Y)=q(X). If YY is obtained by reducing one heap, equality of the half-heap nim-sums forces its half-heap to remain unchanged. Therefore the only possibility is

2ui+1⟼2ui.(11)2u_i+1\longmapsto 2u_i. \tag{11}

The compatibility graph stays fixed, whereas η\eta changes; hence

h(Y)=h(X)⊕1.(12)h(Y)=h(X)\oplus1. \tag{12}

Suppose instead that heaps xi=2ui+εix_i=2u_i+\varepsilon_i and xj=2uj+εjx_j=2u_j+\varepsilon_j are merged. Their new half-heap is

⌊xi+xj2⌋=ui+uj+εiεj.(13)\left\lfloor\frac{x_i+x_j}{2}\right\rfloor =u_i+u_j+\varepsilon_i\varepsilon_j. \tag{13}

Consequently q(Y)=q(X)q(Y)=q(X) holds exactly when

ui⊕uj=ui+uj+εiεj.(14)u_i\oplus u_j =u_i+u_j+\varepsilon_i\varepsilon_j. \tag{14}

Using

ui+uj=(ui⊕uj)+2(ui&uj),(15)u_i+u_j =(u_i\oplus u_j)+2(u_i\mathbin{\&}u_j), \tag{15}

we see that (14) is equivalent to

ui&uj=0,εiεj=0.(16)u_i\mathbin{\&}u_j=0, \qquad \varepsilon_i\varepsilon_j=0. \tag{16}

Because a legal merge requires ui,uj>0u_i,u_j>0, the merged pair is an edge of HXH_X. If the remaining half-heap satisfies uk>0u_k>0, then it is compatible with the merged half-heap precisely when it was compatible with both original half-heaps:

(ui+uj)&uk=0⟺ui&uk=0 and uj&uk=0.(17)(u_i+u_j)\mathbin{\&}u_k=0 \quad\Longleftrightarrow\quad u_i\mathbin{\&}u_k=0 \ \text{and}\ u_j\mathbin{\&}u_k=0. \tag{17}

If uk=0u_k=0, none of the three relevant edges involving kk exists. Thus, in all cases, the possible edge-count transitions are exactly

e(X)=1⟼e(Y)=0,e(X)=2⟼e(Y)=0,e(X)=3⟼e(Y)=1.(18)e(X)=1\longmapsto e(Y)=0, \qquad e(X)=2\longmapsto e(Y)=0, \qquad e(X)=3\longmapsto e(Y)=1. \tag{18}

In every case δ(Y)=δ(X)⊕1\delta(Y)=\delta(X)\oplus1. A merge preserves the xor of the least significant heap bits, so η(Y)=η(X)\eta(Y)=\eta(X). Therefore (12) also holds for every merge preserving qq.

It follows that no follower YY has F(Y)=F(X)F(Y)=F(X): followers with different qq lie in different consecutive even-odd pairs, and followers with the same qq have the opposite bit by (12).

Finally, if h(X)=1h(X)=1, the remaining smaller value 2q(X)2q(X) must also occur. If some εi=1\varepsilon_i=1, the legal reduction (11) preserves qq and changes hh to 00. Otherwise all three εi\varepsilon_i vanish, and

1=h(X)=δ(X).(19)1=h(X)=\delta(X). \tag{19}

Hence e(X)=1e(X)=1 or 22. Choose any edge of HXH_X. Its two heaps are positive even integers at least two, so their merge is legal; by (16)--(18), it preserves qq and changes hh to 00. In either case there exists a follower with value 2q(X)2q(X).

We have proved that every integer smaller than F(X)F(X) occurs as a follower value, while F(X)F(X) itself does not. Hence

G(X)=mex⁡{G(Y):Y is a legal follower of X}=F(X),(20)\mathcal G(X) =\operatorname{mex}\{\mathcal G(Y):Y\text{ is a legal follower of }X\} =F(X), \tag{20}

completing the induction and proving (4).

Resolution of the conjecture

Since δ(X)∈{0,1}\delta(X)\in\{0,1\}, equation (4) immediately gives

⌊G(x1,x2,x3)2⌋=⌊x1⊕x2⊕x32⌋.(21)\left\lfloor\frac{\mathcal G(x_1,x_2,x_3)}{2}\right\rfloor = \left\lfloor\frac{x_1\oplus x_2\oplus x_3}{2}\right\rfloor. \tag{21}

Thus, for every n≥0n\geq0,

G(x1,x2,x3)∈{2n,2n+1}⟺x1⊕x2⊕x3∈{2n,2n+1}.(22)\mathcal G(x_1,x_2,x_3)\in\{2n,2n+1\} \quad\Longleftrightarrow\quad x_1\oplus x_2\oplus x_3\in\{2n,2n+1\}. \tag{22}

This proves both clauses of Manabe's Conjecture 1 and strengthens them to the exact closed formula (4).