OFFSET
0,9
FORMULA
G.f. of column k: Sum_{j>=1} phi(j) * x^j / (1 - k*x^j).
T(n,k) = A185651(n,k)/k for k > 0.
T(n,k) = Sum_{d|n} phi(n/d)*k^(d - 1).
EXAMPLE
Square array begins:
0, 0, 0, 0, 0, 0, 0, ...
1, 1, 1, 1, 1, 1, 1, ...
1, 2, 3, 4, 5, 6, 7, ...
2, 3, 6, 11, 18, 27, 38, ...
2, 4, 12, 32, 70, 132, 224, ...
4, 5, 20, 85, 260, 629, 1300, ...
2, 6, 42, 260, 1050, 3162, 7826, ...
MATHEMATICA
T[n_, k_] := Sum[If[k == (g = GCD[j, n] - 1) == 0, 1, k^g], {j, 1, n}]; Table[T[k, n - k], {n, 0, 11}, {k, 0, n}] // Flatten (* Amiram Eldar, Apr 17 2021 *)
PROG
(PARI) T(n, k) = sum(j=1, n, k^(gcd(j, n)-1));
(PARI) T(n, k) = if(n==0, 0, sumdiv(n, d, eulerphi(n/d)*k^(d-1)));
CROSSREFS
KEYWORD
nonn,tabl
AUTHOR
Seiichi Manyama, Apr 17 2021
STATUS
approved