login
A334654
Number of equilateral triangles of edge length square root of 2n and having vertices in Z^4, one of which is the origin.
0
96, 96, 672, 96, 1152, 672, 1344, 96, 3264, 1152, 2304, 672, 2496, 1344, 8064, 96, 3456, 3264, 3648, 1152, 9408, 2304, 4608, 672, 9312, 2496, 13632, 1344, 5760, 8064, 5952, 96, 16128, 3456, 16128, 3264, 7104, 3648, 17472, 1152, 8064, 9408, 8256, 2304, 39168, 4608
OFFSET
1,1
COMMENTS
A parity argument shows that the edge length of an equilateral triangle with vertices in Z^4 must be the square root of an even integer.
A characterization of the planes in which an equilateral triangle with vertices in Z^4 can lie is given in the Ionascu reference.
LINKS
E.J. Ionascu, Equilateral triangles in Z^4, arXiv:1209.0147 [math.NT], 2012-2013; Vietnam J. Math. 43 (3) (2015), 525-539.
FORMULA
a(2n) = a(n).
MATHEMATICA
a[n_] := a[n] = If[ EvenQ[n], a[n/2], Block[{p, c=0, v = Tuples[ {1, -1}, 4]}, p = Union@ Flatten[ Table[ Union[ Permutations /@ ((q #) & /@ v)], {q, PowersRepresentations[2 n, 4, 2]}], 2]; Do[ If[ Total[ (p[[i]] - p[[j]])^2] == 2 n, c++], {i, Length@ p}, {j, i-1}]; c]]; Array[a, 30] (* Giovanni Resta, May 08 2020 *)
CROSSREFS
Sequence in context: A252715 A050277 A090221 * A045528 A181470 A306104
KEYWORD
nonn
AUTHOR
Matt Noble and Will Farran, May 07 2020
STATUS
approved