|
|
A069119
|
|
Numbers n such that n!*Sum_{i=1..n} 1/(i*2^i) is an integer.
|
|
2
|
|
|
3, 7, 15, 23, 31, 47, 63, 79, 87, 95, 127, 143, 151, 159, 186, 191, 215, 223, 255, 271, 279, 287, 319, 343, 351, 383, 415, 447, 471, 511, 527, 535, 543, 575, 599, 607, 639, 671, 698, 703, 727, 767, 799, 831, 895, 959, 964, 1023, 1039, 1047, 1055, 1087, 1111
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,1
|
|
COMMENTS
|
m is in this list if and only if v_2(d) + s_2(m) <= m where v_2(d) is the 2-adic valuation of the denominator of sum(i=1..n, 1/(i*2^i)) and s_2(m) is the sum of the digits in the expansion of m in base 2. - Peter Luschny, May 19 2014
|
|
LINKS
|
|
|
EXAMPLE
|
3 is in the sequence because 3!*(1/1/2^1 + 1/2/2^2 + 1/3/2^3) = 4 is an integer. - Robert Israel, May 18 2014
|
|
MAPLE
|
select(k -> type(k!*add(1/i/2^i, i=1..k), integer), [$1..10000]); # Robert Israel, May 18 2014
|
|
MATHEMATICA
|
|
|
PROG
|
(Sage)
s = add(1/(i*2^i) for i in (1..n))
vf = n - sum(ZZ(n).digits(base=2))
return valuation(denominator(s), 2) <= vf
(PARI) sm(n)=my(s, o); forstep(i=n, 1, -1, o=-valuation(s+=1/(i<<i), 2); if(i+#binary(i)-1<o, return(o))); o
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|