This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A379267 #17 Dec 21 2024 11:08:58 %S A379267 4,9,10,12,19,21,22,25,26,28,39,43,45,46,51,53,54,57,58,60,79,87,91, %T A379267 93,94,103,107,109,110,115,117,118,121,122,124,159,175,183,187,189, %U A379267 190,207,215,219,221,222,231,235,237,238,243,245,246,249,250,252,319,351 %N A379267 Numbers whose binary representation contains exactly two zeros. %H A379267 Robert Baillie and Thomas Schmelzer, <a href="https://library.wolfram.com/infocenter/MathSource/7166/">Summing Kempner's Curious (Slowly-Convergent) Series</a>, Mathematica Notebook kempnerSums.nb, Wolfram Library Archive, 2008. %F A379267 a(n) = (A357773(n)-1)/2. %F A379267 A023416(a(n)) = 2. %F A379267 Sum_{n>=1} 1/a(n) = 1.4121825365494357179372249141360906507417257788239800327155414852526863441610798293625536351899799813... (calculated using Baillie's irwinSums.m, see Links). - _Amiram Eldar_, Dec 21 2024 %t A379267 Select[Range[351],Count[IntegerDigits[#,2],0]==2&] (* _James C. McMahon_, Dec 20 2024 *) %o A379267 (Python) %o A379267 from math import isqrt, comb %o A379267 from sympy import integer_nthroot %o A379267 def A379267(n): %o A379267 a = (m:=integer_nthroot(6*n, 3)[0])+(n>comb(m+2,3))+2 %o A379267 b = isqrt((j:=comb(a,3)-n+1)<<3)+1>>1 %o A379267 c = j-comb((r:=isqrt(w:=j<<1))+(w>r*(r+1)),2)-1 %o A379267 return (1<<a)-(1<<b)-(1<<c)-1 %Y A379267 Cf. A023416, A357773. %K A379267 nonn,base %O A379267 1,1 %A A379267 _Chai Wah Wu_, Dec 19 2024