Office Applications and Entertainment, Latin Squares

Vorige Pagina Volgende Pagina Index About the Author

10.0   Latin Squares (10 x 10)

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

Based on this definition 9.982.437.658.213.039.871.725.064.756.920.320.000 ea order 10 Latin Squares can be found (ref. OEIS A002860).

10.1   Latin Diagonal Squares (10 x 10)

Latin Diagonal Squares are Latin Squares for which the 10 different symbols occur also only once in each of the main diagonals.

10.2   Magic Squares, Natural Numbers

10.2.1 General

Although Euler postulated that sets of Greco Latin Squares did not exist for oddly even orders n ≡ 2 (mod 4), R. C. Bose and S. Shrinkhade proved the contrary for all n >= 10 (1959/1960).

Consequently also order 10 (Simple) Magic Squares can be based on pairs of Orthogonal (Latin Diagonal) Squares (A, B).

10.2.2 Simple Magic Squares

An example of the construction of an order 10 Simple Magic Square M based on a pair of Orthogonal Latin Diagonal Squares (A, B), is shown below for the symbols {ai, i = 1 ... 10} and {bj, j = 1 ... 10).

A
a10 a8 a3 a1 a7 a4 a2 a9 a5 a6
a8 a2 a6 a9 a10 a3 a5 a7 a1 a4
a1 a10 a8 a2 a9 a7 a6 a5 a4 a3
a3 a9 a1 a4 a5 a8 a10 a6 a7 a2
a5 a7 a10 a8 a6 a2 a1 a4 a3 a9
a4 a3 a7 a6 a8 a5 a9 a1 a2 a10
a9 a1 a2 a3 a4 a6 a7 a8 a10 a5
a2 a6 a9 a5 a1 a10 a4 a3 a8 a7
a6 a4 a5 a7 a2 a1 a3 a10 a9 a8
a7 a5 a4 a10 a3 a9 a8 a2 a6 a1
B
b10 b6 b5 b8 b1 b3 b4 b2 b7 b9
b7 b2 b4 b3 b9 b10 b1 b8 b5 b6
b6 b5 b8 b1 b10 b9 b3 b4 b2 b7
b9 b7 b2 b4 b3 b1 b8 b5 b6 b10
b2 b4 b3 b9 b6 b7 b10 b1 b8 b5
b8 b1 b10 b7 b2 b5 b6 b9 b3 b4
b4 b3 b9 b6 b5 b2 b7 b10 b1 b8
b5 b8 b1 b10 b7 b6 b9 b3 b4 b2
b1 b10 b6 b5 b8 b4 b2 b7 b9 b3
b3 b9 b7 b2 b4 b8 b5 b6 b10 b1

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

A
9 7 2 0 6 3 1 8 4 5
7 1 5 8 9 2 4 6 0 3
0 9 7 1 8 6 5 4 3 2
2 8 0 3 4 7 9 5 6 1
4 6 9 7 5 1 0 3 2 8
3 2 6 5 7 4 8 0 1 9
8 0 1 2 3 5 6 7 9 4
1 5 8 4 0 9 3 2 7 6
5 3 4 6 1 0 2 9 8 7
6 4 3 9 2 8 7 1 5 0
B
9 5 4 7 0 2 3 1 6 8
6 1 3 2 8 9 0 7 4 5
5 4 7 0 9 8 2 3 1 6
8 6 1 3 2 0 7 4 5 9
1 3 2 8 5 6 9 0 7 4
7 0 9 6 1 4 5 8 2 3
3 2 8 5 4 1 6 9 0 7
4 7 0 9 6 5 8 2 3 1
0 9 5 4 7 3 1 6 8 2
2 8 6 1 3 7 4 5 9 0
M = A + 10 * B + 1
100 58 43 71 7 24 32 19 65 86
68 12 36 29 90 93 5 77 41 54
51 50 78 2 99 87 26 35 14 63
83 69 11 34 25 8 80 46 57 92
15 37 30 88 56 62 91 4 73 49
74 3 97 66 18 45 59 81 22 40
39 21 82 53 44 16 67 98 10 75
42 76 9 95 61 60 84 23 38 17
6 94 55 47 72 31 13 70 89 28
27 85 64 20 33 79 48 52 96 1

