Office Applications and Entertainment, Latin Squares

Vorige Pagina Volgende Pagina Index About the Author

5.0   Latin Squares (5 x 5)

A Latin Square of order 5 is a 5 x 5 square filled with 5 different symbols, each occurring only once in each row and only once in each column.

Based on this definition 161280 ea order 5 Latin Squares can be found (ref. LatSqr5).

For the construction of order 5 Magic Squares normally only those Latin Squares are used for which the 5 different symbols occur also only once in each of the main diagonals (Latin Diagonal Squares).

5.1   Latin Diagonal Squares (5 x 5)

Attachment 3.7.1 shows the 960 ea order 5 Latin Diagonal Squares, which can be found based on the definition formulated above (ref. SudSqr5a).

Suitable Euler Squares can be found, by selecting pairs of Latin Diagonal Squares (A, B) while ensuring that the resulting square M contains 25 distinct pairs.

Based on the symbols {ai} = {0, 1, 2, 3, 4} and {bi} = {0, 1, 2, 3, 4}, 57600 Euler Squares can be constructed (ref. CnstrSqrs5a)

5.2   Magic Squares, Natural Numbers

5.2.1 Simple Magic Squares

(Simple) Magic Square M of order 5 with the integers 1 ... 25 can be written as M = A + 5 * B + [1] where the squares A and B contain only the integers 0, 1, 2, 3 and 4.

Consequently order 5 (Simple) Magic Squares can be based on pairs of Orthogonal Latin Diagonal Squares (A, B) which is illustrated below for a Pan Magic Square M.

A
2 1 0 4 3
0 4 3 2 1
3 2 1 0 4
1 0 4 3 2
4 3 2 1 0
B
1 0 4 3 2
3 2 1 0 4
0 4 3 2 1
2 1 0 4 3
4 3 2 1 0
M = A + 5 * B + 1
8 2 21 20 14
16 15 9 3 22
4 23 17 11 10
12 6 5 24 18
25 19 13 7 1

Based on the 57600 Euler Squares found in Section 5.1 above, 57600 ea (Simple) Magic Squares can be constructed.

Attachment 3.7.3 shows a collection of 4288 Latin Squares with the Main Diagonals summing to 10, which can be filtered from the 161280 Latin Squares found in Section 5.0 above.

Based on this sub collection 143424 order 5 Simple Magic Squares can be constructed, which include the 57600 found above.

5.2.2 Pan Magic Squares

Attachment 3.7.2 shows the 240 ea order 5 Latin Diagonal Squares, with the Broken Diagonals summing to 10, which can be filtered from the 960 Latin Diagonal squares found in Section 5.1 above.

All 28800 order 5 Pan Magic Squares can be based on pairs of Orthogonal Latin Diagonal Squares (A, B) out of this collection and are shown in Attachment 5.2.6.

5.2.3 Ultra Magic Squares

Attachment 3.7.4 shows the 16 ea order 5 Symmetric Latin Diagonal Squares, with the Broken Diagonals summing to 10, which can be filtered from the 960 Latin Diagonal squares found in Section 5.1 above.

All 128 order 5 Ultra Magic Squares can be based on pairs of Orthogonal Symmetric Latin Diagonal Squares (A, B) out of this collection and are shown in Attachment 5.4.1.

5.2.4 Associated Magic Squares

Symmetric Latin Diagonal Squares

Attachment 3.7.3 shows the 64 ea order 5 Symmetric Latin Diagonal Squares, which can be filtered from the 960 Latin Diagonal Squares found in Section 5.1 above.

The 256 order 5 Associated Magic Squares, which can be based on pairs of Orthogonal Symmetric Latin Diagonal Squares (A, B) out of this collection, are shown in Attachment 5.2.3.

Symmetric Latin Squares

Attachment 5.2.4 shows the 256 ea order 5 Symmetric Latin Squares, which can be filtered from the 161280 Latin Squares found in Section 5.0 above.

Based on this collection 3072 order 5 Associated Magic Squares can be constructed.

Symmetric Semi-Latin Squares

Alternatively order 5 Associated Magic Squares M can be constructed based on pairs of Orthogonal Symmetric Semi-Latin Squares (A, B), as shown below for the symbols {ai, i = 1 ... 5} and {bj, j = 1 ... 5).

