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

A298356
a(n) = a(n-1) + a(n-2) + a([n/2]) + a([n/3]) + ... + a([n/n]), where a(0) = 1, a(1) = 1, a(2) = 1.
2
1, 1, 1, 4, 8, 16, 32, 57, 103, 178, 308, 514, 874, 1441, 2394, 3926, 6462, 10531, 17231, 28001, 45614, 74026, 120258, 194903, 316210, 512171, 830007, 1343883, 2176578, 3523150, 5704107, 9231637, 14942711, 24181525, 39135483, 63328289, 102482212, 165828942
OFFSET
0,4
COMMENTS
a(n)/a(n-1) -> (1 + sqrt(5))/2, the golden ratio (A001622), so that (a(n)) has the growth rate of the Fibonacci numbers (A000045). See A298338 for a guide to related sequences.
LINKS
MATHEMATICA
a[0] = 1; a[1] = 1; a[2] = 1;
a[n_] := a[n] = a[n - 1] + a[n - 2] + Sum[a[Floor[n/k]], {k, 2, n}];
Table[a[n], {n, 0, 30}] (* A298356 *)
PROG
(Python)
from functools import lru_cache
@lru_cache(maxsize=None)
def A298356(n):
if n <= 2:
return 1
c, j = A298356(n-1)+A298356(n-2), 2
k1 = n//j
while k1 > 1:
j2 = n//k1 + 1
c += (j2-j)*A298356(k1)
j, k1 = j2, n//j2
return c+n-j+1 # Chai Wah Wu, Mar 31 2021
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Clark Kimberling, Feb 10 2018
STATUS
approved