Each orthogonal set (A, B) corresponds with 1920 transformations, as described below.

  • Any line n can be interchanged with line (11 - n). The possible number of transformations is 25 = 32.
    It should be noted that for each square the 180o rotated aspect is included in this collection.

  • Any permutation can be applied to the lines 1, 2, 3, 4, 5, provided that the same permutation is applied to the lines 10, 9, 8, 7, 6. The possible number of transformations is 5! = 120.

The resulting number of transformations, excluding the 180o rotated aspects, is 32/2 * 120 = 1920.

Attachment 10.2.2 shows alternatively the construction of a Simple Magic Square M based on a Self Orthogonal Diagonal Latin Square A.

The first row of the Self Orthogonal Diagonal Latin Square A is in natural order. The total number of Self Orthogonal Diagonal Latin Squares of order 10 is 234255360 * 10! = 850065850368000 (ref. OEIS A287762).

10.2.3 Simple Magic Squares

Symmetrical Diagonals

An example of the construction of an order 10 Simple Magic Square M - with Symmetrical Diagonals - based on pairs of Orthogonal Semi-Latin Squares (A, B), is shown below for the symbols {ai, i = 1 ... 10} and {bj, j = 1 ... 10}.

A
a1 a1 a1 a1 a10 a10 a10 a10 a10 a1
a2 a2 a2 a9 a9 a9 a9 a9 a2 a2
a3 a8 a3 a3 a8 a8 a8 a3 a8 a3
a4 a4 a7 a4 a7 a7 a4 a7 a7 a4
a5 a5 a5 a6 a5 a5 a6 a6 a6 a6
a6 a6 a6 a5 a6 a6 a5 a5 a5 a5
a7 a7 a4 a7 a4 a4 a7 a4 a4 a7
a8 a3 a8 a8 a3 a3 a3 a8 a3 a8
a9 a9 a9 a2 a2 a2 a2 a2 a9 a9
a10 a10 a10 a10 a1 a1 a1 a1 a1 a10
B = T(A)
b1 b2 b3 b4 b5 b6 b7 b8 b9 b10
b1 b2 b8 b4 b5 b6 b7 b3 b9 b10
b1 b2 b3 b7 b5 b6 b4 b8 b9 b10
b1 b9 b3 b4 b6 b5 b7 b8 b2 b10
b10 b9 b8 b7 b5 b6 b4 b3 b2 b1
b10 b9 b8 b7 b5 b6 b4 b3 b2 b1
b10 b9 b8 b4 b6 b5 b7 b3 b2 b1
b10 b9 b3 b7 b6 b5 b4 b8 b2 b1
b10 b2 b8 b7 b6 b5 b4 b3 b9 b1
b1 b2 b3 b4 b6 b5 b7 b8 b9 b10

The Semi-Latin Square A has Semi-Latin Rows, Latin Columns and Latin Diagonals (Symmetrical).
The Semi-Latin Square B is the transposed square of A (rows and columns exchanged).

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

A
0 0 0 0 9 9 9 9 9 0
1 1 1 8 8 8 8 8 1 1
2 7 2 2 7 7 7 2 7 2
3 3 6 3 6 6 3 6 6 3
4 4 4 5 4 4 5 5 5 5
5 5 5 4 5 5 4 4 4 4
6 6 3 6 3 3 6 3 3 6
7 2 7 7 2 2 2 7 2 7
8 8 8 1 1 1 1 1 8 8
9 9 9 9 0 0 0 0 0 9
B = T(A)
0 1 2 3 4 5 6 7 8 9
0 1 7 3 4 5 6 2 8 9
0 1 2 6 4 5 3 7 8 9
0 8 2 3 5 4 6 7 1 9
9 8 7 6 4 5 3 2 1 0
9 8 7 6 4 5 3 2 1 0
9 8 7 3 5 4 6 2 1 0
9 8 2 6 5 4 3 7 1 0
9 1 7 6 5 4 3 2 8 0
0 1 2 3 5 4 6 7 8 9
M = A + 10 * B + 1
1 11 21 31 50 60 70 80 90 91
2 12 72 39 49 59 69 29 82 92
3 18 23 63 48 58 38 73 88 93
4 84 27 34 57 47 64 77 17 94
95 85 75 66 45 55 36 26 16 6
96 86 76 65 46 56 35 25 15 5
97 87 74 37 54 44 67 24 14 7
98 83 28 68 53 43 33 78 13 8
99 19 79 62 52 42 32 22 89 9
10 20 30 40 51 41 61 71 81 100

