login
A249032
First differences of A075326.
4
3, 6, 4, 5, 5, 6, 4, 6, 4, 6, 4, 5, 5, 6, 4, 5, 5, 6, 4, 5, 5, 6, 4, 6, 4, 6, 4, 5, 5, 6, 4, 6, 4, 6, 4, 5, 5, 6, 4, 6, 4, 6, 4, 5, 5, 6, 4, 5, 5, 6, 4, 5, 5, 6, 4, 6, 4, 6, 4, 5, 5, 6, 4, 5, 5, 6, 4, 5, 5, 6, 4, 6, 4, 6, 4, 5, 5, 6, 4, 5, 5, 6, 4, 5, 5, 6
OFFSET
0,1
COMMENTS
Can be constructed as follows. Apart from the initial "3", one always has either "6-4" (i.e., a 6 followed by a 4), or else "5-5". The 6-4's always come either alone (6-4) or triply (6-4, 6-4, 6-4), while the 5-5's always come alone. So if we let "6-4, 5-5" be represented by the numeral "1", and "6-4, 6-4, 6-4, 5-5" by the numeral "3", then the sequence of first differences, in this compressed code, is A080426, which itself is defined by a simple substitution rule. - D. R. Hofstadter, Oct 23 2014
LINKS
D. R. Hofstadter, Anti-Fibonacci numbers, Oct 23 2014
Thomas Zaslavsky, Anti-Fibonacci Numbers: A Formula, Sep 26 2016
PROG
(Haskell)
a249032 n = a249032_list !! n
a249032_list = zipWith (-) (tail a075326_list) a075326_list
-- Reinhard Zumkeller, Oct 26 2014
(Python)
def A249032(n): return 4+int((n+1|(~((m:=n>>1)+1)&m).bit_length())&1^1)+int((n|(~((k:=n-1>>1)+1)&k).bit_length())&1) if n else 3 # Chai Wah Wu, Sep 11 2024
CROSSREFS
KEYWORD
nonn
AUTHOR
N. J. A. Sloane, Oct 26 2014
STATUS
approved