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 A342042 #115 Jan 11 2025 04:00:47 %S A342042 0,1,2,3,4,5,6,7,8,9,10,11,12,30,13,14,50,15,16,70,17,18,90,19,23,24, %T A342042 51,25,26,71,27,28,91,29,31,32,33,34,52,35,36,72,37,38,92,39,45,46,73, %U A342042 47,48,93,49,53,54,55,56,74,57,58,94,59,67,68,95,69,75,76,77,78,96,79,89,97,98,99,101 %N A342042 When a digit d in the digit-stream of this sequence is even, the next digit is > d. %C A342042 The definition refers to the digit-stream in the sequence (ignoring the commas), which starts 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 1, 0, 1, 1, 1, 2, 3, 0, ... %C A342042 The sequence is always extended with the smallest nonnegative integer not yet present that doesn't lead to a contradiction. %C A342042 Theorem: The sequence contains every nonnegative integer except those in A347298. %C A342042 Proved in September 2021. See S.K. link for a new, more detailed proof. - _Sebastian Karlsson_, Nov 28 2024. See N.J.A.S. link for an alternative, shorter, proof. - _N. J. A. Sloane_, Nov 29 2024 %C A342042 Comments added by _N. J. A. Sloane_, Dec 04 2024 (Start): %C A342042 Let S = present sequence, P = A377912. By definition the terms in P appear in their natural order. There are A377917(k) terms in P of decimal length k >= 1. They form a consecutive block in P, starting at P(i1) and ending at P(i2), where i1 = A377918(k), i2 = A377918(k+1)-1. %C A342042 We know S contains exactly the same terms as P, but in a different order. %C A342042 Conjecture 1. For k >= 1, the terms of length k in S form a consecutive block with the same starting and ending points as in P. In both P and S, the block begins with 10101... (1's and 0's alternate, length is k) and end with 99...9 (k 9's). %C A342042 Conjecture 2. We know every number appears in S. Suppose x = S(m) = 899...9 (with k-1 9's). Then x is the last term of length k in S that begins with a digit <= 8. The remaining terms of length k have leading digit 9 and appear in order, ending with 99...9 (k 9's). %C A342042 (Some k-digit numbers beginning with 9 may appear before x.) %C A342042 (End) %C A342042 Comment from _N. J. A. Sloane_, Dec 01 2024 (Start) %C A342042 Let c1 = 7.422574840... and c2 = 1.3824387... be the constants defined in A377918. Then assuming Conjecture 1, the index of the last term of length k in the present sequence is close to (c2*c1^k, 10^k). [Thanks to _Sebastian Karlsson_ for pointing out that Conjecture 1 is required and is as yet unproved.] %C A342042 Let x = c2*c1^k, and express k in terms of x. %C A342042 Then this point has coordinates (x,y) where y = (x/c2)^c3, with c3 = (log 10)/(log c1) = 1.14869... This defines a curve that is a good approximation to the lower envelope of the present sequence. %C A342042 For example, the fifth meeting point has coordinates (31148, 101010) (see A377918) and the formula here gives (x,y) = (31148, 100003.0039). %C A342042 (End) %C A342042 Comment from _Sebastian Karlsson_, Dec 12 2024: (Start) %C A342042 Theorem: Let d be in {1, 2, ..., 8}. For every positive integer k, the k-digit number d99...9 appears in the sequence before the k-digit number (d+1)99...9. %C A342042 A proof can be found in the links. Since all k-digit numbers starting with 9 appears before any (k+1)-digit number, we get that terms of a certain length form a consecutive block. In particular, this proves Conjectures 1 and 2 above. %C A342042 (End) %H A342042 N. J. A. Sloane, <a href="/A342042/b342042.txt">Table of n, a(n) for n = 1..20000</a> [Computed using Rémy Sigrist's PARI program. The first 10000 terms were computed by Peter Kagey] %H A342042 Sebastian Karlsson, <a href="/A342042/a342042.pdf">Proof of Theorem</a>. %H A342042 Sebastian Karlsson, <a href="/A342042/a342042_2.pdf">Proof of the second Theorem</a>. %H A342042 Rémy Sigrist, <a href="/A342042/a342042.png">Colored scatterplot of the first 20000 terms</a> (where the color is function of the leading digit of a(n)) %H A342042 Rémy Sigrist, <a href="/A342042/a342042.gp.txt">PARI program for A342042</a> %H A342042 N. J. A. Sloane, <a href="https://www.youtube.com/watch?v=3RAYoaKMckM">A Nasty Surprise in a Sequence and Other OEIS Stories</a>, Experimental Mathematics Seminar, Rutgers University, Oct 10 2024, Youtube video; <a href="https://sites.math.rutgers.edu/~zeilberg/expmath/sloane85BD.pdf">Slides</a> [Mentions this sequence] %H A342042 N. J. A. Sloane, <a href="/A342042/a342042_2.txt">An Alternative Proof of the Theorem.</a> %o A342042 (PARI) \\ See Links section. %o A342042 (Python) %o A342042 def cond(s, minfirst): %o A342042 return all(s[i+1] > s[i] for i in range(len(s)-1) if s[i] in "02468") %o A342042 def aupton(terms): %o A342042 alst, seen = [0], {0} %o A342042 while len(alst) < terms: %o A342042 d = alst[-1]%10 %o A342042 an = minfirst = (1 - d%2)*(d+1) %o A342042 stran = str(an) %o A342042 while an in seen or not cond(stran, minfirst): %o A342042 an += 1 %o A342042 stran = str(an) %o A342042 if int(stran[0]) < minfirst: %o A342042 an = minfirst*10**(len(stran)-1) %o A342042 alst.append(an); seen.add(an) %o A342042 return alst %o A342042 print(aupton(77)) # _Michael S. Branicky_, Sep 07 2021 %Y A342042 Cf. A342043, A342044, A342045, A342046 and A342047 (variations on the same idea). %Y A342042 See A377913 and A377914 for records. %Y A342042 See also A347298. %Y A342042 Cf. A379901, A379903. %K A342042 base,nonn,nice %O A342042 1,3 %A A342042 _Eric Angelini_, Feb 26 2021 %E A342042 Edited by _N. J. A. Sloane_, Nov 24 2024