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

A283884
Relative of Hofstadter Q-sequence: a(n) = max(0, n+193) for n <= 0; a(n) = a(n-a(n-1)) + a(n-a(n-2)) + a(n-a(n-3)) for n > 0.
5
6, 194, 195, 196, 9, 197, 198, 199, 12, 200, 201, 202, 15, 203, 204, 17, 206, 18, 206, 208, 209, 22, 21, 397, 391, 9, 18, 406, 409, 202, 22, 223, 228, 206, 27, 36, 230, 396, 197, 39, 231, 237, 201, 42, 233, 240, 16, 232, 240, 220, 40
OFFSET
1,1
COMMENTS
Sequences like this are more naturally considered with the first nonzero term in position 1. But this sequence would then match A000027 for its first 193 terms.
Most terms in this sequence appear in long period-5 quasilinear runs. These runs are separated by 441 other terms, and each run is approximately six times as long as the previous.
FORMULA
If the index is between 67 and 195 (inclusive), then a(7n) = 7n+2, a(7n+1) = 7n+195, a(7n+2) = 7n+197, a(7n+3) = 7, a(7n+4) = 2n+431, a(7n+5) = n+379, a(7n+6) = 191.
For nonnegative integers i, if 1<=5n+r<=(2417/5)*6^(i+1)-3382/5, then
a((2417/5)*6^i-1177/5+5n) = 5
a((2417/5)*6^i-1177/5+5n+1) = (7251/5)*6^i - 2046/5 + 3n
a((2417/5)*6^i-1177/5+5n+2) = 3
a((2417/5)*6^i-1177/5+5n+3) = (2417/5)*6^i - 1162/5 + 5n
a((2417/5)*6^i-1177/5+5n+4) = (7251/5)*6^i - 2041/5 + 3n.
MAPLE
A283884:=proc(n) option remember: if n <= 0 then max(0, n+193): else A283884(n-A283884(n-1)) + A283884(n-A283884(n-2)) + A283884(n-A283884(n-3)): fi: end:
KEYWORD
nonn,look
AUTHOR
Nathan Fox, Mar 19 2017
STATUS
approved