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 A354775 #12 Jun 27 2022 08:24:57 %S A354775 5,9,25,37,49,67,73,91,97,145,193,289,385,577,769,1153,1537,2305,3073, %T A354775 4609,6145,9217,12289,18433,24577,36865,49153,73729,98305,147457, %U A354775 196609,294913,393217,589825,786433,1179649,1572865,2359297,3145729,4718593,6291457 %N A354775 Indices where A354169 is the sum of two consecutive powers of 2. %C A354775 A subsequence of A354798. %C A354775 The first differences begin 4, 16, 12, 12, 18, 6, 18, 6, 48, 48, 96, 96, 192, 192, 384, 384, 768, 768, 1536, ..., which suggests that from the 9th term on, the differences have g.f. 48*(1+x)/(1-2*x^2), with an analogous conjecture for the sequence itself. %H A354775 Rémy Sigrist, <a href="/A354775/a354775.txt">C++ program</a> %o A354775 (C++) See Links section. %o A354775 (Python) %o A354775 from itertools import count, islice %o A354775 from collections import deque %o A354775 from functools import reduce %o A354775 from operator import or_ %o A354775 def A354775_gen(): # generator of terms %o A354775 aset, aqueue, b, f, i = {0,1,2}, deque([2]), 2, False, 2 %o A354775 while True: %o A354775 for k in count(1): %o A354775 m, j, j2, r, s = 0, 0, 1, b, k %o A354775 while r > 0: %o A354775 r, q = divmod(r,2) %o A354775 if not q: %o A354775 s, y = divmod(s,2) %o A354775 m += y*j2 %o A354775 j += 1 %o A354775 j2 *= 2 %o A354775 if s > 0: %o A354775 m += s*2**b.bit_length() %o A354775 if m not in aset: %o A354775 i += 1 %o A354775 if '11' in (s := bin(m)[2:]) and s.count('1') == 2: %o A354775 yield i %o A354775 aset.add(m) %o A354775 aqueue.append(m) %o A354775 if f: aqueue.popleft() %o A354775 b = reduce(or_,aqueue) %o A354775 f = not f %o A354775 break %o A354775 A354775_list = list(islice(A354775_gen(),15)) # _Chai Wah Wu_, Jun 27 2022 %Y A354775 Cf. A354169, A354680, A354767, A354798, A354773-A354774. %K A354775 nonn %O A354775 1,1 %A A354775 _N. J. A. Sloane_, Jun 26 2022 %E A354775 More terms from _Rémy Sigrist_, Jun 27 2022