

A108712


A fractal sequence, defined by a(2n1) = A007376(n) (the almostnatural numbers), a(2n) = a(n).


0



1, 1, 2, 1, 3, 2, 4, 1, 5, 3, 6, 2, 7, 4, 8, 1, 9, 5, 1, 3, 0, 6, 1, 2, 1, 7, 1, 4, 2, 8, 1, 1, 3, 9, 1, 5, 4, 1, 1, 3, 5, 0, 1, 6, 6, 1, 1, 2, 7, 1, 1, 7, 8, 1, 1, 4, 9, 2, 2, 8, 0, 1, 2, 1, 1, 3, 2, 9, 2, 1, 2, 5, 3, 4, 2, 1, 4, 1, 2, 3, 5, 5, 2, 0, 6, 1, 2, 6, 7, 6, 2, 1, 8, 1, 2, 2, 9, 7, 3, 1, 0, 1, 3, 7, 1
(list;
graph;
refs;
listen;
history;
text;
internal format)



OFFSET

1,3


COMMENTS

Start saying "1" and erase, as soon as they appear, the digits spelling the natural numbers. The result is the sequence itself.
Sequence based on the same skeleton as A108202 (the natural counting digits) but beginning with 1 instead of zero; with n increasing, the apparent correlation between the two sequences disappears.


LINKS

Table of n, a(n) for n=1..105.
Clark Kimberling, Un. of Evansville, Fractal Sequences.


FORMULA

a(2n1) = A007376(n), a(2n) = a(n).


EXAMPLE

Say "1" and erase the first "1", then say "2" and erase the first "2" (leaving all other digits where they are), then say "3" and erase the first "3", etc. When it comes to "10" erase the first "1" and then the closest "0", etc. The digits to erase when the count comes to "16", for example, are next one to another.


MATHEMATICA

f[n_] := Block[{m = 0, d = n, i = 1, l, p}, While[m <= d, l = m; m = 9i*10^(i  1) + l; i++ ]; i; p = Mod[d  l, i]; q = Floor[(d  l)/i] + 10^(i  1); If[p != 0, IntegerDigits[q][[p]], Mod[q  1, 10]]]; a[n_] := a[n] = If[EvenQ[n], a[n/2], f[(n + 1)/2]]; Table[ a[n], {n, 105}] (* Robert G. Wilson v, Jun 24 2005 *)


CROSSREFS

a(n) = A108202(n) + 1.
Cf. A003602.
Sequence in context: A260429 A094193 A278539 * A003602 A265650 A181733
Adjacent sequences: A108709 A108710 A108711 * A108713 A108714 A108715


KEYWORD

base,easy,nonn


AUTHOR

Eric Angelini, Jun 20 2005


EXTENSIONS

Additional comments from Robert G. Wilson v and Alexandre Wajnberg, Jun 24 2005


STATUS

approved



