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

A368345
a(n) = Sum_{k=0..n} 4^(n-k) * floor(k/3).
1
0, 0, 0, 1, 5, 21, 86, 346, 1386, 5547, 22191, 88767, 355072, 1420292, 5681172, 22724693, 90898777, 363595113, 1454380458, 5817521838, 23270087358, 93080349439, 372321397763, 1489285591059, 5957142364244, 23828569456984, 95314277827944, 381257111311785
OFFSET
0,5
FORMULA
a(n) = a(n-3) + (4^(n-2) - 1)/3.
a(n) = 1/3 * Sum_{k=0..n} floor(4^k/21) = Sum_{k=0..n} floor(4^k/63).
a(n) = 5*a(n-1) - 4*a(n-2) + a(n-3) - 5*a(n-4) + 4*a(n-5).
G.f.: x^3/((1-x) * (1-4*x) * (1-x^3)).
a(n) = (floor(4^(n+1)/63) - floor((n+1)/3))/3.
PROG
(PARI) a(n, m=3, k=4) = (k^(n+1)\(k^m-1)-(n+1)\m)/(k-1);
CROSSREFS
Partial sums of A033140.
Column k=4 of A368343.
Cf. A097138.
Sequence in context: A272832 A273489 A097113 * A265939 A012814 A039919
KEYWORD
nonn,easy
AUTHOR
Seiichi Manyama, Dec 22 2023
STATUS
approved