%I #31 Dec 06 2018 15:51:04
%S 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,
%T 182,4,265,14,33,65,9,5,394,84,33,3,449,8,471,25,6,121,570,5,48,21,62,
%U 40,619,13,18,8,85,150,847,2,1020,263,9,13,38,31,1064,60
%N Sum of digits of 1/n in factorial base.
%C See the Wikipedia link for the construction method of 1/n in factorial base.
%C For n>1, A002034(n) gives the number of significant digits of 1/n in factorial base.
%H Rémy Sigrist, <a href="/A276350/b276350.txt">Table of n, a(n) for n = 1..10000</a>
%H Rémy Sigrist, <a href="/A276350/a276350.png">Colored logarithmic scatterplot of the first 25000 terms</a> (where the color is function of A052126(n))
%H Wikipedia, <a href="https://en.wikipedia.org/wiki/Factorial_number_system#Fractional_values">Factorial number system (Fractional values)</a>
%H <a href="/index/Fa#facbase">Index entries for sequences related to factorial base representation</a>
%F a(n!)=1 for any n>0.
%e n 1/n in factorial base a(n)
%e -- ---------------------------- ----
%e 1 1 1
%e 2 0.0 1 1
%e 3 0.0 0 2 2
%e 4 0.0 0 1 2 3
%e 5 0.0 0 1 0 4 5
%e 6 0.0 0 1 1
%e 7 0.0 0 0 3 2 0 6 11
%e 8 0.0 0 0 3 3
%e 9 0.0 0 0 2 3 2 7
%e 10 0.0 0 0 2 2 4
%e 11 0.0 0 0 2 0 5 3 1 4 0 10 25
%e 12 0.0 0 0 2 2
%e 13 0.0 0 0 1 4 1 2 5 4 8 5 0 12 42
%e 14 0.0 0 0 1 3 3 3 10
%e 15 0.0 0 0 1 3 4
%t 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 *)
%o (PARI) {a(n) = my(s=0, r=1, f=1/n); while (f>0, s+= floor(f); r++; f = frac(f)*r); s}
%Y Cf. A002034, A007623, A034968, A052126.
%K nonn,base
%O 1,3
%A _Rémy Sigrist_, Dec 12 2016