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

A120164
a(n) = 6 + floor( Sum_{j=1..n-1} a(j)/4 ).
2
6, 7, 9, 11, 14, 17, 22, 27, 34, 42, 53, 66, 83, 103, 129, 161, 202, 252, 315, 394, 492, 615, 769, 961, 1202, 1502, 1878, 2347, 2934, 3667, 4584, 5730, 7163, 8953, 11192, 13990, 17487, 21859, 27324, 34155
OFFSET
1,1
LINKS
MATHEMATICA
f[n_, p_, q_]:= f[n, p, q]= p +Quotient[q +Sum[f[k, p, q], {k, n-1}], 4];
A120164[n_]:= f[n, 6, 0];
Table[A120164[n], {n, 60}] (* G. C. Greubel, Sep 05 2023 *)
PROG
(Magma)
function f(n, a, b)
t:=0;
for k in [1..n-1] do
t+:= a+Floor((b+t)/4);
end for;
return t;
end function;
g:= func< n, a, b | f(n+1, a, b)-f(n, a, b) >;
A120164:= func< n | g(n, 6, 0) >;
[A120164(n): n in [1..60]]; // G. C. Greubel, Sep 05 2023
(SageMath)
@CachedFunction
def f(n, p, q): return p + (q +sum(f(k, p, q) for k in range(1, n)))//4
def A120164(n): return f(n, 6, 0)
[A120164(n) for n in range(1, 61)] # G. C. Greubel, Sep 05 2023
CROSSREFS
KEYWORD
nonn
AUTHOR
Graeme McRae, Jun 10 2006
STATUS
approved