A
a5 a4 a2 a3 a1
a3 a2 a1 a4 a5
a1 a4 a3 a2 a5
a1 a2 a5 a4 a3
a5 a3 a4 a2 a1
B
b5 b3 b1 b1 b5
b4 b2 b4 b2 b3
b2 b1 b3 b5 b4
b3 b4 b2 b4 b2
b1 b5 b5 b3 b1
(A, B)
a5, b5 a4, b3 a2, b1 a3, b1 a1, b5
a3, b4 a2, b2 a1, b4 a4, b2 a5, b3
a1, b2 a4, b1 a3, b3 a2, b5 a5, b4
a1, b3 a2, b4 a5, b2 a4, b4 a3, b2
a5, b1 a3, b5 a4, b5 a2, b3 a1, b1

All pairs of the resulting square (A, B) are distinct, as illustrated by following numerical example:

A
4 3 1 2 0
2 1 0 3 4
0 3 2 1 4
0 1 4 3 2
4 2 3 1 0
B = T(A)
4 2 0 0 4
3 1 3 1 2
1 0 2 4 3
2 3 1 3 1
0 4 4 2 0
M = A + 5 * B + 1
25 14 2 3 21
18 7 16 9 15
6 4 13 22 20
11 17 10 19 8
5 23 24 12 1

Attachment 5.2.5 shows 960 ea order 5 Symmetric (Semi) Latin Squares, which can be found with procedure SemiLat5a.

Based on this collection 29696 order 5 Associated Magic Squares can be constructed.

5.2.5 Crosswise Symmetric Magic Squares

Order 5 Crosswise Symmetric Magic Squares M can be constructed based on pairs of Orthogonal Crosswise Symmetric (Semi) Latin Squares (A, B), as summarized below:

Cross Symm
Summary

Type

A

M

Latin Diagonal

32

0

Latin

256

3072

Semi Latin Diagonal

128

512

Semi Latin

960

14080

For each type, all pairs of the resulting square (A, B) are distinct, as illustrated by following numerical example:

A
1 4 0 3 2
0 3 4 2 1
3 1 2 0 4
2 0 1 4 3
4 2 3 1 0
B
3 0 1 2 4
4 1 3 0 2
0 4 2 3 1
1 2 0 4 3
2 3 4 1 0
M = A + 5 * B + 1
17 5 6 14 23
21 9 20 3 12
4 22 13 16 10
8 11 2 25 19
15 18 24 7 1

Attachment 5.2.8 shows 256 ea order 5 Crosswise Symmetric Latin Squares, which can be found with procedure SemiLat5d.

Based on this collection 3072 order 5 Crosswise Symmetric Magic Squares can be constructed, of which the first 96 are shown in Attachment 5.4.8.

Note:
The number of Semi Latin Squares shown in the Summary above is based on Latin Rows. If the squares with Latin Columns are added more Crosswise Symmetric Magic Squares can be constructed (29696).

5.2.6 Concentric Magic Squares

Order 5 Concentric Magic Squares M can be constructed based on pairs of Orthogonal Concentric Semi-Latin Squares (A, B), as shown below for the symbols {ai, i = 1 ... 5} and {bj, j = 1 ... 5).

A
a5 a1 a2 a4 a3
a1 a4 a2 a3 a5
a5 a2 a3 a4 a1
a1 a3 a4 a2 a5
a3 a5 a4 a2 a1
B
b3 b1 b5 b5 b1
b2 b3 b2 b4 b4
b1 b4 b3 b2 b5
b4 b2 b4 b3 b2
b5 b5 b1 b1 b3
(A, B)
a5, b3 a1, b1 a2, b5 a4, b5 a3, b1
a1, b2 a4, b3 a2, b2 a3, b4 a5, b4
a5, b1 a2, b4 a3, b3 a4, b2 a1, b5
a1, b4 a3, b2 a4, b4 a2, b3 a5, b2
a3, b5 a5, b5 a4, b1 a2, b1 a1, b3

All pairs of the resulting square (A, B) are distinct, as illustrated by following numerical example:

A
4 0 1 3 2
0 3 1 2 4
4 1 2 3 0
0 2 3 1 4
2 4 3 1 0
B
2 0 4 4 0
1 2 1 3 3
0 3 2 1 4
3 1 3 2 1
4 4 0 0 2
M = A + 5 * B + 1
15 1 22 24 3
6 14 7 18 20
5 17 13 9 21
16 8 19 12 10
23 25 4 2 11

Attachment 5.2.6 shows 216 ea order 5 Concentric (Semi) Latin Squares, which can be found with procedure SemiLat5b.

