ArticleslgStudy

mathematics

Magic square

Magic square is a mathematics topic covered in the lgStudy science library. This page brings together a partial reference excerpt, illustrations, worked examples, real-world applications and a short study plan, so you can understand Magic square rather than just read about it. In short: In mathematics, especially historical and recreational mathematics, a magic square is a square array of numbers, usually positive integers, where the sums of the numbers in each row, each column, and both main diagonals are the same. The order of a magic square is the number of integers along one side (n), and the constant sum is called the magic constant or magic sum.

Magic square — main illustration
Magic square — illustration

Key takeaways

  • Magic square belongs to mathematics; place it in that map before memorising details.
  • Learn the definition first, then one example that makes the definition concrete.
  • Connect Magic square to a quantity you can measure, compute or draw — that is where exam questions come from.
  • Reproduce the core statement of Magic square from memory before moving on to harder problems.

Reference excerpt

In mathematics, especially historical and recreational mathematics, a magic square is a square array of numbers, usually positive integers, where the sums of the numbers in each row, each column, and both main diagonals are the same. The order of a magic square is the number of integers along one side (n), and the constant sum is called the magic constant or magic sum. If the array includes just the positive integers 1,2,...,n2, the magic square is said to be normal. Many authors take magic square to mean normal magic square. Magic squares that include repeated entries do not fall under this definition and are referred to as trivial. Some well-known examples, including the Sagrada Família magic square are trivial in this sense. When all the rows and columns but not both diagonals sum to the magic constant, this gives a semimagic square (sometimes called orthomagic square). The mathematical study of magic squares typically deals with its construction, classification, and enumeration. Although completely general methods for producing all the magic squares of all orders do not exist, historically three general techniques have been discovered: by bordering, by making composite magic squares, and by adding two preliminary squares. There are also more specific strategies like the continuous enumeration method that reproduces specific patterns. Magic squares are generally classified according to their order n as: odd if n is odd, evenly even (also referred to as "doubly even") if n is a multiple of 4, oddly even (also known as "singly even") if n is any other even number. This classification is based on different techniques required to construct odd, evenly even, and oddly even squares. Beside this, depending on further properties, magic squares are also classified as associative magic squares, pandiagonal magic squares, most-perfect magic squares, and so on. More challengingly, attempts have also been made to classify all the magic squares of a given order as transformations of a smaller set of squares. Except for n ≤ 5, the enumeration of higher-order magic squares is still an open challenge. The enumeration of most-perfect magic squares of any order was only accomplished in the late 20th century. Magic squares have a long history, dating back to at least 190 BCE in China. At various times they have acquired occult or mythical significance, and have appeared as symbols in works of art. In modern times they have been generalized a number of ways, including using extra or different constraints, multiplying instead of adding cells, using alternate shapes or more than two dimensions, and replacing numbers with shapes and addition with geometric operations.

History

