login
A049801
Triangular array T, read by rows: T(n,k) = n mod floor(k/3), k = 3..n and n >= 3.
4
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 1, 1, 1, 2, 2, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 2, 2, 2, 2, 2, 2, 0, 0, 0, 1, 1, 1, 0, 0, 0, 3, 3, 3, 0
OFFSET
3,43
EXAMPLE
Array T(n,k) (with rows n >= 3 and columns k >= 3) begins as follows:
0;
0, 0;
0, 0, 0;
0, 0, 0, 0;
0, 0, 0, 1, 1;
0, 0, 0, 0, 0, 0;
0, 0, 0, 1, 1, 1, 0;
0, 0, 0, 0, 0, 0, 1, 1;
0, 0, 0, 1, 1, 1, 2, 2, 2;
0, 0, 0, 0, 0, 0, 0, 0, 0, 0;
0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1;
0, 0, 0, 0, 0, 0, 2, 2, 2, 2, 2, 2;
...
MAPLE
# To get the sequence:
seq(seq(n mod floor(k/3), k = 3..n), n = 3..30);
# To get the triangular array:
for n from 3 to 30 do
seq(n mod floor(k/3), k = 3..n);
end do; # Petros Hadjicostas, Nov 20 2019
MATHEMATICA
Table[Mod[n, Floor[k/3]], {n, 3, 15}, {k, 3, n}]//Flatten (* G. C. Greubel, Dec 09 2019 *)
PROG
(PARI) T(n, k) = lift(Mod(n, k\3)); \\ G. C. Greubel, Dec 09 2019
(Magma) [ n mod Floor(k/3): k in [3..n], n in [3..15]]; // G. C. Greubel, Dec 09 2019
(Sage) [[ mod(n, floor(k/3)) for k in (3..n)] for n in (3..15)] # G. C. Greubel, Dec 09 2019
(GAP) Flat(List([3..15], n-> List([3..n], k-> n mod Int(k/3) ))); # G. C. Greubel, Dec 09 2019
CROSSREFS
Row sums are in A049799.
Sequence in context: A356816 A016414 A049337 * A076953 A180472 A308583
KEYWORD
nonn,tabl
EXTENSIONS
Name edited by and more terms from Petros Hadjicostas, Nov 20 2019
STATUS
approved