A059268 Concatenate subsequences [2^0, 2^1, ..., 2^n] for n = 0, 1, 2, ...
1, 1, 2, 1, 2, 4, 1, 2, 4, 8, 1, 2, 4, 8, 16, 1, 2, 4, 8, 16, 32, 1, 2, 4, 8, 16, 32, 64, 1, 2, 4, 8, 16, 32, 64, 128, 1, 2, 4, 8, 16, 32, 64, 128, 256, 1, 2, 4, 8, 16, 32, 64, 128, 256, 512, 1, 2, 4, 8, 16, 32, 64, 128, 256, 512, 1024, 1, 2, 4, 8, 16, 32, 64, 128, 256, 512, 1024, 2048
Offset: 0
Examples
T(4,3)=8 since there are 8 subsets of {0,1,2,3,4} whose largest element is 3, namely, {3}, {0,3}, {1,3}, {2,3}, {0,1,3}, {0,2,3}, {1,2,3}, and {0,1,2,3}. Triangle starts: 1; 1, 2; 1, 2, 4; 1, 2, 4, 8; 1, 2, 4, 8, 16; 1, 2, 4, 8, 16, 32; ...
Links
- Reinhard Zumkeller, Rows n = 0..150 of triangle, flattened
- J. L. Arregui, Tangent and Bernoulli numbers related to Motzkin and Catalan numbers by means of numerical triangles, arXiv:math/0109108 [math.NT], 2001.
- Boris Putievskiy, Transformations Integer Sequences And Pairing Functions arXiv:1212.2732 [math.CO], 2012.
Programs
-
Haskell
a059268 n k = a059268_tabl !! n !! k a059268_row n = a059268_tabl !! n a059268_tabl = iterate (scanl (+) 1) [1] -- Reinhard Zumkeller, Apr 18 2013, Jul 05 2012
-
Maple
seq(seq(2^k,k=0..n),n=0..10);
-
Mathematica
Table[2^k, {n, 0, 11}, {k, 0, n}] // Flatten (* Jean-François Alcover, Jun 10 2013 *)
-
Python
from math import isqrt def A059268(n): a = (m:=isqrt(k:=n+1<<1))-(k<=m*(m+1)) return 1<
>1) # Chai Wah Wu, Feb 24 2025
Formula
E.g.f.: exp(x+2*y) (T coordinates).
T(n,k) = 2^k. - Reinhard Zumkeller, Jan 29 2010
As a linear array, the sequence is a(n) = 2^(n-1-t*(t+1)/2), where t = floor((-1+sqrt(8*n-7))/2), n>=1. - Boris Putievskiy, Dec 17 2012
As a linear array, the sequence is a(n) = 2^(n-1-t*(t+1)/2), where t = floor(sqrt(2*n)-1/2), n>=1. - Zhining Yang, Jun 09 2017
Extensions
Formula corrected by Reinhard Zumkeller, Feb 23 2010
Comments