\section{The mirror rule}\label{sec:rules} For the mirror rule, condition (A) is a condition on the divisors of $m$, cross intercalates come from coincidences of the values $\mu(c) = x_c + \beta(c)$, and generation is a condition on differences of shifts. \subsection{Orbits, cross intercalates and the values of \texorpdfstring{$\mu$}{mu}} \begin{lemma}\label{lem:orbit} If every proper divisor of $m$ is at most $s$ and at most $m - s$, then every orbit of a nonzero translation of $\Z_m$ meets both parts of the split $s$. \end{lemma} \begin{proof} Let $d \ne 0$ and $g = \gcd(d, m)$, a proper divisor of $m$. By B\'ezout's identity the orbit of $x$ contains $x + jg$ for every $j$, so it contains every residue congruent to $x$ modulo $g$. An interval of at least $g$ consecutive residues contains such a residue, and both parts are such intervals. \end{proof} Conversely, a part with fewer than $g$ residues misses a coset of $g\Z_m$. Hence (A) holds exactly when the largest proper divisor of $m$ is at most both parts of both splits. For $m = 2w$ this forces both splits to be $w$; for $m = 2u + 1$ the splits $u$ satisfy (A), since every proper divisor of $2u + 1$ is at most $(2u + 1)/3 \le u$. \begin{lemma}\label{lem:cross} Let $(r, c), (r', c'), (r, c'), (r', c)$ be the cells of a cross intercalate, with $(r, c)$ and $(r', c')$ of class $i$ and the other two of class $j \ne i$. If $0 \in \{i, j\}$, then $\mu(c) = \mu(c')$; otherwise $2(\beta(c) - \beta(c')) = 0$. If $k$ is odd, then $c$ and $c'$ lie in different parts, exactly one of $r$, $r'$ is upper, and if $c$ is the lower column, then $2(h_c - h_{c'}) = 1$ in $\Z_k$. If $k$ and $m$ are both odd, then $0 \in \{i, j\}$. \end{lemma} \begin{proof} The equalities of symbols read $x_r + \beta_i(c) = x_{r'} + \beta_i(c')$ and $x_r + \beta_j(c') = x_{r'} + \beta_j(c)$; subtracting gives the first two statements. By \eqref{eq:class} the two cells in the row $r$ give $i - j = h_c - h_{c'} - \varepsilon(r, c) + \varepsilon(r, c')$, and the two cells in the row $r'$ give $j - i = h_c - h_{c'} - \varepsilon(r', c) + \varepsilon(r', c')$. Subtracting and adding these equations gives \begin{align*} 2(i - j) &= \varepsilon(r, c') - \varepsilon(r, c) + \varepsilon(r', c) - \varepsilon(r', c'), \\ 2(h_c - h_{c'}) &= \varepsilon(r, c) - \varepsilon(r, c') + \varepsilon(r', c) - \varepsilon(r', c'). \end{align*} If $c$ and $c'$ lie in the same part, the right side of the first equation is $0$, which is impossible for odd $k$ as $i \ne j$. If $c$ is lower and $c'$ upper, then $\varepsilon(r, c') = \varepsilon(r', c') = 0$; the first equation gives $\varepsilon(r', c) \ne \varepsilon(r, c)$, so exactly one of $r, r'$ is upper, and the second gives $2(h_c - h_{c'}) = \varepsilon(r, c) + \varepsilon(r', c) = 1$. If $k$ and $m$ are odd and $i, j \ne 0$, then $\beta(c) = \beta(c')$ as $2$ is invertible modulo $m$, which is impossible for columns in different parts. \end{proof} For even $m$ the last statement fails, and for odd $k \ge 3$ this always gives a cross intercalate. \begin{proposition}\label{prop:evenm} Let $k \ge 3$ be odd and $m$ even. For every column map $\beta$ and all splits, $K$ has a cross intercalate. \end{proposition} \begin{proof} Since $\beta$ maps every sector onto its part, there are a lower column $c$ and an upper column $c'$ with $\beta(c') = \beta(c) + m/2$, and their blocks can be chosen with $2(h_c - h_{c'}) = 1$, as $2$ is invertible modulo $k$. Take an upper row $r$ and a lower row $r'$ with $x_r - x_{r'} = m/2$. Then $x_r + \beta(c) = x_{r'} + \beta(c')$ and $x_r + \beta(c') = x_{r'} + \beta(c)$, because $2 \cdot m/2 = 0$. Choose the blocks of $r$ and $r'$ such that $(r, c)$ and $(r', c')$ have the same class $i$. By \eqref{eq:class} the cells $(r, c')$ and $(r', c)$ then have the classes $i + h_{c'} - h_c + 1$ and $i + h_c - h_{c'}$, which agree because $2(h_c - h_{c'}) = 1$, and differ from $i$ because $h_c - h_{c'} \not\equiv 0$. As $k \ge 3$, $i$ can be chosen so that both classes are nonzero. These four cells form a cross intercalate. \end{proof} In particular, for odd prime $k$ the standard field needs odd $m$; this is why the square of order $12$ in the appendix uses another class field (Section~\ref{sec:rem}). From now on $\beta$ is the mirror rule. Its values of $\mu$ are easy to compute. \begin{lemma}\label{lem:mu} Let $c$ be the column at position $p$ of the sector $(g, b)$, whose shift is $t = t(g, b)$. If $c$ is lower, then $\mu(c) = t$ for $p \le t$ and $\mu(c) = t + s_c$ for $p > t$. If $c$ is upper, then $\mu(c) = 2 s_c + t$ for $p \le t$ and $\mu(c) = s_c + t$ for $p > t$, modulo $m$. In particular, on each sector $\mu$ takes at most two values, which differ by $s_c$ and are congruent to the shift modulo every common divisor of $m$ and $s_c$; the second value occurs exactly when $t < z_b - 1$. \end{lemma} \begin{proof} A lower column has $x_c = p$ and $\beta(c) = (t - p) \bmod s_c$, which is $t - p$ for $p \le t$ and $t - p + s_c$ otherwise. An upper column has $x_c = s_c + p$ and $\beta(c) = s_c + ((t - p) \bmod (m - s_c))$, which is $s_c + t - p$ for $p \le t$ and $m + t - p$ otherwise. Adding $x_c$ gives the values. \end{proof} For the sector $(g, b)$ let $M(g, b)$ be the set of these values. \subsection{Three rules} For a column part $P$, the successors of Corollary~\ref{cor:gen} are easy to describe for the mirror rule. \begin{lemma}\label{lem:mirror} The mirror rule with shifts $t$ satisfies (B) if for each part $b$ there is a block $g$ with $t(g + 1, b) + 1 \equiv t(g, b) \pmod{z_b}$. \end{lemma} \begin{proof} Let $(g, x)$ be at position $p$ in its sector. The column $(g + 1, y)$ at position $p - 1$ has $\beta$-value at position $t(g + 1, b) - (p - 1) \equiv t(g, b) - p \pmod{z_b}$, which is the position of $\beta(g, x)$. Hence the residue at position $p - 1$ is a successor of the residue at position $p$, and a nonempty set that contains the successors of its elements contains every residue of the part. \end{proof} \begin{proposition}\label{prop:rules} The squares given by the first three rows of Table~\ref{tab:params} have no proper subsquare. \end{proposition} \begin{proof} Condition (A) holds by the remark after Lemma~\ref{lem:orbit}, and both column parts have at least two elements. In all three rules Lemma~\ref{lem:mirror} applies: for $k = 2$ with $g = 1$, and for odd $k$ with $g = 0$ in the lower part and $g = (k - 1)/2$ in the upper part. By Corollary~\ref{cor:gen} it remains to exclude cross intercalates, and by Lemma~\ref{lem:cross} such an intercalate needs $\mu(c) = \mu(c')$ for two columns in different sectors, which for odd $k$ lie in the sectors $(g, 0)$ and $(g + (k - 1)/2, 1)$. The values of $\mu$ come from Lemma~\ref{lem:mu}. For $m = 2w$ with shifts $(0, 1)$ and $(2, 3)$, $\mu$ is congruent modulo $w$ to the shift of the sector of the column, and the four shifts are different modulo $w$ as $w \ge 4$. For $m = 2u + 1$ with shifts $(0, 1)$ and $(3, 4)$ the sets $M(g, b)$ are contained in $\{0, u\}$, $\{1, u + 1\}$, $\{2, u + 3\}$ and $\{3, u + 4\}$, which are disjoint for $u \ge 4$. For odd prime $k$ and $h_{c'} = h_c + (k - 1)/2$, the column $c$ lies in the block $0$ exactly when $c'$ lies in the block $(k - 1)/2$. In that case the values of $\mu$ are $1$ or $u + 1$ on $c$ and $2$ or $u + 3$ on $c'$ (for $u = 2$: $4$ or $2$); otherwise they are $0$ or $u$ on $c$ and $1$ or $u + 2$ on $c'$. In both cases they differ. \end{proof} \subsection{All shifts} Generation gives sufficient conditions cheaply; the following theorem gives the exact ones, for arbitrary splits. Let $c$, $c'$ be columns in different sectors with $\mu(c) = \mu(c')$. For $k = 2$, call them a \emph{realisable collision} if they lie in the same column part, or if $c$ is lower, $c'$ is upper, and $x_{c'} - x_c$ is the difference of two residues of the row part $a = 1 + h_{c'} - h_c$ (with $0$ for lower and $1$ for upper). For odd $k$, call them a realisable collision if $c$ is lower, $c'$ is upper and $h_{c'} = h_c + (k - 1)/2$. \begin{theorem}\label{thm:mirror} Let $k$ be prime, let $\beta$ be the mirror rule, assume (A), and if $k$ is odd let $m$ be odd. Then $K$ has no proper subsquare if and only if \begin{enumerate}[label=\textup{(\arabic*)}] \item in no part are all $k$ shifts equal; \item there is no divisor $e > 1$ of $\gcd(m, s_c)$ such that all $2k$ shifts are congruent modulo $e$; \item there is no realisable collision. \end{enumerate} \end{theorem} \begin{proof} By Theorem~\ref{thm:U} it suffices to show that (a), (b) and (c) of Theorem~\ref{thm:U} together are equivalent to (1), (2) and (3). Two columns at the same position of a part in different blocks have the same value of $\beta$ exactly when their shifts agree, so (b) is equivalent to (1). \emph{Condition (a).} By Lemma~\ref{lem:cross} a cross intercalate has class $0$ in two opposite cells, say $(r, c)$ and $(r', c')$, and the equalities of symbols say $\mu(c) = \mu(c')$ and $x_r - x_{r'} = x_{c'} - x_c$. For $k = 2$, the class equations \eqref{eq:class} put $r$ and $r'$ into the part $a$ of the definition if $c$ is lower and $c'$ upper. If $c$ and $c'$ lie in the same column part, the class equations do not restrict the parts of $r$ and $r'$, and every difference is realised: $0$ by two rows of one part, and every nonzero difference by an upper and a lower row. For odd $k$, Lemma~\ref{lem:cross} gives the sectors of $c$ and $c'$ and puts $r$ and $r'$ into different parts; residues of different parts realise every nonzero difference, and $x_{c'} - x_c \ne 0$. Conversely, in each case the blocks of $r$ and $r'$ can be chosen to satisfy the class equations, so a realisable collision gives a cross intercalate. Hence (a) is equivalent to (3). \emph{Condition (c).} Let $H = e\Z_m$ with $1 < e < m$ and $e \mid m$. If $e$ divides $s_c$, then by Lemma~\ref{lem:mu} $\beta(c) \equiv t - x_c \pmod e$ for every column $c$ in a sector with shift $t$; hence a coset of $H$ is mapped into one coset of $H$ exactly when all shifts are congruent modulo $e$, and then $x = 0$ works. This gives the equivalence of (2) with (c) for these $H$. If $e$ does not divide $s_c$, let $\rho = s_c \bmod e \ne 0$ and suppose that $\beta$ maps $x + H$ into $z + H$ in all blocks. By (A) both parts have at least $e$ residues, so every sector contains columns of $x + H$. Let $p_0 < e$ and $q_0 < e$ be the first positions of $x + H$ in the lower and in the upper part; then $q_0 \equiv p_0 - \rho \pmod e$. The values of $\mu$ on the columns of $x + H$ are congruent modulo $e$, and as the two values of $\mu$ in a sector differ by $s_c \notin H$, the columns of $x + H$ in a sector lie all up to the shift or all beyond it, which I call the type of the sector. In the first case the shift is at least the last position $L$ of $x + H$ in the part, and $L \ge z_b - e$; by Lemma~\ref{lem:mu} the value of $\mu$ then lies in $[s_c - e, s_c - 1]$ modulo $m$. In the second case the shift is less than $p_0$ or $q_0$, and the value lies in $[s_c, s_c + e - 2]$. Each of these two intervals contains at most one residue of a given class modulo $e$, so the value, and with it the shift, of a sector is determined by its part and its type. Suppose that both types occur in the lower part, with shifts $t_1 \in [L, s_c - 1]$ and $t_2 \le p_0 - 1$, where $t_1 \equiv t_2 + s_c \pmod e$. Since $L - s_c \in [-e, -1]$ and $L \equiv p_0 \pmod e$, the residue of $t_1 - s_c$ modulo $e$ lies in $[(p_0 - \rho) \bmod e, e - 1]$, so $(p_0 - \rho) \bmod e \le t_2 \le p_0 - 1$, which forces $p_0 \ge \rho$. In the same way, both types in the upper part give shifts $t_1 \in [L, m - s_c - 1]$ and $t_2 \le q_0 - 1$ with $t_2 \equiv t_1 + s_c \pmod e$, so $(q_0 + \rho) \bmod e \le q_0 - 1$, which forces $q_0 \ge e - \rho$. Both cannot hold, since $p_0 \ge \rho$ gives $q_0 = p_0 - \rho < e - \rho$. Hence in one part all sectors have the same type and the same shift, contrary to (1). Thus, given (1), (c) is equivalent to (2). \end{proof} By the remark after Lemma~\ref{lem:orbit}, for $k = 2$ and even $m$ condition (A) leaves only the splits $m/2$, and the theorem takes the following form. \begin{corollary}\label{prop:classify} Let $k = 2$, $m = 2w$ with $w \ge 3$, and let both splits be $w$. The square $K$ has no proper subsquare if and only if \begin{enumerate}[label=\textup{(\roman*)}] \item the four shifts $t(0, 0)$, $t(1, 0)$, $t(0, 1)$, $t(1, 1)$ are pairwise different, and \item the differences of the four shifts generate $\Z_w$. \end{enumerate} \end{corollary} The shifts $(0, 1)$ and $(2, 3)$ of Table~\ref{tab:params} satisfy both conditions for $w \ge 4$. For $w = 3$ condition (i) cannot hold, and for $w = 2$ no square of Definition~\ref{def:family} is free (Section~\ref{sec:rem}); thus the bound $w \ge 4$ cannot be lowered. Counting the shifts with (i) and (ii) by inclusion and exclusion over the subgroups of $\Z_w$ gives \[ \sum_{d \mid w} \nu(d)\, d \, \frac{w}{d} \Bigl(\frac{w}{d} - 1\Bigr) \Bigl(\frac{w}{d} - 2\Bigr) \Bigl(\frac{w}{d} - 3\Bigr) \] choices, where $\nu$ is the M\"obius function. For $w = 2^a$ this is $\frac78 w^4 - \frac92 w^3 + \frac{11}{2} w^2$, so the proportion of good choices tends to $7/8$ as $a$ grows; for $w = 16$ it is about $62$ percent. Figure~\ref{fig:shifts} shows how small the visible difference between a square with and a square without proper subsquares is. \begin{proof} As $\gcd(2w, w) = w$, condition (2) of Theorem~\ref{thm:mirror} is (ii). By Lemma~\ref{lem:mu}, $\mu(c)$ is congruent modulo $w$ to the shift of the sector of $c$. Hence, if the shifts are pairwise different, no two columns of different sectors have the same value of $\mu$, and (1) and (3) hold. Conversely, two equal shifts in one part violate (1). If $t(g, 0) = t(g', 1) = t$, choose positions $p' < p$ on the same side of $t$ ($p' = 0$, $p = 1$ if $t \ge 1$, and $p' = w - 2$, $p = w - 1$ if $t = 0$, using $w \ge 3$), let $c$ be the lower column of the block $g$ at position $p$ and $c'$ the upper column of the block $g'$ at position $p'$. Then $\mu(c) = \mu(c')$, and $x_{c'} - x_c = w + p' - p$ lies strictly between $0$ and $w$, so it is the difference of two residues of either row part: a realisable collision. \end{proof} For odd $m = 2u + 1$ and both splits $u$, a lower sector has $u$ and an upper sector $u + 1$ columns, and by Lemma~\ref{lem:mu}, read modulo $m$ with $2u \equiv -1$, \begin{align*} M(g, 0) &= \{t(g, 0)\} \cup \{t(g, 0) + u : t(g, 0) \le u - 2\}, \\ M(g, 1) &= \{t(g, 1) - 1\} \cup \{t(g, 1) + u : t(g, 1) \le u - 1\}. \end{align*} \begin{corollary}\label{prop:classify-odd} Let $m = 2u + 1$ with $u \ge 2$, let both splits be $u$, and let $\beta$ be the mirror rule. \begin{enumerate}[label=\textup{(\roman*)}] \item For $k = 2$, the square $K$ has no proper subsquare if and only if any two of the four sets $M(g, b)$ are disjoint, with two exceptions: $M(g, 0)$ and $M(g + 1, 1)$ may share the value $0$ if $t(g, 0) = 0$ and $t(g + 1, 1) = 1$, and the value $2u - 2$ if $t(g, 0) = t(g + 1, 1) = u - 2$. \item For an odd prime $k$, the square $K$ has no proper subsquare if and only if in each part the $k$ shifts are not all equal and $M(g, 0) \cap M(g + (k - 1)/2, 1) = \emptyset$ for every block $g$. \end{enumerate} \end{corollary} \begin{proof} As $\gcd(2u + 1, u) = 1$, condition (2) of Theorem~\ref{thm:mirror} is empty. For odd $k$, every collision between $M(g, 0)$ and $M(g + (k - 1)/2, 1)$ is realisable, which gives (ii). For $k = 2$, equal shifts in one part give equal sets $M$, so (1) follows from (3). Collisions of two sectors in the same column part are realisable by definition, and those of the two sectors of one block too, since the rows are then upper and the $u + 1$ upper residues realise every difference modulo $2u + 1$. For the lower sector of the block $g$ and the upper sector of the block $g + 1$ the rows must be lower, and the $u$ lower residues realise every difference except $\pm u$. For columns at the positions $p$ and $p'$ the difference is $u + p' - p$, so the collision fails to be realisable exactly when $p' - p \in \{0, 1\}$ for all positions carrying the common value of $\mu$. By Lemma~\ref{lem:mu} this happens exactly in the two exceptional cases. \end{proof} \input{sections/fig-shifts} The three rules of Table~\ref{tab:params} satisfy the conditions of these corollaries. Independently of the proofs, I checked Theorem~\ref{thm:mirror} and Proposition~\ref{prop:evenm} by computer against the exact criterion of Theorem~\ref{thm:U}, for all splits satisfying (A) and all shifts, for $k = 2$ and $m \le 21$ and for $k = 3$ and $m \le 9$, and on random samples for $m \le 33$; Corollary~\ref{prop:classify-odd} was also checked against a direct closure test of all shift vectors, for $k = 2$ and $u \le 9$, for $k = 3$ and $u \le 7$, and for $k = 5$ and $u \le 3$.