The amount of Semi-Latin Squares with Symmetrical Diagonals is so substantial, that the example shown above is based on following (restricting) properties:

  • Row 1 and 10 contain the integers 0 and 9
  • Row 2 and  9 contain the integers 1 and 8
  • Row 3 and  8 contain the integers 2 and 7
  • Row 4 and  7 contain the integers 3 and 6
  • Row 5 and  6 contain the integers 4 and 5

The number of Orthogonal Sets (A, B) which can be generated under these conditions, with both diagonals, the top and bottom row constant, is 117504 (ref. SemiLat10).

Composed Border

With the 'Check Border' routine activated it is possible to filter Orthogonal Semi-Latin Squares (A, B) with Composed Borders from the collection described above, as illustrated by following numerical example (ref. SemiLat10):

A
0 0 0 0 9 9 9 9 9 0
1 1 1 8 8 8 8 8 1 1
2 7 2 2 7 7 7 2 7 2
3 6 6 3 3 6 3 6 6 3
4 4 4 5 4 4 5 5 5 5
5 5 5 4 5 5 4 4 4 4
6 3 3 6 6 3 6 3 3 6
7 2 7 7 2 2 2 7 2 7
8 8 8 1 1 1 1 1 8 8
9 9 9 9 0 0 0 0 0 9
B = T(A)
0 1 2 3 4 5 6 7 8 9
0 1 7 6 4 5 3 2 8 9
0 1 2 6 4 5 3 7 8 9
0 8 2 3 5 4 6 7 1 9
9 8 7 3 4 5 6 2 1 0
9 8 7 6 4 5 3 2 1 0
9 8 7 3 5 4 6 2 1 0
9 8 2 6 5 4 3 7 1 0
9 1 7 6 5 4 3 2 8 0
0 1 2 3 5 4 6 7 8 9
C = A + 10 * B + 1
1 11 21 31 50 60 70 80 90 91
2 12 72 69 49 59 39 29 82 92
3 18 23 63 48 58 38 73 88 93
4 87 27 34 54 47 64 77 17 94
95 85 75 36 45 55 66 26 16 6
96 86 76 65 46 56 35 25 15 5
97 84 74 37 57 44 67 24 14 7
98 83 28 68 53 43 33 78 13 8
99 19 79 62 52 42 32 22 89 9
10 20 30 40 51 41 61 71 81 100

The number of Orthogonal Sets (A, B), which can be filtered from the collection with both diagonals, the top and bottom row constant, is 6400 out of 117504.

10.2.4 Almost Associated Magic Squares

Order 10 Almost Associated Magic Squares as discussed in Section 10.3.2, but composed out of

  • An order 10 Associated Border and
  • An order 6 Almost Associated Center Square

can be constructed based on Orthogonal Semi-Latin Squares (A, B) as illustrted by following numerical example:

