OFFSET
1,2
COMMENTS
Partial sums for the convergent modified harmonic series in base 3 excluding 0 = Sum of 1/a(n) + 1/(a(n) + 1) = Sum of (2*a(n) + 1)/(a(n)*(a(n) + 1)).
LINKS
Robert Baillie, Sums of Reciprocals of Integers Missing a Given Digit, American Mathematical Monthly (Washington, DC: Mathematical Association of America) 86 (5): 372-374, May 1979, doi:10.2307/2321096. ISSN 0002-9890. JSTOR 2321096.
FORMULA
a(n) = A032924(2n - 1).
EXAMPLE
Pattern of numbers of skipped terms (numbers in base 3 with at least one zero) is 1 (3 = 10_3), 1 (6 = 20_3), 3+1 (9 = 100_3, 10 = 101_3, 11 = 102_3, 12 = 110_3), 1, 3+1, 1, 9+3+1, 1, 3+1, 1, 9+3+1, 1, 3+1, 1, 27+9+3+1, ...
PROG
(PARI) lista(nn)=prec0 = 1; for(n=1, nn, if (vecmin(digits(n, 3)), if (prec0, print1(n, , ", ")); prec0 = 0, prec0 = 1); ); \\ Michel Marcus, Aug 03 2015
(Python)
def A259566(n): return int(bin(m:=n)[3:], 3)*3 + (3**m.bit_length()-1>>1) if n>1 else 1 # Chai Wah Wu, Oct 13 2023
CROSSREFS
KEYWORD
nonn,base,less
AUTHOR
Sean Oneil, Jun 30 2015
STATUS
approved