OFFSET
1,3
COMMENTS
Start with a(1) = 1 and read the sequence digit by digit starting from the left:
when the read digit is odd, we divide by 2 the last term of the sequence, then extend the sequence with the entire part of the result;
when the read digit is even (but not 0), we multiply by 3 the last term of the sequence, then extend the sequence with the result;
when the read digit is 0, we extend the sequence with the smallest integer not yet present in the sequence.
LINKS
Jean-Marc Falcoz, Table of n, a(n) for n = 1..10001
EXAMPLE
The odd digit 1 divides 1 by two (which is 0,5), and |0,5| is 0;
the digit 0 extends the sequence with the smallest integer not present yet in the sequence, which is 2;
the digit 2 multiplies 2 by three, which is 6;
the digit 6 multiplies 6 by three, which is 18;
the odd digit 1 divides 18 by two, which is 9;
the digit 8 multiplies 9 by three, which is 27; etc.
CROSSREFS
KEYWORD
AUTHOR
Eric Angelini and Jean-Marc Falcoz, Jul 12 2018
STATUS
approved