OFFSET
1,2
COMMENTS
An irregular table in which the n-th row lists the base-9 digits of n. - Jason Kimberley, Dec 07 2012
The base-9 Champernowne constant: it is normal in base 9. - Jason Kimberley, Dec 07 2012
LINKS
Reinhard Zumkeller, Table of n, a(n) for n = 1..10000
MATHEMATICA
Flatten@ IntegerDigits[ Range@ 55, 9] (* or *)
almostNatural[n_, b_] := Block[{m = 0, d = n, i = 1, l, p}, While[m <= d, l = m; m = (b - 1) i*b^(i - 1) + l; i++]; i--; p = Mod[d - l, i]; q = Floor[(d - l)/i] + b^(i - 1); If[p != 0, IntegerDigits[q, b][[p]], Mod[q - 1, b]]]; Array[ almostNatural[#, 9] &, 105] (* Robert G. Wilson v, Jul 01 2014 *)
PROG
(Magma) &cat[Reverse(IntegerToSequence(n, 9)):n in[1..31]]; // Jason Kimberley, Dec 07 2012
(Haskell)
a031076 n = a031076_list !! (n-1)
a031076_list = concat $ map reverse $ tail a031087_tabf
-- Reinhard Zumkeller, Jul 07 2015
(Python)
from itertools import count, chain, islice
from sympy.ntheory.factor_ import digits
def A031076_gen(): return chain.from_iterable(digits(m, 9)[1:] for m in count(1))
CROSSREFS
KEYWORD
AUTHOR
STATUS
approved