Solution
We need to determine the minimum number of different numerals required to fill a matrix such that no two horizontally, vertically, or diagonally adjacent cells contain the same numeral.
Consider the grid:
Observe any submatrix, for example,
Each pair of cells in this block is adjacent (either horizontally, vertically, or diagonally). Hence, all four cells in any block must contain different numerals.
Therefore, at least 4 different numerals are necessary.
Consider the following arrangement using four numerals:
Verification:
- No two horizontally adjacent cells contain the same numeral.
- No two vertically adjacent cells contain the same numeral.
- No two diagonally adjacent cells contain the same numeral.
Although the numerals , , and are repeated, identical numerals are always separated by at least one cell and therefore are not adjacent.
Since 4 numerals are necessary and 4 numerals are sufficient, the minimum number of different numerals required is 4.