cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A340995 Triangle T(n,k) whose k-th column is the k-fold self-convolution of the Euler totient function phi; triangle T(n,k), n>=0, 0<=k<=n, read by rows.

Original entry on oeis.org

1, 0, 1, 0, 1, 1, 0, 2, 2, 1, 0, 2, 5, 3, 1, 0, 4, 8, 9, 4, 1, 0, 2, 16, 19, 14, 5, 1, 0, 6, 20, 42, 36, 20, 6, 1, 0, 4, 36, 72, 89, 60, 27, 7, 1, 0, 6, 44, 134, 184, 165, 92, 35, 8, 1, 0, 4, 68, 210, 376, 391, 279, 133, 44, 9, 1, 0, 10, 76, 348, 688, 880, 738, 441, 184, 54, 10, 1
Offset: 0

Views

Author

Alois P. Heinz, Feb 01 2021

Keywords

Examples

			Triangle T(n,k) begins:
  1;
  0,  1;
  0,  1,  1;
  0,  2,  2,   1;
  0,  2,  5,   3,   1;
  0,  4,  8,   9,   4,   1;
  0,  2, 16,  19,  14,   5,   1;
  0,  6, 20,  42,  36,  20,   6,   1;
  0,  4, 36,  72,  89,  60,  27,   7,   1;
  0,  6, 44, 134, 184, 165,  92,  35,   8,  1;
  0,  4, 68, 210, 376, 391, 279, 133,  44,  9,  1;
  0, 10, 76, 348, 688, 880, 738, 441, 184, 54, 10, 1;
  ...
		

Crossrefs

Columns k=0-2 give (offsets may differ): A000007, A000010, A065093.
Row sums give A159929.
T(2n,n) gives A340994.

Programs

  • Maple
    T:= proc(n, k) option remember; `if`(k=0, `if`(n=0, 1, 0),
          `if`(k=1, `if`(n=0, 0, numtheory[phi](n)), (q->
           add(T(j, q)*T(n-j, k-q), j=0..n))(iquo(k, 2))))
        end:
    seq(seq(T(n, k), k=0..n), n=0..12);
  • Mathematica
    T[n_, k_] := T[n, k] = If[k == 0, If[n == 0, 1, 0],
         If[k == 1, If[n == 0, 0, EulerPhi[n]], With[{q = Quotient[k, 2]},
         Sum[T[j, q]*T[n - j, k - q], {j, 0, n}]]]];
    Table[Table[T[n, k], {k, 0, n}], {n, 0, 12}] // Flatten (* Jean-François Alcover, Feb 13 2021, after Alois P. Heinz *)

Formula

T(n,k) = [x^n] (Sum_{j>=1} phi(j)*x^j)^k.