A036799 a(n) = 2 + 2^(n+1)*(n-1).
0, 2, 10, 34, 98, 258, 642, 1538, 3586, 8194, 18434, 40962, 90114, 196610, 425986, 917506, 1966082, 4194306, 8912898, 18874370, 39845890, 83886082, 176160770, 369098754, 771751938, 1610612738, 3355443202, 6979321858, 14495514626, 30064771074, 62277025794
Offset: 0
References
- M. Petkovsek et al., A=B, Peters, 1996, p. 97.
Links
- Reinhard Zumkeller, Table of n, a(n) for n = 0..1000
- R. K. Guy, Catwalks, sandsteps and Pascal pyramids, J. Integer Sequences, Vol. 3 (2000), Article #00.1.6.
- Jia Huang, Partially Palindromic Compositions, J. Int. Seq. (2023) Vol. 26, Art. 23.4.1. See pp. 3, 4, 9.
- Problem Selection Committee for the 2014 IMO, Shortlisted Problems with Solutions for the 55th International Mathematical Olympiad. See pp. 9, 68-70.
- Stanislav Sykora, Finite and Infinite Sums of the Power Series (k^p)(x^k), DOI 10.3247/SL1Math06.002, Section V.
- Index entries for linear recurrences with constant coefficients, signature (5,-8,4).
Programs
-
Haskell
a036799 n = (n-1)*2^(n+1) + 2 -- Reinhard Zumkeller, May 24 2012
-
Magma
[2+2^(n+1)*(n-1) : n in [0..40]]; // Wesley Ivan Hurt, Nov 12 2015
-
Maple
A036799:=n->2+2^(n+1)*(n-1): seq(A036799(n), n=0..40); # Wesley Ivan Hurt, Nov 12 2015
-
Mathematica
Accumulate[Table[n*2^n, {n, 0, 40}]] (* Vladimir Joseph Stephan Orlovsky, Jul 09 2011 *)
-
PARI
a(n)=2+(n-1)<<(n+1) \\ Charles R Greathouse IV, Sep 28 2015
-
PARI
concat(0, Vec(2*x/((1-x)*(1-2*x)^2) + O(x^40))) \\ Altug Alkan, Nov 09 2015
-
Sage
[2^(n+1)*(n-1) +2 for n in (0..40)] # G. C. Greubel, Mar 29 2021
Formula
a(n) = (n-1) * 2^(n+1) + 2.
a(n) = 2 * A000337(n).
a(n) = Sum_{k=1..n} k*2^k. - Benoit Cloitre, Oct 25 2002
G.f.: 2*x/((1-x)*(1-2*x)^2). - Colin Barker, Apr 30 2012
a(n) = 5*a(n-1) - 8*a(n-2) + 4*a(n-3) for n > 2. - Wesley Ivan Hurt, Nov 12 2015
a(n) = Sum_{k=0..n} Sum_{i=0..n} k * binomial(k,i). - Wesley Ivan Hurt, Sep 21 2017
E.g.f.: 2*exp(x) - 2*(1-2*x)*exp(2*x). - G. C. Greubel, Mar 29 2021
Comments