Particular games

The short side only says how many

The rung below settled which cut to make in a Maundy Cake and left the value open. With the cut settled the recursion is a walk, the walk unrolls, and what it unrolls into is the running products of the long side's prime factors, largest first. The short side never enters the products at all — it decides how many of them there are and nothing else, so sixty-two different short sides give one value.

Assumes: Cut small unless you are behind · The size of a cake

The cut a Maundy Cake wants is settled: an extreme prime is always a best cut, and Ω\Omega decides which of the two. That rung closed on what it leaves undone:

The rung above is the value itself. With the cut settled, the recursion for a two-sided cake is a walk rather than a search, and a walk with a known rule is the kind of thing that unrolls into a formula: at each step the rule says which prime to divide by, so the sequence of sizes is determined by the two factorisations alone.

It unrolls. And the expression it unrolls into reads one of the two factorisations and throws the other away.

Running products, and where to stop. Six Maundy Cakes with the prime factors of the longer side, the running products those primes make, and the value the sum of them gives.
Fig. 1 Six cakes with the prime factors of the longer side, the running products those primes make, and the sum of them. The short side appears nowhere in the products — only in how many there are.

The walk, and where it stops

The walk the settled cut makes. A Maundy Cake taken down its own walk, one cut at a time, with the number of pieces accumulated so far. The pieces column is the sum the closed form adds up.
Fig. 2 A six by three hundred and sixty cake taken down its own walk. Each row is the cut the rule prescribes, and the last column is what that step contributes to the total.

Take a 6×3606 \times 360 cake. Ω(6)=2\Omega(6) = 2 and Ω(360)=6\Omega(360) = 6, counting prime factors with multiplicity, so the mover is four moves ahead on the long side and the rule from the rung below says cut at the largest prime. That is 55, leaving six copies of a 6×726 \times 72 cake.

Ω(72)=5\Omega(72) = 5, still three ahead, so cut large again — at 33, leaving 6×246 \times 24. Then at 33 again, leaving 6×86 \times 8. And there the walk stops, because Ω(8)=3\Omega(8) = 3 is exactly one more than Ω(6)\Omega(6), and a cake one ahead is worth 11 whatever its sides are.

Four steps, and no cut is ever made in the short side. That is the whole mechanism, and it is worth stating before the arithmetic: while the long side is two or more prime factors ahead, every move the analysis takes is a cut of the long side. The short side sits there being counted, and the only question it answers is when the walk stops.

The multipliers accumulate. Cutting a cake into jj pieces multiplies what one piece is worth by jj, so a chain of cuts at 55, then 33, then 33 carries a factor of 11, then 55, then 1515, then 4545 — the running products of the primes taken largest first. Each step contributes its own multiplier once, because the cake it leaves is worth one more than the cake beyond it. Adding the column gives 1+5+15+45=661 + 5 + 15 + 45 = 66, which is what the recursion returns for 6×3606 \times 360.

The sum, written out

Write Ω(k)\Omega(k) for the number of prime factors of kk with multiplicity, and P1P2P_1 \ge P_2 \ge \dots for the prime factors of nn largest first. Then whenever Ω(n)>Ω(m)\Omega(n) > \Omega(m),

V(m,n)=1+P1+P1P2++P1P2PΩ(n)Ω(m)1,V(m, n) = 1 + P_1 + P_1P_2 + \dots + P_1P_2\cdots P_{\Omega(n) - \Omega(m) - 1},

a sum of running products with Ω(n)Ω(m)\Omega(n) - \Omega(m) terms. When the two counts are equal the cake is worth nought — that is the sign rule two rungs below — and when Ω(m)>Ω(n)\Omega(m) > \Omega(n) the value is V(n,m)-V(n, m), because swapping the sides swaps the players.

Three things about that expression are worth separating.

The primes come from the long side only. P1,P2,P_1, P_2, \dots are the factors of nn, and mm contributes no prime to any product.

