Each of the $9$ squares in a ${3 \times 3}$ grid is to be colored red, blue, or yellow in such a way that each red square shares an edge with at least one blue square, each blue square shares an edge with at least one yellow square, and each yellow square shares an edge with at least one red square. Colorings that can be obtained from one another by rotations and/or reflections are considered the same. How many different colorings are possible?
一个$3 \times 3$网格的$9$个方格将被涂成红色、蓝色或黄色,使得每个红色方格与至少一个蓝色方格共享边,每个蓝色方格与至少一个黄色方格共享边,每个黄色方格与至少一个红色方格共享边。由旋转和/或反射得到的着色视为相同。可能的不同着色有多少种?
Denote $1=\text{red}$, $2=\text{blue}$, $3=\text{yellow}$. We need $1\to 2\to 3\to 1$.
WLOG place $1$ in the center $(0,0)$, $2$ on the left edge $(-1,0)$, $3$ on the top-left corner $(-1,1)$.
\[\begin{bmatrix} 3 & 0 & 0 \\ 2 & 1 & 0 \\ 0 & 0 & 0 \end{bmatrix}\]
$3$ must see $1$, so the top edge $(0,1)$ must also have $1$. Then, $1$ must see $2$, so the top-right corner $(1,1)$ becomes $2$, which must see $3$, so the right edge $(1,0)$ must have $3$.
\[\begin{bmatrix} 3 & 1 & 2 \\ 2 & 1 & 3 \\ 0 & 0 & 0 \end{bmatrix}\]
Now this bottom-right corner can vary either as $1$, $2$ or $3$.
Cases on $(1,-1)$:
If $1$:
\[\begin{bmatrix} 3 & 1 & 2 \\ 2 & 1 & 3 \\ 3 & 2 & 1 \end{bmatrix}\]
but the 3 needs a 1 and does not have it, so there are $0$ cases.
If $2$:
\[\begin{bmatrix} 3 & 1 & 2 \\ 2 & 1 & 3 \\ b & a & 2 \end{bmatrix}\]
if $a=1$, $b$ can be $1$ or $3$. If $a=2$, $b=3$, but the 3 needs a 1 and can't get it.
If $a=3$, $b=1,2$, so there are $4$ cases in total.
If $3$:
\[\begin{bmatrix} 3 & 1 & 2 \\ 2 & 1 & 3 \\ 2 & 1 & 3 \end{bmatrix}\]
Since the 2 in the bottom left corner does not have a 3 nearby, there are $0$ cases.
WLOG the center fixes a factor of $3$, so the answer is $4\cdot 3=\boxed{\textbf{(C) } 12}$.
记$1=\text{红}$,$2=\text{蓝}$,$3=\text{黄}$。需满足$1\to 2\to 3\to 1$。
不失一般性,将$1$置于中心$(0,0)$,$2$于左边$(-1,0)$,$3$于左上角$(-1,1)$。
\[\begin{bmatrix} 3 & 0 & 0 \\ 2 & 1 & 0 \\ 0 & 0 & 0 \end{bmatrix}\]
$3$必须邻接$1$,故上边$(0,1)$必须为$1$。则$1$必须邻接$2$,故右上角$(1,1)$为$2$,其必须邻接$3$,故右边$(1,0)$为$3$。
\[\begin{bmatrix} 3 & 1 & 2 \\ 2 & 1 & 3 \\ 0 & 0 & 0 \end{bmatrix}\]
现在右下角可为$1$、$2$或$3$。
对$(1,-1)$分类讨论:
若为$1$:
\[\begin{bmatrix} 3 & 1 & 2 \\ 2 & 1 & 3 \\ 3 & 2 & 1 \end{bmatrix}\]
但$3$无邻接$1$,故$0$种。
若为$2$:
\[\begin{bmatrix} 3 & 1 & 2 \\ 2 & 1 & 3 \\ b & a & 2 \end{bmatrix}\]
若$a=1$,$b$可为$1$或$3$;若$a=2$,$b=3$,但$3$无邻接$1$;若$a=3$,$b=1,2$,共$4$种。
若为$3$:
\[\begin{bmatrix} 3 & 1 & 2 \\ 2 & 1 & 3 \\ 2 & 1 & 3 \end{bmatrix}\]
左下角$2$无邻接$3$,故$0$种。
中心固定一种情况,对称有因子$3$,故答案$4\cdot 3=\boxed{\textbf{(C) } 12}$。