##
Nim-Chomp *August 19, 2010*

*Posted by lumixedia in combinatorics, math, Problem-solving.*

Tags: combinatorial game theory, combinatorics, rsi

trackback

Tags: combinatorial game theory, combinatorics, rsi

trackback

Wow, I’m really not cut out for helping to maintain a blog, am I? So what finally prompted me to post was Dr. Khovanova’s description of the game of Nim-Chomp at her blog, which she suggested I respond to.

So Dr. Khovanova described Nim-Chomp to me at RSI more than a year ago, and I thought I solved it. Then a few months ago I found a flaw, thought it was hopeless, and gave up. Then a few minutes ago I realized that the flaw was in fact fixable. The point of this paragraph is that I’m not sure I’m to be trusted regarding this problem, but I’ll try.

I won’t repeat the problem statement here. Too lazy. Just read her post. Because I find it easier to think about this way, I’ll make a slight modification to the Chomp perspective on Nim-Chomp: on a given turn, each player may only eat squares from a single *column* (rather than a single *row*).

First let’s pretend the bottom left square is not actually poisoned. We can transform this easy-Nim-Chomp into regular Nim as follows: for a given position in easy-Nim-Chomp, suppose the number of squares remaining in each column is a_{1}, a_{2}, …, a_{n} from left to right. Let b_{1} = a_{1} – a_{2}, b_{2} = a_{3} – a_{4}, …, b_{[n/2]} = (a_{n-1} – a_{n}) or (a_{n}) depending on whether n is even or odd. Then this position is equivalent to regular Nim with piles of b_{1}, b_{2}, …, b_{[n/2]}. Basically, we’re splitting the chocolate columns into pairs of adjacent columns and considering the differences between the members of each pair to be the piles of our regular game of Nim. Because the piles are in nonincreasing order, this is a well-defined transformation.

It works as follows: suppose the loser of the Nim-game (b_{1}, b_{2}, …, b_{[n/2]}) eats some squares from the kth column where k is odd. This decreases the value of a_{k}, thereby decreasing one of the Nim-piles as in a regular Nim-game, so the winner just makes the appropriate response. Instead, the loser might try to dodge by eating squares from the kth column where k is even, thus decreasing the value of a_{k} but increasing one of the Nim-piles rather than decreasing it, which can’t be done in regular Nim. But the winner can simply decrease a_{k-1} by the same amount and leave the loser in the same position as before. There are a finite number of squares, so the loser can’t keep doing this. Eventually they must go back to decreasing piles, and lose.

This is how far I got at RSI. I didn’t realize the poisoned lower-left square was a significant issue, but it is. Thankfully, all it really does (I think) is turn the game into misère Nim rather than normal Nim. We make the transformation to Nim-piles in the same way as before, and the winner uses nearly the same strategy as in the previous paragraph, but they modify it to ensure that the loser is eventually faced with “b_{k}”s which are all 0 or 1 with an odd number of 1s. (Maybe one day if I get around to writing a basic game theory post I’ll explain why this is possible. Or you can check Wikipedia. Or just think about it.) When the loser increases some b_{k}, the winner eats squares in the corresponding column to decrease it back to 0 or 1; when the loser decreases a 1 to a 0, the winner decreases another 1 to a 0.

Eventually, the loser is forced to hand the winner a chocolate bar consisting of pairs of adjacent equal columns. At this point the winner takes a single square from any column for which this is possible, leaving a bunch of 0s with a single 1—i.e. another misère 2^{nd}-player win. This continues until we run out of squares, at which point we conclude that the loser of the new game of misère Nim is indeed the player who consumes the poisoned square in the original game of Nim-Chomp.

Question I’m too lazy to think about right now: can we still do this or something like this if we poison not only the bottom left square of the chocolate bar, but some arbitrary section at the bottom left?

Cute problem. I haven’t fully convinced myself your solution works, but it looks like a very nice idea. About your extension (to an arbitrary set of poisoned squares in the lower-left corner): if we think of Chomp as taking place in a Young diagram, then this modification is the modification to a skew Young diagram. It seems to me like something analogous should work, except that the players should play to make the nimber of the position equal to that associated to the inner shape, rather than to 0, no? In fact, this generalization also covers the non-misere version of the game, doesn’t it? I probably should refresh my memory of the strategy for misere Nim to see that I’m not talking nonsense.

http://www.transience.com.au/pearl3.html

I’m attempting to win this game with no luck. HELP PLEASE!

Thanks for another great post. Where else could anyone get that type of info in such an ideal way of writing? I have a presentation next week, and I am on the look for such info.

i think this is late for me, but very useful, thanks a lot for this post