OFFSET
1,2
COMMENTS
An order n triangle contains binomial(n,2) upright 2 X 2 subtriangles and binomial(n-2,2) inverted 2 X 2 subtriangles. In total, there are n^2-3*n+3 subtriangles.
It seems that the sequence is likely finite. Considering each of the n^2! possibilities of arranging 1..n^2, for each of the (n^2-3n+3) subtriangles only one choice for the central value can give the magic sum. We should, therefore, divide (n^2)! by (n^2)^(n^2-3*n+3) to calculate an estimation of a(n). For n >= 16, (n^2)!/(n^2)^(n^2-3*n+3) < 1.
For n >= 3, a(n) is a multiple of 8, because swapping between a corner triangle and an edge-adjacent triangle generate different examples,
Disregarding corner swap, a(3) to a(6) would be "18, 4792, 67488, 10906128"
LINKS
Donghwi Park, Source code for a(4).
Donghwi Park, Source code for a(5).
EXAMPLE
a(1)=1 because there is only the trivial case without any subtriangle.
a(2)=4 because we can choose only the number in the central triangle.
a(3)=18, which is same for A342467(4)*8. Trotter's order 4 magic triangle can be transformed to this order-3 magic triangle disregarding corner swap.
For n = 3, numbers 1..9 are placed inside the triangles shown:
o
/ \
o-- o
/ \ / \
o---o---o
/ \ / \ / \
o---o---o---o
An example with magic sum=17:
9
5
1 2
6 4
7 3 8
This corresponds to the magic perimeter triangle (A342467):
1 9 5 2
7 4
6 8
3
CROSSREFS
KEYWORD
nonn,more,hard
AUTHOR
Donghwi Park, Aug 15 2024
STATUS
approved