OFFSET
1,2
LINKS
FORMULA
A(n,k) = A286158(n,k) listed for n >= 1, k = 1 .. n.
EXAMPLE
The first ten rows of this triangular array:
1,
3, 1,
6, 4, 1,
10, 3, 4, 1,
15, 7, 8, 4, 1,
21, 6, 3, 8, 4, 1,
28, 11, 7, 13, 8, 4, 1,
36, 10, 12, 3, 13, 8, 4, 1,
45, 16, 6, 7, 19, 13, 8, 4, 1,
55, 15, 11, 12, 3, 19, 13, 8, 4, 1.
MATHEMATICA
Map[((#1 + #2)^2 + 3 #1 + #2)/2 & @@ # & /@ Reverse@ # &, Table[Reverse@ QuotientRemainder[n, k], {n, 14}, {k, n, 1, -1}]] // Flatten (* Michael De Vlieger, May 20 2017 *)
PROG
(Python)
def T(a, b): return ((a + b)**2 + 3*a + b)/2
def A(n, k): return T(n%k, int(n/k))
for n in range(1, 21): print [A(k, n - k + 1) for k in range(1, n + 1)] # Indranil Ghosh, May 20 2017
CROSSREFS
KEYWORD
nonn,tabl
AUTHOR
Antti Karttunen, May 04 2017
STATUS
approved