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
Magic square
(section)
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!
===Narayana-De la Hire's method for even orders=== Narayana-De la Hire's method for odd square is the same as that of Euler's. However, for even squares, we drop the second requirement that each Greek and Latin letter appear only once in a given row or column. This allows us to take advantage of the fact that the sum of an arithmetic progression with an even number of terms is equal to the sum of two opposite symmetric terms multiplied by half the total number of terms. Thus, when constructing the Greek or Latin squares, * ''for even ordered squares, a letter can appear ''n''/2 times in a column but only once in a row, or vice versa.'' As a running example, if we take a 4×4 square, where the Greek and Latin terms have the values (''α'', ''β'', ''γ'', ''δ'') = (0, 4, 8, 12) and (''a'', ''b'', ''c'', ''d'') = (1, 2, 3, 4), respectively, then we have ''α'' + ''β'' + ''γ'' + ''δ'' = 2 (''α'' + ''δ'') = 2 (''β'' + ''γ''). Similarly, ''a'' + ''b'' + ''c'' + ''d'' = 2 (''a'' + ''d'') = 2 (''b'' + ''c''). This means that the complementary pair ''α'' and ''δ'' (or ''β'' and ''γ'') can appear twice in a column (or a row) and still give the desired magic sum. Thus, we can construct: * ''For even ordered squares, the Greek magic square is made by first placing the Greek alphabets along the main diagonal in some order. The skew diagonal is then filled in the same order or by picking the terms that are complementary to the terms in the main diagonal. Finally, the remaining cells are filled column wise. Given a column, we use the complementary terms in the diagonal cells intersected by that column, making sure that they appear only once in a given row but ''n''/2 times in the given column. The Latin square is obtained by flipping or rotating the Greek square and interchanging the corresponding alphabets. The final magic square is obtained by adding the Greek and Latin squares.'' In the example given below, the main diagonal (from top left to bottom right) is filled with sequence ordered as ''α'', ''β'', ''γ'', ''δ'', while the skew diagonal (from bottom left to top right) filled in the same order. The remaining cells are then filled column wise such that the complementary letters appears only once within a row, but twice within a column. In the first column, since ''α'' appears on the 1st and 4th row, the remaining cells are filled with its complementary term ''δ''. Similarly, the empty cells in the 2nd column are filled with ''γ''; in 3rd column ''β''; and 4th column ''α''. Each Greek letter appears only once along the rows, but twice along the columns. As such, the row sums are ''α'' + ''β'' + ''γ'' + ''δ'' while the column sums are either 2 (''α'' + ''δ'') or 2 (''β'' + ''γ''). Likewise for the Latin square, which is obtained by flipping the Greek square along the main diagonal and interchanging the corresponding letters. {{col-begin|width=auto;margin:0.5em auto}} {{col-break|valign=bottom}} {| class="wikitable" style="margin-left:auto;margin-right:auto;text-align:center;width:8em;height:8em;table-layout:fixed;" |- | α || || || δ |- | || β || γ || |- | || β || γ || |- | α || || || δ |} {{col-break|valign=bottom|gap=1em}} {| class="wikitable" style="margin-left:auto;margin-right:auto;text-align:center;width:8em;height:8em;table-layout:fixed;" |- | α || γ || β || δ |- | δ || β || γ || α |- | δ || β || γ || α |- | α || γ || β || δ |} {{col-break|valign=bottom|gap=1em}} {| class="wikitable" style="margin-left:auto;margin-right:auto;text-align:center;width:8em;height:8em;table-layout:fixed;" |- | a || d || d || a |- | c || b || b || c |- | b || c || c || b |- | d || a || a || d |} {{col-break|valign=bottom|gap=1em}} {| class="wikitable" style="margin-left:auto;margin-right:auto;text-align:center;width:8em;height:8em;table-layout:fixed;" |- | αa || γd || βd || δa |- | δc || βb || γb || αc |- | δb || βc || γc || αb |- | αd || γa || βa || δd |} {{col-break|valign=bottom|gap=1em}} {| class="wikitable" style="margin-left:auto;margin-right:auto;text-align:center;width:8em;height:8em;table-layout:fixed;" |- | style="background-color: silver;"|1 || 12 || 8 || style="background-color: silver;"|13 |- | 15 || style="background-color: silver;"|6 || style="background-color: silver;"|10 || 3 |- | 14 || style="background-color: silver;"|7 || style="background-color: silver;"|11 || 2 |- | style="background-color: silver;"|4 || 9 || 5 || style="background-color: silver;"|16 |} {{col-end}} The above example explains why the "criss-cross" method for doubly even magic square works. Another possible 4×4 magic square, which is also pan-diagonal as well as most-perfect, is constructed below using the same rule. However, the diagonal sequence is chosen such that all four letters ''α'', ''β'', ''γ'', ''δ'' appear inside the central 2×2 sub-square. Remaining cells are filled column wise such that each letter appears only once within a row. In the 1st column, the empty cells need to be filled with one of the letters selected from the complementary pair ''α'' and ''δ''. Given the 1st column, the entry in the 2nd row can only be ''δ'' since ''α'' is already there in the 2nd row; while, in the 3rd row the entry can only be ''α'' since ''δ'' is already present in the 3rd row. We proceed similarly until all cells are filled. The Latin square given below has been obtained by flipping the Greek square along the main diagonal and replacing the Greek alphabets with corresponding Latin alphabets. {{col-begin|width=auto;margin:0.5em auto}} {{col-break|valign=bottom}} {| class="wikitable" style="margin-left:auto;margin-right:auto;text-align:center;width:8em;height:8em;table-layout:fixed;" |- | α || || || γ |- | || γ || α || |- | || β || δ || |- | δ || || || β |} {{col-break|valign=bottom|gap=1em}} {| class="wikitable" style="margin-left:auto;margin-right:auto;text-align:center;width:8em;height:8em;table-layout:fixed;" |- | α || β || δ || γ |- | δ || γ || α || β |- | α || β || δ || γ |- | δ || γ || α || β |} {{col-break|valign=bottom|gap=1em}} {| class="wikitable" style="margin-left:auto;margin-right:auto;text-align:center;width:8em;height:8em;table-layout:fixed;" |- | a || d || a || d |- | b || c || b || c |- | d || a || d || a |- | c || b || c || b |} {{col-break|valign=bottom|gap=1em}} {| class="wikitable" style="margin-left:auto;margin-right:auto;text-align:center;width:8em;height:8em;table-layout:fixed;" |- | αa || βd || δa || γd |- | δb || γc || αb || βc |- | αd || βa || δd || γa |- | δc || γb || αc || βb |} {{col-break|valign=bottom|gap=1em}} {| class="wikitable" style="margin-left:auto;margin-right:auto;text-align:center;width:8em;height:8em;table-layout:fixed;" |- | 1 || 8 || 13 || 12 |- | 14 || 11 || 2 || 7 |- | 4 || 5 || 16 || 9 |- | 15 || 10 || 3 || 6 |} {{col-end}} We can use this approach to construct singly even magic squares as well. However, we have to be more careful in this case since the criteria of pairing the Greek and Latin alphabets uniquely is not automatically satisfied. Violation of this condition leads to some missing numbers in the final square, while duplicating others. Thus, here is an important proviso: * ''For singly even squares, in the Greek square, check the cells of the columns which is vertically paired to its complement. In such a case, the corresponding cell of the Latin square must contain the same letter as its horizontally paired cell.'' Below is a construction of a 6×6 magic square, where the numbers are directly given, rather than the alphabets. The second square is constructed by flipping the first square along the main diagonal. Here in the first column of the root square the 3rd cell is paired with its complement in the 4th cells. Thus, in the primary square, the numbers in the 1st and 6th cell of the 3rd row are same. Likewise, with other columns and rows. In this example the flipped version of the root square satisfies this proviso. {{col-begin|width=auto;margin:0.5em auto}} {{col-break|valign=bottom}} {| class="wikitable" style="margin-left:auto;margin-right:auto;text-align:center;width:12em;height:12em;table-layout:fixed;" |- | 0 || '''24''' || 18 || 12 || '''6''' || 30 |- | 30 || 6 || '''12''' || '''18''' || 24 || 0 |- | '''0''' || 24 || 12 || 18 || 6 || '''30''' |- | '''30''' || 24 || 12 || 18 || 6 || '''0''' |- | 30 || 6 || '''18''' || '''12''' || 24 || 0 |- | 0 || '''6''' || 18 || 12 || '''24''' || 30 |} {{col-break|valign=bottom|gap=1em}} {| class="wikitable" style="margin-left:auto;margin-right:auto;text-align:center;width:12em;height:12em;table-layout:fixed;" |- | 1 || '''6''' || 1 || 6 || '''6''' || 1 |- | 5 || 2 || '''5''' || '''5''' || 2 || 2 |- | '''4''' || 3 || 3 || 3 || 4 || '''4''' |- | '''3''' || 4 || 4 || 4 || 3 || '''3''' |- | 2 || 5 || '''2''' || '''2''' || 5 || 5 |- | 6 || '''1''' || 6 || 1 || '''1''' || 6 |} {{col-break|valign=bottom|gap=1em}} {| class="wikitable" style="margin-left:auto;margin-right:auto;text-align:center;width:12em;height:12em;table-layout:fixed;" |- | 1 || 30 || 19 || 18 || 12 || 31 |- | 35 || 8 || 17 || 23 || 26 || 2 |- | 4 || 27 || 15 || 21 || 10 || 34 |- | 33 || 28 || 16 || 22 || 9 || 3 |- | 32 || 11 || 20 || 14 || 29 || 5 |- | 6 || 7 || 24 || 13 || 25 || 36 |} {{col-end}} As another example of a 6×6 magic square constructed this way is given below. Here the diagonal entries are arranged differently. The primary square is constructed by flipping the root square about the main diagonal. In the second square the proviso for singly even square is not satisfied, leading to a non-normal magic square (third square) where the numbers 3, 13, 24, and 34 are duplicated while missing the numbers 4, 18, 19, and 33. {{col-begin|width=auto;margin:0.5em auto}} {{col-break|valign=bottom}} {| class="wikitable" style="margin-left:auto;margin-right:auto;text-align:center;width:12em;height:12em;table-layout:fixed;" |- | 6 || 30 || 12 || 18 || 0 || 24 |- | 24 || 0 || '''12''' || '''18''' || 30 || 6 |- | '''24''' || '''0''' || 18 || 12 || '''30''' || '''6''' |- | '''6''' || '''30''' || 18 || 12 || '''0''' || '''24''' |- | 24 || 0 || '''18''' || '''12''' || 30 || 6 |- | 6 || 30 || 12 || 18 || 0 || 24 |} {{col-break|valign=bottom|gap=1em}} {| class="wikitable" style="margin-left:auto;margin-right:auto;text-align:center;width:12em;height:12em;table-layout:fixed;" |- | 2 || 5 || 5 || 2 || 5 || 2 |- | 6 || 1 || '''1''' || '''6''' || 1 || 6 |- | '''3''' || '''3''' || 4 || 4 || '''4''' || '''3''' |- | '''4''' || '''4''' || 3 || 3 || '''3''' || '''4''' |- | 1 || 6 || '''6''' || '''1''' || 6 || 1 |- | 5 || 2 || 2 || 5 || 2 || 5 |} {{col-break|valign=bottom|gap=1em}} {| class="wikitable" style="margin-left:auto;margin-right:auto;text-align:center;width:12em;height:12em;table-layout:fixed;" |- | 8 || 35 || 17 || 20 || 5 || 26 |- | 30 || 1 || '''13''' || '''24''' || 31 || 12 |- | 27 || '''3''' || 22 || 16 || '''34''' || 9 |- | 10 || '''34''' || 21 || 15 || '''3''' || 28 |- | 25 || 6 || '''24''' || '''13''' || 36 || 7 |- | 11 || 32 || 14 || 23 || 2 || 29 |} {{col-end}} The last condition is a bit arbitrary and may not always need to be invoked, as in this example, where in the root square each cell is vertically paired with its complement: {{col-begin|width=auto;margin:0.5em auto}} {{col-break|valign=bottom}} {| class="wikitable" style="margin-left:auto;margin-right:auto;text-align:center;width:12em;height:12em;table-layout:fixed;" |- | 6 || 30 || 12 || 24 || 18 || 0 |- | 6 || 0 || 18 || 24 || 12 || 30 |- | 24 || 0 || 12 || 6 || 18 || 30 |- | 6 || 30 || 18 || 24 || 12 || 0 |- | 24 || 30 || 12 || 6 || 18 || 0 |- | 24 || 0 || 18 || 6 || 12 || 30 |} {{col-break|valign=bottom|gap=1em}} {| class="wikitable" style="margin-left:auto;margin-right:auto;text-align:center;width:12em;height:12em;table-layout:fixed;" |- | 2 || 2 || 5 || 2 || 5 || 5 |- | 6 || 1 || 1 || 6 || 6 || 1 |- | 3 || 4 || 3 || 4 || 3 || 4 |- | 5 || 5 || 2 || 5 || 2 || 2 |- | 4 || 3 || 4 || 3 || 4 || 3 |- | 1 || 6 || 6 || 1 || 1 || 6 |} {{col-break|valign=bottom|gap=1em}} {| class="wikitable" style="margin-left:auto;margin-right:auto;text-align:center;width:12em;height:12em;table-layout:fixed;" |- | 8 || 32 || 17 || 26 || 23 || 5 |- | 12 || 1 || 19 || 30 || 18 || 31 |- | 27 || 4 || 15 || 10 || 21 || 34 |- | 11 || 35 || 20 || 29 || 14 || 2 |- | 28 || 33 || 16 || 9 || 22 || 3 |- | 25 || 6 || 24 || 7 || 13 || 36 |} {{col-end}} As one more example, we have generated an 8×8 magic square. Unlike the criss-cross pattern of the earlier section for evenly even square, here we have a checkered pattern for the altered and unaltered cells. Also, in each quadrant the odd and even numbers appear in alternating columns. {{col-begin|width=auto;margin:0.5em auto}} {{col-break|valign=bottom}} {| class="wikitable" style="margin-left:auto;margin-right:auto;text-align:center;width:16em;height:16em;table-layout:fixed;" |- | 0 || 48 || 16 || 32 || 24 || 40 || 8 || 56 |- | 56 || 8 || 40 || 24 || 32 || 16 || 48 || 0 |- | 0 || 48 || 16 || 32 || 24 || 40 || 8 || 56 |- | 56 || 8 || 40 || 24 || 32 || 16 || 48 || 0 |- | 56 || 8 || 40 || 24 || 32 || 16 || 48 || 0 |- | 0 || 48 || 16 || 32 || 24 || 40 || 8 || 56 |- | 56 || 8 || 40 || 24 || 32 || 16 || 48 || 0 |- | 0 || 48 || 16 || 32 || 24 || 40 || 8 || 56 |} {{col-break|valign=bottom|gap=1em}} {| class="wikitable" style="margin-left:auto;margin-right:auto;text-align:center;width:16em;height:16em;table-layout:fixed;" |- | 1 || 8 || 1 || 8 || 8 || 1 || 8 || 1 |- | 7 || 2 || 7 || 2 || 2 || 7 || 2 || 7 |- | 3 || 6 || 3 || 6 || 6 || 3 || 6 || 3 |- | 5 || 4 || 5 || 4 || 4 || 5 || 4 || 5 |- | 4 || 5 || 4 || 5 || 5 || 4 || 5 || 4 |- | 6 || 3 || 6 || 3 || 3 || 6 || 3 || 6 |- | 2 || 7 || 2 || 7 || 7 || 2 || 7 || 2 |- | 8 || 1 || 8 || 1 || 1 || 8 || 1 || 8 |} {{col-break|valign=bottom|gap=1em}} {| class="wikitable" style="margin-left:auto;margin-right:auto;text-align:center;width:16em;height:16em;table-layout:fixed;" |- | style="background-color: silver;"|1 || 56 || style="background-color: silver;"|17 || 40 || 32 || style="background-color: silver;"|41 || 16 || style="background-color: silver;"|57 |- | 63 ||style="background-color: silver;"| 10 || 47 || style="background-color: silver;"|26 || style="background-color: silver;"|34 || 23 || style="background-color: silver;"|50 || 7 |- | style="background-color: silver;"|3 || 54 || style="background-color: silver;"|19 || 38 || 30 || style="background-color: silver;"|43 || 14 || style="background-color: silver;"|59 |- | 61 || style="background-color: silver;"|12 || 45 || style="background-color: silver;"|28 || style="background-color: silver;"|36 || 21 || style="background-color: silver;"|42 || 5 |- | 60 || style="background-color: silver;"|13 || 44 || style="background-color: silver;"|29 || style="background-color: silver;"|37 || 20 || style="background-color: silver;"|53 || 4 |- | style="background-color: silver;"|6 || 51 || style="background-color: silver;"|22 || 35 || 27 || style="background-color: silver;"|46 || 11 || style="background-color: silver;"|62 |- | 58 || style="background-color: silver;"|15 || 42 || style="background-color: silver;"|31 || style="background-color: silver;"|39 || 18 || style="background-color: silver;"|55 || 2 |- | style="background-color: silver;"|8 || 47 || style="background-color: silver;"|24 || 33 || 25 || style="background-color: silver;"|48 || 9 || style="background-color: silver;"|64 |} {{col-end}} '''Variations''': A number of variations of the basic idea are possible: ''a complementary pair can appear ''n''/2 times or less in a column''. That is, a column of a Greek square can be constructed using more than one complementary pair. This method allows us to imbue the magic square with far richer properties. The idea can also be extended to the diagonals too. An example of an 8×8 magic square is given below. In the finished square each of four quadrants are pan-magic squares as well, each quadrant with same magic constant 130. {{col-begin|width=auto;margin:0.5em auto}} {{col-break|valign=bottom}} {| class="wikitable" style="margin-left:auto;margin-right:auto;text-align:center;width:16em;height:16em;table-layout:fixed;" |- | 0 || 48 || 56 || 8 || 16 || 32 || 40 || 24 |- | 56 || 8 || 0 || 48 || 40 || 24 || 16 || 32 |- | 0 || 48 || 56 || 8 || 16 || 32 || 40 || 24 |- | 56 || 8 || 0 || 48 || 40 || 24 || 16 || 32 |- | 48 || 0 || 8 || 56 || 32 || 16 || 24 || 40 |- | 8 || 56 || 48 || 0 || 24 || 40 || 32 || 16 |- | 48 || 0 || 8 || 56 || 32 || 16 || 24 || 40 |- | 8 || 56 || 48 || 0 || 24 || 40 || 32 || 16 |} {{col-break|valign=bottom|gap=1em}} {| class="wikitable" style="margin-left:auto;margin-right:auto;text-align:center;width:16em;height:16em;table-layout:fixed;" |- | 1 || 8 || 1 || 8 || 7 || 2 || 7 || 2 |- | 7 || 2 || 7 || 2 || 1 || 8 || 1 || 8 |- | 8 || 1 || 8 || 1 || 2 || 7 || 2 || 7 |- | 2 || 7 || 2 || 7 || 8 || 1 || 8 || 1 |- | 3 || 6 || 3 || 6 || 5 || 4 || 5 || 4 |- | 5 || 4 || 5 || 4 || 3 || 6 || 3 || 6 |- | 6 || 3 || 6 || 3 || 4 || 5 || 4 || 5 |- | 4 || 5 || 4 || 5 || 6 || 3 || 6 || 3 |} {{col-break|valign=bottom|gap=1em}} {| class="wikitable" style="margin-left:auto;margin-right:auto;text-align:center;width:16em;height:16em;table-layout:fixed;" |- | style="background-color: silver;"|1 || style="background-color: silver;"|56 || style="background-color: silver;"|57 || style="background-color: silver;"|16 || 23 || 34 || 47 || 26 |- | style="background-color: silver;"|63 || style="background-color: silver;"|10 || style="background-color: silver;"|7 || style="background-color: silver;"|50 || 41 || 32 || 17 || 40 |- | style="background-color: silver;"|8 || style="background-color: silver;"|49 || style="background-color: silver;"|64 || style="background-color: silver;"|9 || 18 || 39 || 42 || 31 |- | style="background-color: silver;"|58 || style="background-color: silver;"|15 || style="background-color: silver;"|2 || style="background-color: silver;"|55 || 48 || 25 || 24 || 33 |- | 51 || 6 || 11 || 62 || style="background-color: silver;"|37 || style="background-color: silver;"|20 || style="background-color: silver;"|29 || style="background-color: silver;"|44 |- | 13 || 60 || 53 || 4 || style="background-color: silver;"|27 || style="background-color: silver;"|46 || style="background-color: silver;"|35 || style="background-color: silver;"|22 |- | 54 || 3 || 14 || 59 || style="background-color: silver;"|36 || style="background-color: silver;"|21 || style="background-color: silver;"|28 || style="background-color: silver;"|45 |- | 12 || 61 || 52 || 5 || style="background-color: silver;"|30 || style="background-color: silver;"|43 || style="background-color: silver;"|38 || style="background-color: silver;"|19 |} {{col-end}}
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)