OFFSET
0,4
COMMENTS
The digital sum analog (in base 4) of the Fibonacci recurrence.
When starting from index n=3, periodic with Pisano period A001175(3)=8.
For general bases p>2, the inequality 2<=a(n)<=2p-3 holds for n>2. Actually, a(n)<=5=A131319(4) for the base p=4.
a(n) and Fib(n)=A000045(n) are congruent modulo 3 which implies that (a(n) mod 3) is equal to (Fib(n) mod 3)=A082115(n-1) (for n>0). Thus (a(n) mod 3) is periodic with the Pisano period = A001175(3)=8 too. - Hieronymus Fischer
LINKS
FORMULA
EXAMPLE
a(8)=3, since a(6)=5=11(base 4), ds_4(5)=2,
a(7)=4=10(base 4), ds_4(4)=1 and so a(8)=2+1.
MATHEMATICA
nxt[{a_, b_}]:={b, Total[IntegerDigits[a, 4]]+Total[IntegerDigits[b, 4]]}; NestList[ nxt, {0, 1}, 110][[All, 1]] (* Harvey P. Dale, Jul 30 2018 *)
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Hieronymus Fischer, Jun 27 2007
STATUS
approved