login

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”).

A368346
a(n) = Sum_{k=0..n} 2^(n-k) * floor(k/4).
2
0, 0, 0, 0, 1, 3, 7, 15, 32, 66, 134, 270, 543, 1089, 2181, 4365, 8734, 17472, 34948, 69900, 139805, 279615, 559235, 1118475, 2236956, 4473918, 8947842, 17895690, 35791387, 71582781, 143165569, 286331145, 572662298, 1145324604, 2290649216, 4581298440
OFFSET
0,6
FORMULA
a(n) = a(n-4) + 2^(n-3) - 1.
a(n) = Sum_{k=0..n} floor(2^k/15).
a(n) = 3*a(n-1) - 2*a(n-2) + a(n-4) - 3*a(n-5) + 2*a(n-6).
G.f.: x^4/((1-x) * (1-2*x) * (1-x^4)).
a(n) = floor(2^(n+1)/15) - floor((n+1)/4).
PROG
(PARI) a(n, m=4, k=2) = (k^(n+1)\(k^m-1)-(n+1)\m)/(k-1);
(Python)
def A368346(n): return (1<<n+1)//15-(n+1>>2) # Chai Wah Wu, Dec 22 2023
CROSSREFS
Partial sums of A083593.
Sequence in context: A066175 A132978 A336976 * A117079 A026745 A139333
KEYWORD
nonn,easy
AUTHOR
Seiichi Manyama, Dec 22 2023
STATUS
approved