OFFSET
0,4
COMMENTS
T(n, k) is the norm of the Eisenstein integer n + k*w (where w = -1/2 + sqrt(-3)/2 is a primitive cube root of unity).
All terms belong to A003136.
LINKS
Rémy Sigrist, Table of n, a(n) for n = 0..10010
Wikipedia, Eisenstein integers: Euclidean domain
FORMULA
T(n, k) = T(k, n).
T(n, 0) = T(n, n) = n^2.
G.f.: (x - 5*x*y + y*(1 + y) + x^2*(1 + y^2))/((1 - x)^3*(1 - y)^3). - Stefano Spezia, Nov 08 2021
EXAMPLE
Array T(n, k) begins:
n\k| 0 1 2 3 4 5 6 7 8 9 10
---+----------------------------------------------
0| 0 1 4 9 16 25 36 49 64 81 100
1| 1 1 3 7 13 21 31 43 57 73 91
2| 4 3 4 7 12 19 28 39 52 67 84
3| 9 7 7 9 13 19 27 37 49 63 79
4| 16 13 12 13 16 21 28 37 48 61 76
5| 25 21 19 19 21 25 31 39 49 61 75
6| 36 31 28 27 28 31 36 43 52 63 76
7| 49 43 39 37 37 39 43 49 57 67 79
8| 64 57 52 49 48 49 52 57 64 73 84
9| 81 73 67 63 61 61 63 67 73 81 91
10| 100 91 84 79 76 75 76 79 84 91 100
MATHEMATICA
T[n_, k_] := n^2 - n*k + k^2; Table[T[k, n - k], {n, 0, 11}, {k, 0, n}] // Flatten (* Amiram Eldar, Nov 08 2021 *)
PROG
(PARI) T(n, k) = n^2 - n*k + k^2
CROSSREFS
KEYWORD
AUTHOR
Rémy Sigrist, Nov 06 2021
STATUS
approved