Conway's LUX method for magic squares is an
algorithm
In mathematics and computer science, an algorithm () is a finite sequence of Rigour#Mathematics, mathematically rigorous instructions, typically used to solve a class of specific Computational problem, problems or to perform a computation. Algo ...
by
John Horton Conway
John Horton Conway (26 December 1937 – 11 April 2020) was an English mathematician. He was active in the theory of finite groups, knot theory, number theory, combinatorial game theory and coding theory. He also made contributions to many b ...
for creating
magic square
In mathematics, especially History of mathematics, historical and recreational mathematics, a square array of numbers, usually positive integers, is called a magic square if the sums of the numbers in each row, each column, and both main diago ...
s of order 4''n''+2, where ''n'' is a
natural number
In mathematics, the natural numbers are the numbers 0, 1, 2, 3, and so on, possibly excluding 0. Some start counting with 0, defining the natural numbers as the non-negative integers , while others start with 1, defining them as the positive in ...
.
Method
Start by creating a (2''n''+1)-by-(2''n''+1) square array consisting of
* ''n''+1 rows of Ls,
* 1 row of Us, and
* ''n''-1 rows of Xs,
and then exchange the U in the middle with the L above it.
Each letter represents a 2x2 block of numbers in the finished square.
Now replace each letter by four consecutive numbers, starting with 1, 2, 3, 4 in the centre square of the top row, and moving from block to block in the manner of the
Siamese method: move up and right, wrapping around the edges, and move down whenever you are obstructed. Fill each 2x2 block according to the order prescribed by the letter:
:
Example
Let ''n'' = 2, so that the array is 5x5 and the final square is 10x10.
:
Start with the L in the middle of the top row, move to the 4th X in the bottom row, then to the U at the end of the 4th row, then the L at the beginning of the 3rd row, etc.
:
See also
*
Siamese method
*
Strachey method for magic squares
References
*{{citation, title=Aha! Solutions, series=MAA Spectrum, first=Martin, last=Erickson, publisher=
Mathematical Association of America
The Mathematical Association of America (MAA) is a professional society that focuses on mathematics accessible at the undergraduate level. Members include university
A university () is an educational institution, institution of tertiary edu ...
, year=2009, isbn=9780883858295, page=98, url=https://books.google.com/books?id=ywKyQz7_4-MC&pg=PA98.
Magic squares