Hostname: page-component-78c5997874-xbtfd Total loading time: 0 Render date: 2024-11-11T06:24:18.745Z Has data issue: false hasContentIssue false

Generating and enumerating magic squares

Published online by Cambridge University Press:  01 August 2016

Patrick Fitzpatrick*
Affiliation:
Department of Mathematics, University College, Cork, Ireland

Extract

Magic squares have long provided a fruitful source of classroom examples and stimulating exercises in recreational mathematics. Attention is often devoted to the so-called normal magic squares of a given order n in which the entries are the integers from 1 to n2. In these the size must be at least 4 for examples to be sufficiently plentiful: there is essentially only one normal magic square of order 3 (apart from rotations and reflections), while there are 880 of order 4 and several millions of order 5. However, if we drop the requirement of normality, the 3 × 3 square becomes a surprisingly rich subject for investigation, which can challenge pupils at all levels. In this note we discuss the following problems: (1) find a formula to generate all 3 × 3 magic squares with a given magic number m (the sum of entries in any row, column or diagonal), with no restriction on the entries—they can be any real numbers; (2) find conditions under which the square has all entries positive integers; (3) determine how many essentially distinct positive integer squares there are for a given m.

Type
Research Article
Copyright
Copyright © Mathematical Association 1985

Access options

Get access to the full version of this content by using one of the access options below. (Log in options will check for institutional or personal access. Content may require purchase if you do not have access.)