

A323756


a(1) = 1; for n >= 2, if a(n1) has not yet been assigned, then a(n1) = 1 and a(2*n1) = 2, otherwise a(2*n) = 3.


0



1, 1, 1, 3, 2, 1, 2, 1, 1, 3, 1, 3, 2, 1, 1, 3, 2, 1, 2, 1, 1, 3, 2, 1, 1, 3, 1, 3, 2, 1, 2, 1, 1, 3, 1, 3, 2, 1, 1, 3, 2, 1, 2, 1, 1, 3, 1, 3, 2, 1, 2, 1, 1, 3, 2, 1, 1, 3, 1, 3, 2, 1, 1, 3, 2, 1, 2, 1, 1, 3, 2, 1, 1, 3, 1, 3, 2, 1, 2, 1, 1, 3, 1, 3, 2, 1, 1, 3, 2, 1, 2, 1, 1, 3, 2, 1, 1, 3, 1, 3
(list;
graph;
refs;
listen;
history;
text;
internal format)



OFFSET

1,4


COMMENTS

A selfgenerating sequence.
By calculation it looks as though lim_{m>oo} (1/m)*Sum_{n=1..m} a(n) = sqrt(3). 3's are at positions 4, 10, 12, 16, 22, 26, 28, 34, 36, 40, 46, 48, 54, 58, 60, 64, 70, 74, 76, 82, 84, 88, 94, 98, 100, ..., which is 2*A059009(n).


LINKS

Table of n, a(n) for n=1..100.
J.P. Allouche, M. Mendès France, Automata and automatic sequences, Lecture 1.


EXAMPLE

a(1) = 1;
for n = 2, a(1) has been assigned: a(1) = 1, thus a(4) = 3;
for n = 3, a(2) is unassigned, thus a(2) = 1 and a(5) = 2;
for n = 4, a(3) is unassigned, thus a(3) = 1 and a(7) = 2; etc.


CROSSREFS

Cf. A059009.
Sequence in context: A181715 A077089 A156352 * A175191 A324534 A248505
Adjacent sequences: A323753 A323754 A323755 * A323757 A323758 A323759


KEYWORD

nonn


AUTHOR

Ctibor O. Zizka, Jan 26 2019


STATUS

approved