A
9 7 9 1 0 0 9 1 8 1
0 8 0 9 8 8 1 8 0 3
1 6 7 2 7 4 2 5 6 5
2 5 3 6 3 3 6 6 9 2
5 2 2 5 4 7 5 4 5 6
3 4 5 4 2 5 4 7 7 4
7 0 6 3 6 6 3 3 4 7
4 3 4 7 5 2 7 2 3 8
6 9 1 8 1 1 0 9 1 9
8 1 8 0 9 9 8 0 2 0
B
9 0 1 2 5 3 7 4 6 8
7 8 6 5 2 4 0 3 9 1
9 0 7 3 5 2 6 4 1 8
1 9 4 6 2 7 3 5 8 0
0 8 5 3 4 2 6 7 1 9
0 8 2 3 7 5 6 4 1 9
9 1 4 6 2 7 3 5 0 8
1 8 5 6 7 4 3 2 9 0
8 0 6 9 5 7 4 3 1 2
1 3 5 2 6 4 7 8 9 0
C = A + 10 * B + 1
100 8 20 22 51 31 80 42 69 82
71 89 61 60 29 49 2 39 91 14
92 7 78 33 58 25 63 46 17 86
13 96 44 67 24 74 37 57 90 3
6 83 53 36 45 28 66 75 16 97
4 85 26 35 73 56 65 48 18 95
98 11 47 64 27 77 34 54 5 88
15 84 55 68 76 43 38 23 94 9
87 10 62 99 52 72 41 40 12 30
19 32 59 21 70 50 79 81 93 1

The defining equations for the (Semi-Latin) Associated Borders can be written as:

a(91) =   s1   - a(92) - a(93) - a(94) - a(95) - a(96) - a(97) - a(98) - a(99) - a(100)
a(85) =          a(86) - a(95) + a(96)
a(84) =          a(87) - a(94) + a(97)
a(83) =          a(88) - a(93) + a(98)
a(81) =   s1   - a(82) - a(83) - a(84) - a(85) - a(86) - a(87) - a(88) - a(89) - a(90)
a(71) = 2*s1/5 - a(72) - a(79) - a(80)
a(61) = 2*s1/5 - a(62) - a(69) - a(70)
a(59) = 8*s1/5 - a(60) - a(69) - a(70) - a(79) - a(80) - a(86) - a(87) - a(88) - a(89) +
                                                       - a(90) - a(96) - a(97) - a(98) - a(99) - a(100)
a(52) =          a(59) - a(62) + a(69) - a(72) + a(79) - a(82) + a(89) - a(92) + a(99)
a(51) = 2*s1/5 - a(52) - a(59) - a(60)

a(i) =    s1/5 - a(101 - i) for i = 1 ... 22, 29 ... 32, 39 ... 42, 49, 50

The solutions can be obtained by guessing the 22 parameters:

   a(i) for i = 60, 62, 69. 70, 72, 79, 80, 82, 86 ... 90 and 92 ... 100

and filling out these guesses in the abovementioned equations.

Attachment 10.24.1 shows 256 ea order 10 Semi-Latin Associated Borders - with Latin Columns and suitable for Latin Diagonals - based on the equations deducted above (ref. AssBrdr10).

Attachment 10.24.2 shows 256 ea order 10 Associated Borders based on M = A + 10 * T(A) + 1, with T(A) the transposed square of A (rows and columns exchanged).

Based on the 73728 order 6 Almost Associated Center Squares as found in Section 6.2.4, the 256 order 10 Associated Borders result in 256 * 73728 = 18.874.368 order 10 Almost Associated Magic Squares.

10.2.5 Bordered Magic Squares

The order 8 Orthogonal Latin Diagonal or Semi-Latin Squares (A8, B8), as discussed in Section 8.2, have been used to construct collections of Simple Magic Squares based on the Balanced Series {0 ... 7}.

From the Balanced Series {0 ... 9} five suitable Balanced Sub Series can be selected to construct Center Squares for order 10 Bordered Magic Squares e.g. {1 ... 8}.

Suitable Borders can be constructed for each of these Center Squares, based on pairs of Non Latin but Orthogonal Borders (A, B).

A numerical example of the construction of a Bordered Magic Square with a Pan Magic Square composed of order 4 Pan Magic Sub Squares as Center Square is shown below:

