Open main menu
Home
Random
Recent changes
Special pages
Community portal
Preferences
About Wikipedia
Disclaimers
Incubator escapee wiki
Search
User menu
Talk
Dark mode
Contributions
Create account
Log in
Editing
Conway's LUX method for magic squares
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
{{Short description|Algorithm for creating magic squares}} '''Conway's LUX method for magic squares''' is an [[algorithm]] by [[John Horton Conway]] for creating [[magic square]]s of order 4''n''+2, where ''n'' is a [[natural number]]. ==Method== Start by creating a (2''n''+1)-by-(2''n''+1) square array consisting of * ''n''+1 rows of '''L'''s, * 1 row of '''U'''s, and * ''n''-1 rows of '''X'''s, 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: :<math>\mathrm{L}: \quad \begin{smallmatrix}4&&1\\&\swarrow&\\2&\rightarrow&3\end{smallmatrix} \qquad \mathrm{U}: \quad \begin{smallmatrix}1&&4\\\downarrow&&\uparrow\\2&\rightarrow&3\end{smallmatrix} \qquad \mathrm{X}:\quad \begin{smallmatrix}1&&4\\&\searrow\!\!\!\!\!\!\nearrow&\\3&&2\end{smallmatrix}</math> ==Example== Let ''n'' = 2, so that the array is 5x5 and the final square is 10x10. :{| class="wikitable" style="text-align: center" |L||L||L||L||L |- |L||L||L||L||L |- |L||L||U||L||L |- |U||U||L||U||U |- |X||X||X||X||X |} 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. :{| class="wikitable" style="text-align: center" | width="10%" | 68 | width="10%" | 65 | width="10%" | 96 | width="10%" | 93 | width="10%" | 4 | width="10%" | 1 | width="10%" | 32 | width="10%" | 29 | width="10%" | 60 | width="10%" | 57 |- | 66 || 67 || 94 || 95 || 2 || 3 || 30 || 31 || 58 || 59 |- | 92 || 89 || 20 || 17 || 28 || 25 || 56 || 53 || 64 || 61 |- | 90 || 91 || 18 || 19 || 26 || 27 || 54 || 55 || 62 || 63 |- | 16 || 13 || 24 || 21 || 49 || 52 || 80 || 77 || 88 || 85 |- | 14 || 15 || 22 || 23 || 50 || 51 || 78 || 79 || 86 || 87 |- | 37 || 40 || 45 || 48 || 76 || 73 || 81 || 84 || 9 || 12 |- | 38 || 39 || 46 || 47 || 74 || 75 || 82 || 83 || 10 || 11 |- | 41 || 44 || 69 || 72 || 97 ||100 || 5 || 8 || 33 || 36 |- | 43 || 42 || 71 || 70 || 99 || 98 || 7 || 6 || 35 || 34 |} ==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]]|year=2009|isbn=9780883858295|page=98|url=https://books.google.com/books?id=ywKyQz7_4-MC&pg=PA98}}. [[Category:Magic squares]]
Edit summary
(Briefly describe your changes)
By publishing changes, you agree to the
Terms of Use
, and you irrevocably agree to release your contribution under the
CC BY-SA 4.0 License
and the
GFDL
. You agree that a hyperlink or URL is sufficient attribution under the Creative Commons license.
Cancel
Editing help
(opens in new window)
Pages transcluded onto the current version of this page
(
help
)
:
Template:Citation
(
edit
)
Template:Short description
(
edit
)