Verification pending: this question is published for access while the chapter review is completed.
How many different magic squares can be made using the numbers 1 – 9?
Show solutionHide solution
A 3 × 3 magic square using the numbers 1 to 9 is an arrangement in which every row, every column and both diagonals have the same sum. The question asks how many different such squares can be made.
Step 1: Find the magic sum. The total of all nine numbers is
\[1+2+\cdots+9=\frac{9\times 10}{2}=45.\]
Since the three rows together use all nine numbers, each row must sum to
\[45\div 3=15.\]
So the magic sum is 15.
Step 2: The centre must be 5. Consider the four lines through the centre: the middle row, the middle column, and the two diagonals. Each has sum 15 and each contains the centre together with two other numbers. Adding these four lines gives
\[4\times 15=60.\]
In this total the centre is counted four times, and every other cell is counted once. Hence
\[4c+(45-c)=60,\]
where \(c\) is the centre entry. Thus \(3c=15\), so \(c=5\).
Step 3: The corner entries are even. A corner lies on a row, a column and a diagonal, so it belongs to three lines of sum 15. Checking the pairs that complete 15 with each possible corner value shows that only the even numbers 2, 4, 6, 8 can occupy corners; the odd numbers 1, 3, 7, 9 must occupy the edge-centres.
Step 4: Count the arrangements. Once the centre 5 is fixed, the four corner positions must receive 2, 4, 6, 8. Opposite corners must add to 10, so the pairs are \((2,8)\) and \((4,6)\).
- Choose which opposite pair of corners gets \((2,8)\): 2 ways.
- Place 2 and 8 in those two opposite corners: 2 ways.
- Place 4 and 6 in the remaining two opposite corners: 2 ways.
This gives \(2\times 2\times 2=8\) arrangements. The four edge-centres are then forced: each must be the number that makes its line sum to 15.
For example, with 2 in the top-left corner and 8 in the bottom-right, the square is
| 2 | 7 | 6 |
| 9 | 5 | 1 |
| 4 | 3 | 8 |
Every row, column and diagonal sums to 15.
Step 5: Are these all really different? The 8 arrangements are related by rotations and reflections of the same square. If rotations and reflections are counted as the same pattern, there is essentially one magic square. If every distinct placement in the grid is counted separately, there are 8.
Answer: Up to rotation and reflection there is 1 essentially different magic square; counting all distinct grid arrangements, there are 8.