### Composite 12x12 magic square (4)

René Chrétien had noticed the 15x15 composite (4) magic square and showed me it is possible to use the method to construct magic squares of even orders as well.

Construct the 12x12 magic square by using 9 proportional 4x4 panmagic squares. The squares are proportional because all 4 panmagic 4x4 squares have the same magic sum of (1/3 x 870 = ) 290. We use the basic key method (4x4) to produce the panmagic 4x4 squares.  As row coordinates don't use 0 up to 3 but use 0 up to (9x4 -/- 1 = ) 35 instead. Take care that the sum of the row coordinates in each 4x4 square is the same  (0+17+18+35 = 1+16+19+34 = 2+15+20+33 = ... = 8+9+26+27 = 70) to get proportional squares.

1x row coordinate +36x column coordinate + 1 = panmagic 4x4 square

 0 17 18 35 0 3 1 2 1 126 55 108 18 35 0 17 3 0 2 1 127 36 73 54 17 0 35 18 2 1 3 0 90 37 144 19 35 18 17 0 1 2 0 3 72 91 18 109 1 16 19 34 0 3 1 2 2 125 56 107 19 34 1 16 3 0 2 1 128 35 74 53 16 1 34 19 2 1 3 0 89 38 143 20 34 19 16 1 1 2 0 3 71 92 17 110 2 15 20 33 0 3 1 2 3 124 57 106 20 33 2 15 3 0 2 1 129 34 75 52 15 2 33 20 2 1 3 0 88 39 142 21 33 20 15 2 1 2 0 3 70 93 16 111 3 14 21 32 0 3 1 2 4 123 58 105 21 32 3 14 3 0 2 1 130 33 76 51 14 3 32 21 2 1 3 0 87 40 141 22 32 21 14 3 1 2 0 3 69 94 15 112 4 13 22 31 0 3 1 2 5 122 59 104 22 31 4 13 3 0 2 1 131 32 77 50 13 4 31 22 2 1 3 0 86 41 140 23 31 22 13 4 1 2 0 3 68 95 14 113 5 12 23 30 0 3 1 2 6 121 60 103 23 30 5 12 3 0 2 1 132 31 78 49 12 5 30 23 2 1 3 0 85 42 139 24 30 23 12 5 1 2 0 3 67 96 13 114 6 11 24 29 0 3 1 2 7 120 61 102 24 29 6 11 3 0 2 1 133 30 79 48 11 6 29 24 2 1 3 0 84 43 138 25 29 24 11 6 1 2 0 3 66 97 12 115 7 10 25 28 0 3 1 2 8 119 62 101 25 28 7 10 3 0 2 1 134 29 80 47 10 7 28 25 2 1 3 0 83 44 137 26 28 25 10 7 1 2 0 3 65 98 11 116 8 9 26 27 0 3 1 2 9 118 63 100 26 27 8 9 3 0 2 1 135 28 81 46 9 8 27 26 2 1 3 0 82 45 136 27 27 26 9 8 1 2 0 3 64 99 10 117

Put the 9 panmagic 4x4 squares together.

12x12 magisch vierkant

 1 126 55 108 2 125 56 107 3 124 57 106 127 36 73 54 128 35 74 53 129 34 75 52 90 37 144 19 89 38 143 20 88 39 142 21 72 91 18 109 71 92 17 110 70 93 16 111 4 123 58 105 5 122 59 104 6 121 60 103 130 33 76 51 131 32 77 50 132 31 78 49 87 40 141 22 86 41 140 23 85 42 139 24 69 94 15 112 68 95 14 113 67 96 13 114 7 120 61 102 8 119 62 101 9 118 63 100 133 30 79 48 134 29 80 47 135 28 81 46 84 43 138 25 83 44 137 26 82 45 136 27 66 97 12 115 65 98 11 116 64 99 10 117

The 12x12 magic square is not fully 2x2 compact. Use the Khajuraho method to swap numbers to get a perfect result.

Most perfect 12x12 square

 3 126 55 106 2 125 56 107 1 124 57 108 127 34 75 54 128 35 74 53 129 36 73 52 90 39 142 19 89 38 143 20 88 37 144 21 70 91 18 111 71 92 17 110 72 93 16 109 6 123 58 103 5 122 59 104 4 121 60 105 130 31 78 51 131 32 77 50 132 33 76 49 87 42 139 22 86 41 140 23 85 40 141 24 67 94 15 114 68 95 14 113 69 96 13 112 9 120 61 100 8 119 62 101 7 118 63 102 133 28 81 48 134 29 80 47 135 30 79 46 84 45 136 25 83 44 137 26 82 43 138 27 64 97 12 117 65 98 11 116 66 99 10 115

The 12x12 magic square is panmagic, (fully) 2x2 compact and each 1/3 row/column/diagonal gives 1/3 of the magic sum.

12x12, Composite (4).xls