OFFSET
0,2
EXAMPLE
The fourth antidiagonal of A376682 is: (7, 2, 0, -1, -2), so a(4) = 12.
MATHEMATICA
nn=12;
t=Table[Take[Differences[NestList[NestWhile[#+1&, #+1, !PrimeQ[#]&]&, 1, 2*nn], k], nn], {k, 0, nn}];
Total/@Table[Abs[t[[j, i-j+1]]], {i, nn}, {j, i}]
CROSSREFS
KEYWORD
nonn
AUTHOR
Gus Wiseman, Oct 15 2024
STATUS
approved