A Different Way to Pack 17 Squares

The arrangement below is an n=17 square packing arrangement. It is not the world record, but it comes close. The arrangement requires a container very slightly larger - but it is a different topology, not merely a slight mutation.

Seventeen unit squares packed into a square container. Eleven are axis-aligned and six form an interlocking tilted\ncore.

The arangement at its topology-constrained limit. The container side is approximately 4.677648294965133 unit-square widths.

The best-known square packing arrangement for \(n=17\) has a container side of approximately

$$ 4.675530093604551 $$

The arrangement above needs

$$ 4.677648294965133 $$

It is therefore wider by about

$$ 0.002118201360582 $$

or roughly 0.0453% of the record container width. It is not, however, a poorly polished copy of the record - it is a completely distinct arrangement.

Bidwell’s best-known arrangement contains 10 axis-aligned squares and 7 tilted squares, divided between two different angles. This alternative contains 11 axis-aligned squares and 6 tilted squares. All 6 tilt at the same angle:

\[ \theta \approx 39.631881227553^\circ \]

The contacts between the squares are different too. To turn one arrangement into the other, squares would have to separate, move past one another and form a new network of contacts. In the language of the previous post, these are different packing arrangement topologies, rather than two noisy mutations of the same solution.

The Bidwell record packing and the alternative six-tilted-square topology shown side by side.

The record is narrower, but the two arrangements obtain their widths from different internal structures.

Frequent Rediscoveries

I did not set out to design the six-tilted arrangement by hand. It appeared during searches in which a program rotated or translated squares, compacted the result and retained promising states.

More interestingly, it did not appear only once. Four good-looking outputs, produced using more than one search strategy, had the following raw widths:

Search output Raw container width Distance from the topology limit
Learned top-\(K\), \(K=8\) 4.677835155206 0.000186860241
Learned top-\(K\), \(K=32\) 4.677848198015 0.000199903050
Learned top-\(K\), \(K=8\) 4.677970477889 0.000322182924
Family-balanced random, \(K=8\) 4.678278977657 0.000630682692

Basically, these are all reflections/rotations, or examples where a square has been moved or tilted very slightly to give a seemingly different arrangement.

After ‘polishing’ (i.e. optimising) the recurrences, they converged at this width:

\[ 4.677648294965133\ldots \]

Four numerical search outputs converging to the same canonical contact topology.

The drawings on the left contain numerical noise and different labellings. Once canonicalised and squeezed within the same topology, they collapse onto the arrangement at right.

That does not prove that this topology is globally important, and it does not make it a record. It does show that the arrangement is more than a one-off numerical accident. It occupies a basin which several searches can enter from slightly different directions.

The Tilt Angle

Let

\[ q=\sin\theta, \qquad c=\cos\theta. \]

Within this contact pattern, two different wall-to-wall networks constrain how narrow the container can become. Each network uses a collection of wall contacts and contacts between neighbouring squares. They produce the following lower bounds on the container width:

\[ A(\theta)=\frac{3+2q+3c}{q+c} \]

and

\[ B(\theta)= \frac{2c^2+2qc+3q^2+3c+2q}{1+qc}. \]

The diagram below shows the contacts used by the two certificates. The coloured lines are only a schematic way to identify the linked squares; they are not intended to show literal force directions or separating axes.

Two schematic contact certificates highlighted on the alternative packing.

Certificate \(A\) becomes the obstruction when the common angle is slightly too small. Certificate \(B\) becomes the obstruction when it is slightly too large.

For any chosen common angle in this family, the container must satisfy both bounds. Its required width is therefore

\[ W(\theta)=\max\bigl(A(\theta),B(\theta)\bigr). \]

Just below the best angle, \(A\) is larger. Just above it, \(B\) is larger. The smallest possible maximum occurs where the two obstructions balance:

\[ A(\theta)=B(\theta). \]

A graph of the two contact bounds crossing at the limiting common angle.

The thick line is the width demanded by the worse of the two contact constraints. Its minimum is at their intersection.

Using \(c^2+q^2=1\) to eliminate \(c\), the crossing condition reduces to

\[ 5q^5+5q^4+3q^3-3q^2-3q+1=0. \]

The relevant root is

\[ q=0.63785262957341214549\ldots, \]

which gives

\[ \theta=39.63188122755316212\ldots^\circ. \]

The container width can then be written as

\[ W=4+\frac{2}{q}-\frac{1}{q^2}, \]

and \(W\) itself is the relevant real root of

\[ W^5-11W^4+41W^3-37W^2-81W+19=0. \]

Numerically, that root is

\[ W=4.67764829496513302001\ldots \]

Files and Reproduction

The search and optimisation code is available in the Squarl repository. The rounded coordinates used to draw the figures in this post are included alongside this article.

Those rounded coordinates are intended for illustration, not as a rigorous non-overlap certificate.