The number of terms is the difference of the two counts. That is the only place mm appears.

And the first term is the empty product. A cake one ahead has one term, which is 11, which is what the walk found at 6×86 \times 8.

The size of a cake gave the one-row formula as the running products of the primes largest first, and this is that expression with Ω(m)=0\Omega(m) = 0, where every term is kept. The rung below’s result was not a special case that happened to work; it was the general expression measured on the only cakes where the short side has nothing to say.

Sixty-two short sides, one value

The short side is only its length. Every number below two hundred grouped by how many prime factors it has, against the long sides it can face. Within a group the cake's value never changes.
Fig. 3 Every number below two hundred grouped by how many prime factors it has, against the long sides each group can face. Within a group the value never changes.

The consequence is the part that is not obvious, and it is worth being blunt about how strong it is.

There are sixty-two numbers below two hundred with exactly two prime factors — 44, 66, 99, 1010, 1414, 1515, and so on up to 187187. Put any one of them against a long side with more factors than two, and the cake is worth the same thing. A 6×3606 \times 360 cake is worth 6666; so is a 91×36091 \times 360, and so is a 4×3604 \times 360, and so is a 169×360169 \times 360. The sides differ by a factor of forty and the factorisations have no prime in common, and the game does not distinguish them.

Checked across every class and every long side in the grid, the value is constant within a class on all 512 of the (class, long side) pairs available — covering 15,473 cakes — and never once varies.

The mechanism is the walk. A cut is only ever made in the long side, so the short side’s shape never gets used; what gets used is the moment the walk halts, and that is decided by counting. Ω(m)\Omega(m) is a length, and a length is all the expression can see.

This is a different kind of statement from the sign rule, and the difference matters. The sign rule says the outcome is a function of two counts. This says the size is a function of one factorisation and one count — which is much more information than the sign, and still not the second factorisation.

What it was checked against

Forty thousand cakes, and no exception. The closed form against the recursion over a two hundred by two hundred grid, and against the game construction itself on the sizes it can reach.
Fig. 4 The closed form against the integer recursion over a two hundred by two hundred grid, and against the game construction itself on the sizes it can reach. No disagreement anywhere.

Every cake to 200×200200 \times 200 is valued twice: once by the integer recursion the rung below wrote, and once by two factorisations and a running product. The two agree on all 40,000.

That is a comparison between a formula and a recursion, and a recursion is itself a claim. So the small grid is valued a third time, by the construction — options, sums, canonical forms, and name reading the answer off the reduced game — and the formula matches the game on all 100 cakes to 10×1010 \times 10. That is the whole chain from the drawn number back to the rules of Maundy Cake, and it is why the sweep is worth running twice.

Ten by ten is small, and it is small for a reason: the construction builds the full game tree, and a 12×1212 \times 12 cake is already at the edge of what it can hold. The integer recursion is what carries the grid past that, and the closed form is what carries it past the recursion.

What the rejected descriptions score

What the rejected descriptions score. Three candidate descriptions of a Maundy Cake's size, and the closed form, each scored on every cake in a sixty by sixty grid.
Fig. 5 Three candidate descriptions of a cake’s size, and the closed form, each scored on every cake in a sixty by sixty grid. The best of the rejected candidates reaches three quarters.

A formula arriving with nothing to beat is not a result, so the candidates the size of a cake named and rejected are run on the same grid.

Subtracting the two one-row values — V(1,n)V(1,m)V(1, n) - V(1, m) — is right on 532 of 3,600, which is 15 per cent, and it is the natural first guess because both games are about how many moves a side holds.

n/m1n/m - 1 where mm divides nn scores 27 per cent, which is roughly what a rule that is right on the zero cells and nowhere else would score, because the zero cells are numerous.

