login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A178965
a(n) = numerator of Sum_{k>=1} floor(n/k)/2^k.
1
0, 1, 5, 15, 43, 103, 263, 591, 1391, 3103, 7007, 15039, 33983, 72063, 156543, 334591, 722687, 1510911, 3255807, 6773759, 14433279, 30193663, 63535103, 131264511, 278589439, 575004671, 1200349183, 2484846591, 5189910527, 10648256511, 22287450111, 45648642047
OFFSET
0,3
LINKS
FORMULA
a(n) = Sum_{i=1..n} 2^(n-i)*floor(n/i). - Ridouane Oudra, Jul 30 2019
EXAMPLE
a(3)=15 because Sum_{k>=1} floor(3/k)/2^k = 15/8.
MAPLE
seq(add(2^(n-i)*floor(n/i), i=1..n), n=0..60); # Ridouane Oudra, Jul 30 2019
MATHEMATICA
Table[Numerator[Sum[Floor[n/k]/2^k, {k, 1, Infinity}]], {n, 0, 25}]
PROG
(Magma) [0] cat [&+[2^(n-i)*Floor(n/i):i in [1..n]]:n in [1..25]]; // Marius A. Burtea, Jul 30 2019
(PARI) a(n) = numerator(sum(k=1, n, floor(n/k)/2^k)); \\ Jinyuan Wang, Jul 31 2019
CROSSREFS
Sequence in context: A111295 A200760 A032193 * A005665 A025471 A064453
KEYWORD
nonn,frac
AUTHOR
STATUS
approved