OFFSET
1,1
COMMENTS
A pandiagonal square of order 4 consists of 8 pairs of complementary numbers with the sum in each pair equal to S/2 (where S is the magic constant). For example, the array {7, 113, 11, 109, 13, 107, 17, 103, 19, 101, 23, 97, 31, 89, 37, 83, 41, 79, 47, 73, 53, 67, 59, 61} consists of 12 complementary prime pairs with the sum 7 + 113 = 11 + 109 = ... = 59 + 61 = 120 = S/2.
Pandiagonal squares of order 4 are also the most-perfect squares.
There is a one-to-one correspondence between pandiagonal and associative magic squares of order 4. Any pandiagonal square can be turned into an associative square by rearrangements of its rows and columns, and vice versa.
For example, pandiagonal square:
[ 13 83 31 113
97 47 79 17
89 7 107 37
41 103 23 73 ]
the corresponding associative square:
[ 13 83 113 31
97 47 17 79
41 103 73 23
89 7 37 107]
Magic constants of pandiagonal magic squares of order 4 are always multiples of 4. It looks as though most sufficiently large multiples of 4 are magic constants of some pandiagonal magic squares of order 4. For multiples of 4 between 3000 and 10000, only 3028, 3208, 3436, 3664, 4436, 4504, and 5116 are not the magic constant of any pandiagonal magic squares of order 4. - Zhao Hui Du, Jan 09 2024
LINKS
Max Alekseyev, Table of n, a(n) for n = 1..100
Natalia Makarova, Order-4 pandiagonal magic squares composed of primes (in Russian)
EXAMPLE
a(3)=288 for the matrix
[ 7 127 41 113
71 83 37 97
103 31 137 17
107 47 73 61 ]
CROSSREFS
KEYWORD
nonn
AUTHOR
Natalia Makarova, Jun 05 2011
EXTENSIONS
Terms a(18) onward from Max Alekseyev, May 26 2012
STATUS
approved