cp's OEIS Frontend

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.

A354142 a(n) = smallest number missing from A352808 after A352808(n) has been found.

This page as a plain text file.
%I A354142 #10 May 18 2022 22:00:02
%S A354142 1,2,3,3,3,3,6,6,6,6,7,11,11,11,11,11,11,11,13,14,14,14,14,14,14,14,
%T A354142 14,14,14,14,14,14,15,15,15,15,15,15,15,15,15,15,15,15,23,26,26,26,26,
%U A354142 26,27,27,27,27,27,27,30,30,30,30,30,30,31,43,43,43,43,43,43,43,43,43,43,43,43,43,43,43
%N A354142 a(n) = smallest number missing from A352808 after A352808(n) has been found.
%H A354142 Michael S. Branicky, <a href="/A354142/b354142.txt">Table of n, a(n) for n = 0..10000</a>
%e A354142 A352808 (with offset 0) begins 0,1,2,4,5,8; after A352808(0) = 0 has been found, the smallest missing number is 1, so a(0) = 1; after A352808(5) = 8 has been found, the smallest missing number is 3, so a(5) = 3.
%o A354142 (Python)
%o A354142 from itertools import count, islice
%o A354142 def agen(): # generator of terms
%o A354142     A352808lst, A352808set, mink = [0], {0}, 1
%o A354142     for n in count(1):
%o A354142         yield mink
%o A354142         ahalf, k = A352808lst[n//2], mink
%o A354142         while k in A352808set or k&ahalf: k += 1
%o A354142         A352808lst.append(k); A352808set.add(k)
%o A354142         while mink in A352808set: mink += 1
%o A354142 print(list(islice(agen(), 78))) # _Michael S. Branicky_, May 18 2022
%Y A354142 Cf. A352808.
%K A354142 nonn
%O A354142 0,2
%A A354142 _N. J. A. Sloane_, May 18 2022