The third-order magic square was known to Chinese mathematicians as early as 190 BCE, and explicitly given by the first century of the common era. The first dateable instance of the fourth-order magic square occurred in 550 CE in India. Specimens of magic squares of order 3 to 9 appear in an encyclopedia from Baghdad c. 983, the Encyclopedia of the Brethren of Purity (Rasa'il Ikhwan al-Safa). By the end of the 12th century, the general methods for constructing magic squares were well established. Around this time, some of these squares were increasingly used in conjunction with magic letters, as in Shams Al-ma'arif, for occult purposes. In India, all the fourth-order pandiagonal magic squares were enumerated by Narayana in 1356. Magic squares were made known to Europe through translation of Arabic sources as occult objects during the Renaissance, and the general theory had to be re-discovered independent of prior developments in China, India, and Middle East. Also notable are the ancient cultures with a tradition of mathematics and numerology that did not discover the magic squares: Greeks, Babylonians, Egyptians, and Pre-Columbian Americans. Magic squares also appear in art. For example, a magic square appears in Albrecht Dürer's Melencolia (see the photograph of the work). Another one appears in Wilfredo Lam's Bélial, Emperor of the Flies, a magic square is seen in the lower left quadrant of the painting.

China

While ancient references to the pattern of even and odd numbers in the 3×3 magic square appear in the I Ching, the first unequivocal instance of this magic square appears in the chapter called Mingtang (Bright Hall) of a 1st-century book Da Dai Liji (Record of Rites by the Elder Dai), which purported to describe ancient Chinese rites of the Zhou dynasty. These numbers also occur in a possibly earlier mathematical text called Shushu jiyi (Memoir on Some Traditions of Mathematical Art), said to be written in 190 BCE. This is the earliest appearance of a magic square on record; and it was mainly used for divination and astrology. The 3×3 magic square was referred to as the "Nine Halls" by earlier Chinese mathematicians. The identification of the 3×3 magic square to the legendary Luoshu chart was only made in the 12th century, after which it was referred to as the Luoshu square. The oldest surviving Chinese treatise that displays magic squares of order larger than 3 is Yang Hui's Xugu zheqi suanfa (Continuation of Ancient Mathematical Methods for Elucidating the Strange) written in 1275. The contents of Yang Hui's treatise were collected from older works, both native and foreign; and he only explains the construction of third and fourth-order magic squares, while merely passing on the finished diagrams of larger squares. He gives a magic square of order 3, two squares for each order of 4 to 8, one of order nine, and one semi-magic square of order 10. He also gives six magic circles of varying complexity.

… excerpt ends here. Continue reading the full article.

Illustrations

Magic square: The smallest (and unique up to rotation and reflection) non-trivial case of a magic square, order 3, magic sum 15
The smallest (and unique up to rotation and reflection) non-trivial case of a magic square, order 3, magic sum 15
Magic square: Melencolia I (Albrecht Dürer, 1514) includes an order 4 square with magic sum 34
Melencolia I (Albrecht Dürer, 1514) includes an order 4 square with magic sum 34
Magic square: An order 4 magic square, detail from Melencolia I.
An order 4 magic square, detail from Melencolia I.
Magic square: Iron plate with an order-6 magic square in Eastern Arabic numerals from China, dating to the Yuan Dynasty (1271–1368).
Iron plate with an order-6 magic square in Eastern Arabic numerals from China, dating to the Yuan Dynasty (1271–1368).
Magic square: A page displaying 9×9 magic square from Cheng Dawei's Suanfa tongzong (1593).
A page displaying 9×9 magic square from Cheng Dawei's Suanfa tongzong (1593).

Worked examples

Example 1 — a first encounter with Magic square

Start with the simplest possible case. Write down what Magic square claims or describes in one sentence, then invent the smallest concrete situation in which that sentence is true. In mathematics, the smallest case is usually a single object, a single equation or a single measurement. Check that every symbol or term in your sentence has a meaning in that case.

Example 2 — changing one variable

Take the situation from Example 1 and change exactly one quantity: double it, halve it, or set it to zero. Predict what should happen to Magic square before you calculate. Comparing your prediction with the result is the fastest way to find out whether you understand the idea or only the words.

Example 3 — an exam-style question

Typical questions about Magic square ask you to (a) state it precisely, (b) apply it to given data, and (c) explain a limitation. Practise writing all three answers in under five minutes; the third part is what separates a full-mark answer from an average one.

Applications of Magic square

In research
Magic square appears in mathematics research whenever the underlying quantities have to be modelled precisely. Papers usually cite it as a starting assumption and then explore where it breaks down.
In technology and industry
Engineering practice reuses Magic square in design rules, simulations and safety margins. Knowing the idea lets you read a specification sheet and understand why the numbers look the way they do.
In the classroom
Magic square is common in secondary-school and first-year university syllabi. It links to neighbouring topics Chinese mathematical discoveries, Magic squares, Magic symbols, so understanding it makes those chapters shorter.
In everyday life
Look for Magic square outside the textbook — in sport, cooking, traffic, electronics or the sky above you. An example you found yourself is remembered far longer than one you were given.
Ask Teacher Smith questions about this articleOpens your AI tutor with a question about “Magic square” →

How to study Magic square in 20 minutes

  1. Read the reference excerpt below once, without taking notes.
  2. Close the page and write down what Magic square means in your own words.
  3. Compare your version with the excerpt and mark what you missed.
  4. Work through the three examples above with pen and paper.
  5. Explain Magic square out loud to somebody else — or to Teacher Smith in the lgStudy chat.

Frequently asked questions

What is Magic square in simple terms?

In mathematics, especially historical and recreational mathematics, a magic square is a square array of numbers, usually positive integers, where the sums of the numbers in each row, each column, and both main diagonals are the same. The order of a magic square is the number of integers along one s…

Why does Magic square matter?

Because it connects several mathematics ideas at once: it gives you a definition you can apply, a quantity you can calculate, and a way to check whether a result is plausible.

How should I study Magic square?

Read the excerpt, restate it from memory, then work through the examples and applications listed on this page. The five-step study plan above takes about twenty minutes.

What does this page cover?

It gives you a compact reference excerpt plus original lgStudy explanations, examples, applications and study material on Magic square.

Tags

  • Chinese mathematical discoveries
  • Magic squares
  • Magic symbols
  • Matrices (mathematics)
  • Unsolved problems in mathematics

Keep exploring