OFFSET
0,17
FORMULA
EXAMPLE
The array starts:
[n\k][0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, ...]
[0] 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, ... = A000004
[1] 0, -1, 1, 0, 2, 1, 3, 2, 4, 3, 5, 4, ... = A028242(n-2)
[2] -1, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, ... = A023443(n)
[3] 0, 0, 3, 3, 6, 6, 9, 9, 12, 12, 15, 15, ... = 3*A004526(n)
[4] 0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 22, ... = A005843(n)
[5] 2, 3, 7, 8, 12, 13, 17, 18, 22, 23, 27, 28, ... = A047221(n+1)
[6] 3, 6, 9, 12, 15, 18, 21, 24, 27, 30, 33, 36, ... = A008585(n+1)
[7] 6, 8, 13, 15, 20, 22, 27, 29, 34, 36, 41, 43, ... = A047336(n+2)
[8] 8, 12, 16, 20, 24, 28, 32, 36, 40, 44, 48, 52, ... = A008586(n+2)
Successive columns: A198442(n-2), A198442(n-1), A004652(n), A198442(n+1), A198442(n+2), A079524(n), ... .
First subdiagonal: 0, 0, 3, 6, ... = A242477(n).
First upperdiagonal: 0, 1, 2, 6, 10, ... = A238377(n-1).
Array written as a triangle:
0;
0, 0;
0, -1, -1;
0, 1, 0, 0;
0, 0, 1, 0, 0;
0, 2, 2, 3, 2, 2;
etc.
MAPLE
A := proc(n, k) option remember; local h;
h := n -> `if`(n<3, [0, 0, -1][n+1], iquo(n^2-4*n+3, 4));
if k = 0 then h(n) elif k = 1 then h(n+1) else A(n, k-2) + n fi end: # Peter Luschny, Sep 08 2018
MATHEMATICA
h[n_] := If[n < 3, {0, 0, -1}[[n + 1]], Quotient[n^2 - 4 n + 3, 4]];
A[n_, k_] := A[n, k] = If[k == 0, h[n], If[k == 1, h[n+1], A[n, k-2] + n]];
Table[A[n - k, k], {n, 0, 11}, {k, n, 0, -1}] // Flatten (* Jean-François Alcover, Jul 22 2019, after Peter Luschny *)
CROSSREFS
KEYWORD
sign,tabl
AUTHOR
Paul Curtz, Sep 06 2018
STATUS
approved