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

A343376
a(0) = 0, a(1) = 1. For n >= 2, a(n) = a(n-1)/(n-1) if n-1 divides a(n-1); otherwise, a(n) = a(n-1) + a(n-2).
5
0, 1, 1, 2, 3, 5, 1, 6, 7, 13, 20, 2, 22, 24, 46, 70, 116, 186, 302, 488, 790, 1278, 2068, 94, 2162, 2256, 4418, 6674, 11092, 17766, 28858, 46624, 1504, 47, 1551, 1598, 3149, 4747, 7896, 12643, 20539, 33182, 53721, 86903, 2021, 88924, 90945, 179869, 3827, 183696
OFFSET
0,4
COMMENTS
a(n) = A000045(n) for n = 0,1,2,3,4,5 and a(n) = A139047(n-1) for n = 1,2,3,...,10. Also, a(n) = n for n = 0,1,5 and a(n) < n for n = 2,3,4,6,7,8,11.
The values of n for which n divides a(n) are given in A343456 and the corresponding quotients are given in A343457.
If r and s are consecutive terms from A343456, then a(r+1) will divide the terms a(r) through a(s). Proof: Clearly, a(r+1) divides itself. Since a(r+1) = a(r)/r implies that r = a(r)/a(r+1), a(r+1) divides a(r). So, a(r+2) = a(r+1)+a(r) is also divisible by a(r+1). Similarly, the remaining terms a(r+3) = a(r+2)+a(r+1) through a(s) = a(s-1)+a(s-2) will also be divisible by a(r+1). QED
Example: a(r) = a(43) = 86903 = 2021*43 = a(44)*(1*43+0)
a(44) = 2021 = 2021* 1 = a(44)*(0*43+1)
a(45) = 88924 = 2021*44 = a(44)*(1*43+1)
a(46) = 90945 = 2021*45 = a(44)*(1*43+2)
a(s) = a(47) = 179869 = 2021*89 = a(44)*(2*43+3).
Notice that the values b and c in a(43+k) = a(44)*(b*43+c) for k = 0,1,2,3,4 follow the extended Fibonacci sequence A212804. In general, any run of terms a(r) through a(s) between successive divisions will be given by a(r+k) = a(r+1)*(A212804(k)*r+A212804(k+1)) for k = 0,1,2,...,s-r.
2 divides a(10) through a(32), 3 divides a(134) through a(144), 5 and 7 divide a(116) through a(140), and 11 divides a(89) through a(297). Conjecture: For any prime p, there exist r and s = k*p from A343456 for which p divides a(r) through a(s).
LINKS
EXAMPLE
a(2) = a(1)/1 = 1, a(3) = a(2)+a(1) = 2, a(4) = a(3)+a(2) = 3, a(5) = a(4)+a(3) = 5, a(6) = a(5)/5 = 1, a(7) = a(6)+a(5) = 6, ...
MAPLE
a:= proc(n) option remember; local q; `if`(n<2, n,
`if`(irem(a(n-1), n-1, 'q')=0, q, a(n-1)+a(n-2)))
end:
seq(a(n), n=0..50); # Alois P. Heinz, Apr 21 2021
MATHEMATICA
Block[{a = {0, 1}}, Do[AppendTo[a, If[Mod[#, i] == 0, #/i, # + a[[-2]] ]] &@ a[[-1]], {i, 48}]; a] (* Michael De Vlieger, Apr 22 2021 *)
PROG
(PARI) lista(nn) = {my(va = vector(nn)); va[1] = 1; for (n=2, nn, if (va[n-1] % (n-1), va[n] = va[n-1] + va[n-2], va[n] = va[n-1]/(n-1)); ); concat(0, va); } \\ Michel Marcus, Apr 20 2021
(Python)
a = [0, 1]
print("0 0")
print("1 1")
for n in range (2, 101):
if a[n-1] % (n - 1) == 0: a.append(a[n-1]//(n-1))
else: a.append(a[n-1] + a[n-2])
print(n, a[n]) # Karl-Heinz Hofmann, Apr 23 2021
CROSSREFS
KEYWORD
nonn
AUTHOR
Timothy L. Tiffin, Apr 13 2021
STATUS
approved