Based on this collection 1152 order 5 Concentric Magic Squares can be constructed, which are shown in Attachment 5.4.6.

5.2.7 Diamond Inlays

Order 5 Inlaid Magic Squares M can be constructed based on pairs of Orthogonal Inlaid Semi-Latin Squares (A, B), as shown below for the symbols {ai, i = 1 ... 5} and {bj, j = 1 ... 5).

A
a5 a1 a3 a4 a2
a1 a2 a3 a4 a5
a4 a5 a3 a1 a2
a1 a2 a3 a4 a5
a4 a5 a3 a2 a1
B
b3 b1 b4 b5 b2
b2 b3 b5 b1 b4
b2 b1 b3 b5 b4
b4 b5 b1 b3 b2
b4 b5 b2 b1 b3
(A,B)
a5, b3 a1, b1 a3, b4 a4, b5 a2, b2
a1, b2 a2, b3 a3, b5 a4, b1 a5, b4
a4, b2 a5, b1 a3, b3 a1, b5 a2, b4
a1, b4 a2, b5 a3, b1 a4, b3 a5, b2
a4, b4 a5, b5 a3, b2 a2, b1 a1, b3

All pairs of the resulting square (A, B) are distinct, as illustrated by following numerical example:

A
4 0 2 3 1
0 1 2 3 4
3 4 2 0 1
0 1 2 3 4
3 4 2 1 0
B
2 0 3 4 1
1 2 4 0 3
1 0 2 4 3
3 4 0 2 1
3 4 1 0 2
M = A + 5 * B + 1
15 1 18 24 7
6 12 23 4 20
9 5 13 21 17
16 22 3 14 10
19 25 8 2 11

Attachment 5.2.7 shows 284 ea order 5 Inlaid (Semi) Latin Squares, which can be found with procedure SemiLat5c.

Based on this collection 1616 order 5 Inlaid Magic Squares can be constructed, which are shown in Attachment 5.4.7.

5.2.8 Evaluation of the Results

Following table compares the enumeration results for order 5 Magic Squares (ref. Section 5.8) with the results based on the construction methods described above:

Type

Enumerated

Constructed

Base

Simple (All)

2202441792 )*

143424   

Latin )**

57600   

Latin Diagonal

Pan Magic

28800   

28800   

Latin Diagonal

Ultra Magic

128   

128   

Latin Diagonal

Associated

388352   

29696   

Semi-Latin

Crosswise Symm

388352   

29696   

Semi-Latin

Concentric

23040   

1152   

Semi-Latin

Diamond Inlay

8288   

1616   

Semi-Latin


)*  By Richard C. Schroeppel (1973)
)** Latin Squares, Main Diagonals summing to 10.

The constructability by means of Orthogonal (Latin Diagonal) Squares can be considered as an additional property.

5.3   Magic Squares, Prime Numbers

5.3.1 Simple Magic Squares

When the elements {ai, i = 1 ... 5} and {bj, j = 1 ... 5) of a valid pair of Orthogonal Latin Diagonal Squares (A, B) - as applied in Section 5.2.1 above - comply with following condition:

  • mij = ai + bj = prime for i = 1 ... 5 and j = 1 ... 5 (correlated)

the resulting square M = A + B will be an order 5 Prime Number Simple or Pan Magic Square.

As half of the Orthogonal pairs (A, B) return Pan Magic Squares, only Prime Number Pan Magic Squares will be considered.

5.3.2 Pan Magic Squares

Attachment 5.3, page 1 contains miscellaneous correlated unbalanced series {ai, i = 1 ... 5} and {bj, j = 1 ... 5).

Based on Orthogonal Squares (A,B) as applied in Section 5.2.2 and correlated (unbalanced) series, the square M = A + B will be an order 5 Prime Number Pan Magic Square.

Sa = 171
1 3 13 27 127
13 27 127 1 3
127 1 3 13 27
3 13 27 127 1
27 127 1 3 13
Sb = 224
4 10 40 70 100
70 100 4 10 40
10 40 70 100 4
100 4 10 40 70
40 70 100 4 10
Sm = 395
5 13 53 97 227
83 127 131 11 43
137 41 73 113 31
103 17 37 167 71
67 197 101 7 23

Attachment 5.3.2 contains the resulting Prime Number Pan Magic Squares for miscellaneous Magic Sums (Sm).

