login
This site is supported by donations to The OEIS Foundation.
Logo

Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A108731 Triangle read by rows: row n gives digits of n in base factorial. 2

%I

%S 0,1,1,0,1,1,2,0,2,1,1,0,0,1,0,1,1,1,0,1,1,1,1,2,0,1,2,1,2,0,0,2,0,1,

%T 2,1,0,2,1,1,2,2,0,2,2,1,3,0,0,3,0,1,3,1,0,3,1,1,3,2,0,3,2,1,1,0,0,0,

%U 1,0,0,1,1,0,1,0,1,0,1,1,1,0,2,0,1,0,2,1,1,1,0,0,1,1,0,1,1,1,1,0,1,1,1,1,1,1

%N Triangle read by rows: row n gives digits of n in base factorial.

%C Row lengths are A084558. This sequence contains every finite sequence of nonnegative integers.

%H _Reinhard Zumkeller_, <a href="/A108731/b108731.txt">Rows n = 0..2000 of triangle, flattened</a>

%H C. A. Laisant, <a href="http://www.numdam.org/item?id=BSMF_1888__16__176_0">Sur la numération factorielle, application aux permutations</a>, Bulletin de la Société Mathématique de France, 16 (1888), p. 176-183.

%H Wikipedia, <a href="http://en.wikipedia.org/wiki/Factoradic">Factorial number system</a>

%H <a href="/index/Fa#factorial">Index entries for sequences related to factorial numbers</a>

%e Triangle begins:

%e 1

%e 1,0

%e 1,1

%e 2,0

%e 2,1

%e 1,0,0

%e For example, 11 in base factorial is 121 (1*6 + 2*2 + 1*1), so row 11 is 1,2,1.

%o (Haskell)

%o a108731 n k = a108731_row n !! k

%o a108731_row 0 = [0]

%o a108731_row n = t n $ reverse $ takeWhile (<= n) $ tail a000142_list

%o where t 0 [] = []

%o t x (b:bs) = x' : t m bs where (x',m) = divMod x b

%o a108731_tabf = map a108731_row [0..]

%o -- _Reinhard Zumkeller_, Jun 04 2012

%Y Cf: A084558, A007623.

%Y Cf. A000142.

%K easy,nonn,tabf,base

%O 0,7

%A _Franklin T. Adams-Watters_, Jun 22 2005

%E Added a(0)=0 and offset changed accordingly by _Reinhard Zumkeller_, Jun 04 2012

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Transforms | Puzzles | Hot | Classics
Recent Additions | More pages | Superseeker | Maintained by The OEIS Foundation Inc.

Content is available under The OEIS End-User License Agreement .

Last modified May 22 20:23 EDT 2013. Contains 225568 sequences.