OEIS A350148 · new terms a(6), a(7), a(8)

Square-filling motifs

A motif is a path through an n×n grid of tiles that runs along tile edges from one bottom corner to the other, using exactly one edge of every tile. Replace each tile by a shrunken, turned copy of the motif and repeat: you get a curve that fills the square. Most motifs crash into themselves after one or two rounds. McKenna calls the ones that never do globally self-avoiding; there is 1 on the 5×5 grid, 7 on 7×7, 10,101 on 9×9 and 20,305,328 on 11×11. We counted 13×13, 15×15 and 17×17.

Grid
Mode
Motif
Iterate
Colour
Path

Why it can be counted

Each tile owns one of its edges, and the direction the path runs along it says which side of the path the tile is on. That is the inside/outside colouring above: two neighbouring tiles differ exactly when the path runs between them.

McKenna proved two facts that make the problem finite. A globally self-avoiding motif, laid on a torus by gluing opposite sides of the square, is a single loop through every lattice point (left: the motif and its eight neighbours, centre copy bright). And its whole outer ring of tiles is fixed by one of a few zipping modes, a palindromic string of bits with no two 1s together (shown up the left side). The bits say where the path steps off the outer track and back.

With the ring fixed, what remains is a planar puzzle: give every inner tile one edge so that the edges form a single path through every interior point. A transfer matrix counts those row by row without listing them. 11×11 takes a tenth of a second (McKenna's listing took 147 CPU-hours), 13×13 eleven seconds, 15×15 nine minutes.

frozen ring1 bits (zipper)centre copy

How many there are

Counted per zipping mode; mirror images are not counted separately (every motif is either left- or right-handed). Bars show each mode's share, on a log scale.

nGrida(n)By zipping mode