And a rule reading only Ω\Omega reaches 76 per cent. That one is worth pausing over, because it is the ceiling on the sign rule’s approach: give a rule the difference Ω(n)Ω(m)\Omega(n) - \Omega(m) and let it answer with the commonest value in that cell, and it is right three times in four. Three quarters is high enough to look like a rule and far too low to be one — the missing quarter is where the actual primes matter, and the actual primes are exactly what the running products supply.

That the counts alone get three quarters of the way is the reason the ladder stopped at the sign for two rungs. A quantity that explains most of a table is the most persuasive kind of wrong answer, which is the reading the entry fee was the cap records on a different ladder and a bound with one number too many records on a third.

What a closed form buys

Cakes nothing else here can value. Six Maundy Cakes far past the reach of any recursion on this site, valued by the closed form, with how many terms each sum has.
Fig. 6 Six cakes far past the reach of any recursion here, valued by the formula. The last of them is a thousand-trillion-column cake.

The dividend is the sizes it settles.

A 6×2306 \times 2^{30} cake is worth 268,435,455268{,}435{,}455. The game construction cannot represent that position, the integer recursion would need every divisor of every intermediate size along a walk of thirty steps, and the formula needs two factorisations and twenty-eight multiplications. A 248,832×1015248{,}832 \times 10^{15} cake is worth 7,629,394,5317{,}629{,}394{,}531, and the whole computation is a running product over fifteen primes.

That is what a closed form is for on this site, and it is not elegance. It is that the cost of the answer stops being the cost of the game and becomes the cost of factorising two integers — a quantity that has nothing to do with combinatorial game theory at all.

A variable that turns out to be a counter

The finding here has a shape that is worth recognising, because it is one of the more satisfying things that can happen to a two-variable problem and it is easy to mistake for a simplification.

A quantity that enters a formula only through how many times something happens is not a variable of the formula at all; it is a loop bound. The formula is over the other variable, and the first one says where to stop.

That is what the short side turns out to be. It contributes nothing to the products — no prime of it appears anywhere in the answer — and it decides how many of the long side’s running products are taken. Sixty-two different short sides giving one value is that statement measured: any two short sides with the same count produce the same answer, and the count is Omega\\Omega.

It also explains why the earlier rungs’ rules are stated in Omega\\Omega rather than in the sides. A rule comparing Omega(m)+1\\Omega(m)+1 against Omega(n)\\Omega(n) is comparing two loop bounds, and a loop bound is exactly the kind of thing a rule about which cut to make would depend on: the cut decides how fast one of the two counters runs down.

The general form is worth carrying to any two-parameter family. Before looking for a formula in both, check whether one of them appears only as a count — because if it does, the family is a one-parameter family indexed by an integer, and the answer is a sequence with a length rather than a function of two things.

What this does not say

It is not a theorem. The expression is a consequence of the cut rule below it, and that rule is a measurement over 6,320 cakes with no proof under it. So this formula inherits exactly that standing: an identity checked on forty thousand cases with an argument behind it, not an induction. The argument is the walk, and the missing step is showing that the extreme-prime rule is optimal rather than merely best on everything tried.

The grid stops at two hundred. Ω\Omega reaches seven there, on 128128 and 192192, so the longest sum checked has seven terms. Nothing about the derivation suggests a change further out — the walk does not know how large the numbers are — but a sum of thirty terms has been computed and not verified, because there is nothing left to verify it against.

The picture cannot show the game. Every figure here is a table of numbers, and that is not an evasion: a 6×3606 \times 360 cake is a rectangle of 2,160 squares and drawing it would show 2,160 squares. The position is arithmetic and the drawing that would help does not exist, which is the one place this site’s figure-first rule gives way to the subject. What is drawn instead is the walk — the sequence of cakes the rule visits — because the sequence is the object the formula is about.

And it says nothing about play. A cake worth 268,435,455268{,}435{,}455 tells a player which side of the position they are on and not one move to make. The cut rule from the rung below names the move; this names the number. Numbers avoid numbers is why the two stay separate here and always will: every Maundy Cake is a number, so neither player wants to move at all, and the value measures who is compelled to.

