login
a(n) = Sum_{k=0..10} binomial(n,k).
15

%I #47 Jun 24 2023 13:25:14

%S 1,2,4,8,16,32,64,128,256,512,1024,2047,4083,8100,15914,30827,58651,

%T 109294,199140,354522,616666,1048576,1744436,2842226,4540386,7119516,

%U 10970272,16628809,24821333,36519556,53009102,75973189,107594213,150676186,208791332

%N a(n) = Sum_{k=0..10} binomial(n,k).

%C a(n) is the number of compositions (ordered partitions) of n+1 into eleven or fewer parts. - _Geoffrey Critzer_, Jan 24 2009

%C a(n) is the maximal number of regions in 10-space formed by n-1 9-dimensional hypercubes. Also the number of binary words of length n matching the regular expression 0*1*0*1*0*1*0*1*0*1*0*. A000124, A000125, A000127, A006261, A008859, A008860, A008861, A008862 count binary words of the form 0*1*0*, 1*0*1*0*, 0*1*0*1*0*, 1*0*1*0*1*0*, 0*1*0*1*0*1*0*, 1*0*1*0*1*0*1*0*, 0*1*0*1*0*1*0*1*0* and 1*0*1*0*1*0*1*0*1*0* respectively. - _Manfred Scheucher_, Jun 23 2023

%D L. Comtet, Advanced Combinatorics, Reidel, 1974, p. 72, Problem 2.

%H T. D. Noe, <a href="/A008863/b008863.txt">Table of n, a(n) for n = 0..1000</a>

%H <a href="/index/Rec#order_11">Index entries for linear recurrences with constant coefficients</a>, signature (11,-55,165,-330,462,-462,330,-165, 55,-11,1).

%F a(n) = Sum_{k=0..5} binomial(n+1, 2k), compare A008859.

%F From _Geoffrey Critzer_, Jan 24 2009: (Start)

%F G.f.: (1 - 9*x + 37*x^2 - 91*x^3 + 148*x^4 - 166*x^5 + 130*x^6 - 70*x^7 + 25*x^8 - 5*x^9 + x^10)/(1-x)^11.

%F a(n) = (n^10 - 35*n^9 + 600*n^8 - 5790*n^7 + 36813*n^6 - 140595*n^5 + 408050*n^4 - 382060*n^3 + 1368936*n^2 + 2342880*n + 3628800)/10!. (End)

%F a(n) = 11*a(n-1) - 55*a(n-2) + 165*a(n-3) - 330*a(n-4) + 462*a(n-5) - 462*a(n-6) + 330*a(n-7) - 165*a(n-8) + 55*a(n-9) - 11*a(n-10) + a(n-11); a(0)=1, a(1)=2, a(2)=4, a(3)=8, a(4)=16, a(5)=32, a(6)=64, a(7)=128, a(8)=256, a(9)=512, a(10)=1024. - _Harvey P. Dale_, Apr 25 2012

%e a(11) = 2047 because there are 2^11=2048 compositions of 12 into any size parts but one of the compositions (1+1+...+1=12) has more than eleven parts. - _Geoffrey Critzer_, Jan 24 2009

%p A008863:=n->add(binomial(n,k), k=0..10): seq(A008863(n), n=0..40); # _Wesley Ivan Hurt_, Apr 28 2017

%t Table[Sum[Binomial[n, i], {i, 0, 10}], {n, 0, 40}] (* _T. D. Noe_, Mar 27 2012 *)

%t LinearRecurrence[{11,-55,165,-330,462,-462,330,-165,55,-11,1},{1,2,4,8, 16,32,64,128,256,512,1024}, 40] (* _Harvey P. Dale_, Apr 25 2012 *)

%o (Haskell)

%o a008863 = sum . take 11 . a007318_row -- _Reinhard Zumkeller_, Nov 24 2012

%o (Python)

%o A008863_list, m = [], [1, -8, 29, -62, 86, -80, 50, -20, 5, 0, 1]

%o for _ in range(10**2):

%o A008863_list.append(m[-1])

%o for i in range(10):

%o m[i+1] += m[i] # _Chai Wah Wu_, Jan 24 2016

%o (PARI) a(n)=sum(k=0,10,binomial(n,k)) \\ _Charles R Greathouse IV_, Apr 07 2016

%o (Magma) [(&+[Binomial(n,k): k in [0..10]]): n in [0..40]]; // _G. C. Greubel_, Sep 13 2019

%o (Sage) [sum(binomial(n,k) for k in (0..10)) for n in (0..40)] # _G. C. Greubel_, Sep 13 2019

%o (GAP) List([0..40], n-> Sum([0..10], k-> Binomial(n,k)) ); # _G. C. Greubel_, Sep 13 2019

%Y Cf. A008859, A008860, A008861, A008862, A006261, A000127, A007318, A219531.

%K nonn,easy

%O 0,2

%A _N. J. A. Sloane_, _R. K. Guy_