Each square shown corresponds with 28800 Prime Number Pan Magic Squares.

5.3.3 Ultra Magic Squares

When the elements {ai, i = 1 ... 5} and {bj, j = 1 ... 5) of a valid pair of Orthogonal Latin Diagonal Squares (A, B) - as applied in Section 5.2.3 above - comply with following conditions:

  • mij = ai + bj = prime for i = 1 ... 5 and j = 1 ... 5 (correlated)
  • a1 + a5 = 2 * a3 and b1 + b5 = 2 * b3                 (balanced)
    a2 + a4 = 2 * a3 and b2 + b4 = 2 * b3

The resulting square M = A + B will be an order 5 Prime Number Ultra Magic Square.

Sa = 2455
941 41 881 491 101
491 101 941 41 881
41 881 491 101 941
101 941 41 881 491
881 491 101 941 41
Sb = 1050
420 210 0 348 72
0 348 72 420 210
72 420 210 0 348
210 0 348 72 420
348 72 420 210 0
Sm = 3505
1361 251 881 839 173
491 449 1013 461 1091
113 1301 701 101 1289
311 941 389 953 911
1229 563 521 1151 41

Attachment 5.3, page 2 contains miscellaneous correlated balanced series {ai, i = 1 ... 5} and {bj, j = 1 ... 5).

Attachment 5.3.3 contains the resulting Prime Number Ultra Magic Squares and related Magic Sums (Sm).

Each square shown corresponds with numerous Prime Number Ultra Magic Squares.

5.3.4 Associated Magic Squares

Based on Orthogonal Semi-Latin Squares (A,B) as applied in Section 5.2.4 and correlated balanced series, the square M = A + B will be an order 5 Prime Number Associated Magic Square.

Sa = 2455
941 881 101 491 41
491 101 41 881 941
41 881 491 101 941
41 101 941 881 491
941 491 881 101 41
Sb = 1050
420 210 0 0 420
348 72 348 72 210
72 0 210 420 348
210 348 72 348 72
0 420 420 210 0
Sm = 3505
1361 1091 101 491 461
839 173 389 953 1151
113 881 701 521 1289
251 449 1013 1229 563
941 911 1301 311 41

Attachment 5.3.4 contains the resulting Prime Number Associated Magic Squares for miscellaneous Magic Sums (Sm).

Each square shown corresponds with numerous Prime Number Associated Magic Squares.

5.3.5 Concentric Magic Squares

Based on Orthogonal Semi-Latin Squares (A,B) as applied in Section 5.2.5 and correlated balanced series, the square M = A + B will be an order 5 Prime Number Concentric Magic Square.

Sa = 2455
41 881 941 101 491
941 101 881 491 41
41 881 491 101 941
941 491 101 881 41
491 101 41 881 941
Sb = 1050
210 420 0 420 0
72 210 348 72 348
0 72 210 348 420
348 348 72 210 72
420 0 420 0 210
Sm = 3505
251 1301 941 521 491
1013 311 1229 563 389
41 953 701 449 1361
1289 839 173 1091 113
911 101 461 881 1151

Attachment 5.3.5 contains the resulting Prime Number Concentric Magic Squares for miscellaneous Magic Sums (Sm).

Each square shown corresponds with numerous Prime Number Concentric Magic Squares.

5.4   Summary

The obtained results regarding the order 5 Latin - and related Magic Squares, as deducted and discussed in previous sections, are summarized in following table:

Attachment

Subject

Subroutine

Attachment 3.7.1

Latin Diagonal Squares

SudSqr5a

Attachment 5.2.6

Pan Magic Squares

CnstrSqrs5a

Attachment 5.4.1

Ultra Magic Squares

Attachment 5.2.3

Associated Magic Squares

Attachment 5.4.6

Concentric Magic Squares

Attachment 5.4.7

Inlaid Magic Squares (Diamond Inlay)

Attachment 53

Correlated Magic Series

-

Attachment 5.3.2

Prime Number Pan Magic Squares

CnstrSqrs5b

Attachment 5.3.3

Prime Number Ultra Magic Squares

Attachment 5.3.4

Prime Number Associated Magic Squares

Attachment 5.3.5

Prime Number Concentric Magic Squares

Comparable methods as described above, can be used to construct order 6 Semi-Latin - and related Magic Squares (with Symmetrical Main Diagonals), which will be described in following sections.


Vorige Pagina Volgende Pagina Index About the Author