The formula’s shape, and where the site has seen it

There is a family resemblance worth naming, because it is the second time this shape has turned up.

The expression is a positional numeral in a mixed radix. Writing the terms out, 1+P1+P1P2+1 + P_1 + P_1P_2 + \dots is the number whose digits are all 11 in the base system whose place values are the running products of the primes — so a 1×2k1 \times 2^k cake is worth 2k12^k - 1, which is kk ones in binary, and a 1×3k1 \times 3^k cake is (3k1)/2(3^k - 1)/2, which is kk ones in base three.

A numeral in the empty squares found the same thing on a Push strip: a value that is a numeral whose digits are read off the position and whose place values are set by the geometry. Two games with nothing in common — one a partizan cutting game about factorisations, the other a strip of tokens — and the same object underneath, because both are positions whose options are nested at a fixed ratio.

That is not a general theorem and it is not offered as one. It is a note that when a game’s recursion is a walk with a multiplier at each step, the value it accumulates is a numeral, and the base is whatever the multipliers are. Where the multipliers are all 22, the numeral is binary and the site has several of those.

The convention, named

Normal play throughout: a player who cannot cut loses.

Maundy Cake is played on an m×nm \times n rectangle. Left cuts along one axis and Right along the other, and a cut must divide the cake into equal pieces, all of which stay in play — so a side of nn may be cut into jj pieces for any divisor j>1j > 1 of nn. It is Cutcake with the equal-pieces clause added.

Ω(k)\Omega(k) counts the prime factors of kk with multiplicity: Ω(12)=3\Omega(12) = 3 and Ω(1)=0\Omega(1) = 0. The primes largest first are that multiset sorted downward, so 360360 contributes 5,3,3,2,2,25, 3, 3, 2, 2, 2.

The long side is the one with more prime factors and the short side the one with fewer; when they are equal the cake is worth nought and neither name is needed. Every Maundy Cake is a whole number, which is what lets the sweep run on integers with the simplicity rule in place of the construction.

The walk is the sequence of cakes the cut rule visits from a starting cake, each obtained from the last by dividing the long side by one prime. It has Ω(n)Ω(m)1\Omega(n) - \Omega(m) - 1 steps and it never touches the short side, which is the fact the whole page turns on.

Where the ladder goes next

The cutcake anchor has five rungs: the game and its binary-length rule, the equal-cut variant and the Ω\Omega rule for its sign, the size on one row, which cut to make on two, and now the value itself.

The rung above is the proof, and this is the first time the anchor has had a statement worth writing one about. The induction has a visible shape: assume the formula at Ω(n)Ω(m)=d\Omega(n) - \Omega(m) = d, and show that cutting the long side at its largest prime gives P1P_1 copies of a cake at d1d - 1, so the value is P1P_1 times the smaller sum plus one. What that needs is the missing half of the rung below — that no other divisor beats the extreme prime — and that is the one statement on this ladder still resting entirely on a grid. An induction on Ω(m)+Ω(n)\Omega(m) + \Omega(n) would settle both at once, and everything else here would become a corollary.

Two neighbours are worth the trip. Cutcake is the game one clause away, whose answer is about binary length rather than primes, and whose values do not collapse this way at all — a good reminder of how much the equal-pieces clause is doing. And a numeral in the empty squares is the other place on this site where a value turns out to be a numeral read off the position, and reading the two together is the clearest way to see what the shape has in common and what it does not.

Part 5 of 7

One argument about Cutcake. The parts either side of it:

What links here

Essays that reach for this one mid-argument — the half of a link its own author cannot write down.

What this makes readable

Essays that declare this one a prerequisite.

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.

Closed formCutcakeEnumerationInductionIntegerInvariantMaundy cakeNumberPartizanRecursionSimplicity ruleValue