Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).
%I #12 Sep 08 2022 08:46:02
%S 1,5,2,16,9,3,42,27,13,4,99,68,38,17,5,219,156,94,49,21,6,466,339,213,
%T 120,60,25,7,968,713,459,270,146,71,29,8,1981,1470,960,579,327,172,82,
%U 33,9,4017,2994,1972,1207,699,384,198,93,37,10,8100,6053,4007,2474,1454,819,441,224,104,41,11
%N Rectangular array: (row n) = b**c, where b(h) = -1 + 2^h, c(h) = n-1+h, n>=1, h>=1, and ** = convolution.
%C Principal diagonal: A213583.
%C Antidiagonal sums: A156928.
%C Row 1, (1,3,7,15,31,...)**(1,2,3,4,5,...): A002662.
%C Row 2, (1,3,7,15,31,...)**(2,3,4,5,6,...)
%C Row 3, (1,3,7,15,31,...)**(3,4,5,6,7,...)
%C For a guide to related arrays, see A213500.
%H Clark Kimberling, <a href="/A213582/b213582.txt">Antidiagonals n = 1..60, flattened</a>
%F T(n,k) = 5*T(n,k-1) - 9*T(n,k-2) + 7*T(n,k-3) - 2*T(n,k-4).
%F G.f. for row n: f(x)/g(x), where f(x) = n - (n-1)*x and g(x) = (1-2*x) *(1-x)^3.
%F T(n,k) = 2*(n+1)*(2^k - 1) - k*(k + 2*n + 3)/2. - _G. C. Greubel_, Jul 08 2019
%e Northwest corner (the array is read by falling antidiagonals):
%e 1...5....16...42....99....219
%e 2...9....27...68....156...339
%e 3...13...38...94....213...459
%e 4...17...49...120...270...579
%e 5...21...60...146...327...699
%e 6...25...71...172...384...819
%t (* First program *)
%t b[n_]:= 2^n - 1; c[n_]:= n;
%t T[n_, k_]:= Sum[b[k-i] c[n+i], {i, 0, k-1}]
%t TableForm[Table[T[n, k], {n, 1, 10}, {k, 1, 10}]]
%t Flatten[Table[T[n-k+1, k], {n, 12}, {k, n, 1, -1}]] (* A213582 *)
%t r[n_]:= Table[T[n, k], {k, 40}]
%t Table[T[n, n], {n, 1, 40}] (* A213583 *)
%t s[n_]:= Sum[T[i, n+1-i], {i, 1, n}]
%t Table[s[n], {n, 1, 50}] (* A156928 *)
%t (* Second program *)
%t Table[2*(k+1)*(2^(n-k+1) -1) -(n-k+1)*(n+k+4)/2, {n, 12}, {k, n}]//Flatten (* _G. C. Greubel_, Jul 08 2019 *)
%o (PARI) t(n,k) = 2*(k+1)*(2^(n-k+1) -1) -(n-k+1)*(n+k+4)/2;
%o for(n=1,12, for(k=1,n, print1(t(n,k), ", "))) \\ _G. C. Greubel_, Jul 08 2019
%o (Magma) [[2*(k+1)*(2^(n-k+1) -1) -(n-k+1)*(n+k+4)/2: k in [1..n]]: n in [1..12]]; // _G. C. Greubel_, Jul 08 2019
%o (Sage) [[2*(k+1)*(2^(n-k+1) -1) -(n-k+1)*(n+k+4)/2 for k in (1..n)] for n in (1..12)] # _G. C. Greubel_, Jul 08 2019
%o (GAP) Flat(List([1..12], n-> List([1..n], k-> 2*(k+1)*(2^(n-k+1) -1) -(n-k+1)*(n+k+4)/2 ))) # _G. C. Greubel_, Jul 08 2019
%Y Cf. A213500, A213571.
%K nonn,tabl,easy
%O 1,2
%A _Clark Kimberling_, Jun 19 2012