A
0 6 5 4 9 0 9 2 1 9
3 4 1 8 5 3 2 7 6 6
9 6 7 2 3 5 8 1 4 0
9 1 4 5 8 2 3 6 7 0
0 7 6 3 2 8 5 4 1 9
9 4 1 8 5 3 2 7 6 0
0 6 7 2 3 5 8 1 4 9
8 1 4 5 8 2 3 6 7 1
7 7 6 3 2 8 5 4 1 2
0 3 4 5 0 9 0 7 8 9
B
0 9 9 9 8 8 2 0 0 0
9 4 6 1 7 4 6 1 7 0
7 1 7 4 6 1 7 4 6 2
6 8 2 5 3 8 2 5 3 3
6 5 3 8 2 5 3 8 2 3
4 3 5 2 8 3 5 2 8 5
4 2 8 3 5 2 8 3 5 5
0 7 1 6 4 7 1 6 4 9
0 6 4 7 1 6 4 7 1 9
9 0 0 0 1 1 7 9 9 9
M = A + 10 * B + 1
1 97 96 95 90 81 30 3 2 10
94 45 62 19 76 44 63 18 77 7
80 17 78 43 64 16 79 42 65 21
70 82 25 56 39 83 24 57 38 31
61 58 37 84 23 59 36 85 22 40
50 35 52 29 86 34 53 28 87 51
41 27 88 33 54 26 89 32 55 60
9 72 15 66 49 73 14 67 48 92
8 68 47 74 13 69 46 75 12 93
91 4 5 6 11 20 71 98 99 100

Each pair of order 10 Orthogonal Non-Latin Borders corresponds with 8 * (8!)2 = 13.005.619.200 pairs.

Consequently 13728 * 13.005.619.200 = 1,78541 1014 Bordered Magic Squares with Pan Magic Composed Magic Center Squares can be constructed, based on the pair of order 10 Orthogonal Non-Latin Borders shown above.

10.2.6 Composed Magic Squares

Magic Center Cross (2 x 10)

Pairs of Non-Latin but Orthogonal Borders (A', B'), can be transformed to pairs of Non-Latin but Orthogonal Center Crosses (A, B), which can be completed with pairs of order 4 Orthogonal Latin-Diagonal Squares (A4, B4).

Following numerical example is based on Pan Magic Sub Squares and the balanced Sub Series {1 ... 8}:

A
8 4 5 1 3 6 3 2 7 6
1 5 4 8 9 0 6 7 2 3
4 8 1 5 9 0 2 3 6 7
5 1 8 4 0 9 7 6 3 2
6 5 4 9 0 9 0 9 2 1
3 4 5 0 0 9 9 0 7 8
8 4 5 1 9 0 3 2 7 6
1 5 4 8 0 9 6 7 2 3
4 8 1 5 8 1 2 3 6 7
5 1 8 4 7 2 7 6 3 2
B
8 1 4 5 9 0 8 1 4 5
4 5 8 1 7 2 4 5 8 1
5 4 1 8 6 3 5 4 1 8
1 8 5 4 6 3 1 8 5 4
9 9 9 8 0 0 8 2 0 0
0 0 0 1 9 9 1 7 9 9
3 6 2 7 4 5 3 6 2 7
2 7 3 6 4 5 2 7 3 6
7 2 6 3 0 9 7 2 6 3
6 3 7 2 0 9 6 3 7 2
M = A + 10 * B + 1
89 15 46 52 94 7 84 13 48 57
42 56 85 19 80 21 47 58 83 14
55 49 12 86 70 31 53 44 17 88
16 82 59 45 61 40 18 87 54 43
97 96 95 90 1 10 81 30 3 2
4 5 6 11 91 100 20 71 98 99
39 65 26 72 50 51 34 63 28 77
22 76 35 69 41 60 27 78 33 64
75 29 62 36 9 92 73 24 67 38
66 32 79 25 8 93 68 37 74 23

Each pair of order 10 Orthogonal Non-Latin Center Crosses corresponds with 8 * (8!)2 = 13.005.619.200 pairs.

