|
|
A116416
|
|
If n = Sum_{m>=1} 2^(m-1) * b(n,m), where each b(n,m) is 0 or 1 and the sum is a finite sum, then a(n) = numerator of Sum_{m>=1} b(n,m)/m.
|
|
6
|
|
|
0, 1, 1, 3, 1, 4, 5, 11, 1, 5, 3, 7, 7, 19, 13, 25, 1, 6, 7, 17, 8, 23, 31, 61, 9, 29, 19, 39, 47, 107, 77, 137, 1, 7, 2, 5, 1, 3, 1, 2, 5, 17, 11, 23, 3, 7, 5, 9, 11, 41, 13, 28, 7, 17, 6, 11, 37, 97, 67, 127, 19, 39, 29, 49, 1, 8, 9, 23, 10, 31, 41, 83, 11, 39, 25, 53, 61, 145, 103, 187
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
0,4
|
|
LINKS
|
|
|
EXAMPLE
|
13 in binary is 1101. So a(13) is the numerator of 1/4 + 1/3 + 1 = 19/12, since the binary digits at positions (from right to left) 1, 3 and 4 are each 1 and the other digits are 0.
|
|
MATHEMATICA
|
Table[Numerator@ Total@ MapIndexed[#1/ First@ #2 &, Reverse@ IntegerDigits[n, 2]], {n, 0, 79}] (* Michael De Vlieger, Aug 19 2017 *)
|
|
PROG
|
(PARI) a(n) = {my(b = Vecrev(binary(n))); numerator(sum(k=1, #b, b[k]/k)); } \\ Michel Marcus, Apr 18 2016
|
|
CROSSREFS
|
|
|
KEYWORD
|
|
|
AUTHOR
|
|
|
EXTENSIONS
|
|
|
STATUS
|
approved
|
|
|
|