OFFSET
0,5
EXAMPLE
Triangle begins:
k=0 1 2 3 4
n=0: 1;
n=1: 1, 1;
n=2: 1, 3, 1;
n=3: 1, 4, 4, 1;
n=4: 1, 5, 7, 5, 1;
n=5: ...
MATHEMATICA
T[n_, 0] := T[n, n] = 2; T[n_, k_] := T[n, k] = NextPrime[T[n - 1, k - 1] + T[n - 1, k] - 1]; Table[PrimePi@ T[n, k], {n, 0, 11}, {k, 0, n}]] // Flatten (* Michael De Vlieger, Apr 06 2023 *)
PROG
(PARI) t(n, k) = if (n==0, 2, if (k==0, 2, if (k==n, 2, nextprime(t(n-1, k-1) + t(n-1, k))))); \\ A362034
T(n, k) = primepi(t(n, k)); \\ Michel Marcus, Apr 07 2023
CROSSREFS
KEYWORD
nonn,tabl
AUTHOR
Jack Braxton, Apr 05 2023
STATUS
approved