login

Reminder: The OEIS is hiring a new managing editor, and the application deadline is January 26.

A276350
Sum of digits of 1/n in factorial base.
6
1, 1, 2, 3, 5, 1, 11, 3, 7, 4, 25, 2, 42, 10, 4, 6, 65, 6, 94, 2, 7, 24, 125, 1, 26, 46, 18, 10, 182, 4, 265, 14, 33, 65, 9, 5, 394, 84, 33, 3, 449, 8, 471, 25, 6, 121, 570, 5, 48, 21, 62, 40, 619, 13, 18, 8, 85, 150, 847, 2, 1020, 263, 9, 13, 38, 31, 1064, 60
OFFSET
1,3
COMMENTS
See the Wikipedia link for the construction method of 1/n in factorial base.
For n>1, A002034(n) gives the number of significant digits of 1/n in factorial base.
FORMULA
a(n!)=1 for any n>0.
EXAMPLE
n 1/n in factorial base a(n)
-- ---------------------------- ----
1 1 1
2 0.0 1 1
3 0.0 0 2 2
4 0.0 0 1 2 3
5 0.0 0 1 0 4 5
6 0.0 0 1 1
7 0.0 0 0 3 2 0 6 11
8 0.0 0 0 3 3
9 0.0 0 0 2 3 2 7
10 0.0 0 0 2 2 4
11 0.0 0 0 2 0 5 3 1 4 0 10 25
12 0.0 0 0 2 2
13 0.0 0 0 1 4 1 2 5 4 8 5 0 12 42
14 0.0 0 0 1 3 3 3 10
15 0.0 0 0 1 3 4
MATHEMATICA
f[n_] := Block[{s = 0, r = 1, a = 1/n}, While[a > 0, s += Floor[a]; r++; a = FractionalPart[a]*r]; s] (* after Rémy Sigrist *); Array[f, 70] (* Robert G. Wilson v, Feb 01 2018 *)
PROG
(PARI) {a(n) = my(s=0, r=1, f=1/n); while (f>0, s+= floor(f); r++; f = frac(f)*r); s}
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Rémy Sigrist, Dec 12 2016
STATUS
approved