Consequently 87552 * 13.005.619.200 = 1,13867 1015 Composed Magic Squares can be constructed, based on the pair of order 10 Orthogonal Non-Latin Center Crosses shown above.

10.2.7 Inlaid Magic Squares

Order 10 Inlaid Magic Squares with order 3 Simple Magic Square Inlays based on Latin Squares have been discussed in Section 10.4.2.

Order 10 Inlaid Magic Squares with order 4 Pan Magic Square Inlays based on Latin Diagonal Squares have been discussed in Section 10.4.3.

10.3   Magic Squares, Prime Numbers

10.3.1 Simple Magic Squares

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

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

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

Sa = 7026
1 5 71 145 551 581 841 1085 1471 2275
5 841 2275 1085 1 71 1471 551 145 581
145 1 5 841 1085 551 2275 1471 581 71
71 1085 145 581 1471 5 1 2275 551 841
1471 551 1 5 2275 841 145 581 71 1085
581 71 551 2275 5 1471 1085 145 841 1
1085 145 841 71 581 2275 551 5 1 1471
841 2275 1085 1471 145 1 581 71 5 551
2275 581 1471 551 841 145 71 1 1085 5
551 1471 581 1 71 1085 5 841 2275 145
Sb = 7764
12 18 96 192 276 396 612 1548 2238 2376
2238 1548 612 396 2376 12 276 192 96 18
18 96 192 276 12 2376 396 612 1548 2238
2376 2238 1548 612 396 276 192 96 18 12
1548 612 396 2376 18 2238 12 276 192 96
192 276 12 2238 1548 96 18 2376 396 612
612 396 2376 18 96 1548 2238 12 276 192
96 192 276 12 2238 18 2376 396 612 1548
276 12 18 96 192 612 1548 2238 2376 396
396 2376 2238 1548 612 192 96 18 12 276
Sm = 14790
13 23 167 337 827 977 1453 2633 3709 4651
2243 2389 2887 1481 2377 83 1747 743 241 599
163 97 197 1117 1097 2927 2671 2083 2129 2309
2447 3323 1693 1193 1867 281 193 2371 569 853
3019 1163 397 2381 2293 3079 157 857 263 1181
773 347 563 4513 1553 1567 1103 2521 1237 613
1697 541 3217 89 677 3823 2789 17 277 1663
937 2467 1361 1483 2383 19 2957 467 617 2099
2551 593 1489 647 1033 757 1619 2239 3461 401
947 3847 2819 1549 683 1277 101 859 2287 421

Attachment 10.3 contains miscellaneous correlated series {ai, i = 1 ... 10} and {bj, j = 1 ... 10).

Attachment 10.3.1 contains the resulting Prime Number Simple Magic Squares for miscellaneous Magic Sums (Sm).

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

10.3.2 Symmetric Magic Squares

Prime Number Symmetric Magic Squares require that the series {ai, i = 1 ... 10} and {bj, j = 1 ... 10) of a valid pair of Orthogonal Latin Diagonal Squares (A, B) comply with following conditions:

  • mij = ai + bj = prime for i = 1 ... 10 and j = 1 ... 10 (correlated)
  • a1 + a10 = a2 + a9 = a3 + a8 = a4 + a7 = a5 + a6        (balanced)
    b1 + b10 = b2 + b9 = b3 + b8 = b4 + b7 = b5 + b6

Such order 10 Correlated Balanced Magic Series, resulting in Prime Number Symmetric Magic Squares, have not yet been found.

10.4   Summary

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

Attachment

Subject

Subroutine

Attachment 10.2.2

Simple Magic Square M based on (A, T(A))

-

Attachment 10.24.1

Semi-Latin Associated Borders

AssBrdr10

-

-

-

Attachment 10.3

Correlated Series

-

Attachment 10.3.1

Prime Number Simple Magic Squares

CnstrSqrs10b

-

-

-

Comparable methods as described above, can be used to construct order 11 (Semi) Latin - and related (Pan) Magic Squares, which will be described in following sections.


Vorige Pagina Volgende Pagina Index About the Author