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 A290633 #19 Aug 18 2017 14:06:52 %S A290633 2,2,4,4,2,6,3,3,6,2,8,4,6,6,4,8,2,10,4,12,2,14,4,10,2,12,3,9,6,8,8,6, %T A290633 9,3,12,4,14,2,16,4,18,2,20,4,16,2,18,3,15,5,5,10,6,12,8,10,5,15,3,18, %U A290633 4,20,2,22,4,24,2,26,4,22,2,24,3,21,6,10,8,12 %N A290633 Lexicographically earliest sequence of positive integers such that, for any m and n > 0, gcd(a(n), a(n+1)) > 1 and a(n) != a(n+2), and if m < n then a(m) != a(n) or a(m+1) != a(n+1). %C A290633 a(n) > 1 for any n > 0. %C A290633 If we drop the constraint "a(n) != a(n+2)", then we obtain the positive even numbers interspersed with 2's: 2, 2, 4, 2, 6, ... %C A290633 Conjecturally, (a(n), a(n+1)) runs over all pairs of noncoprime positive integers; in this sense, this sequence is opposite to sequences like Stern's diatomic series (A002487). %C A290633 This sequence has connections with A067992: here we avoid duplicate ordered pairs of consecutive terms, there unordered pairs, here we deal with noncoprime consecutive terms, there we (conjecturally) have coprime consecutive terms; also, the scatterplots of these sequences have similarities. %C A290633 For any prime p, the sequence contains a multiple of p: by contradiction: %C A290633 - let p be the least prime whose multiples are missing from the sequence (note that p > 2), %C A290633 - there is only a finite number of pairs of noncoprime (p-1)-smooth numbers < p^2, %C A290633 - so eventually we must have a term, say a(m), > p^2, %C A290633 - if q is the least prime factor of a(m-1), then p*q would have been a better choice for a(m), hence the contradiction. %C A290633 Also, if p is an odd prime, then the first multiple of p appearing in the sequence is a semiprime p*q with q < p. %C A290633 If p < q are prime, then the first multiple of p appears before the first multiple of q. %C A290633 For any prime p, the first occurrence of p in the sequence is immediately followed by a second occurrence of p. %C A290633 For any prime p > 3: %C A290633 - there is a semiprime p*q with q < p in the sequence, %C A290633 - if q = 2, then this first p*q is followed by a 4, %C A290633 - if q > 2, then this first p*q is followed by a 2, %C A290633 - so there are infinitely many 2's or 4's in the sequence, %C A290633 - if there are infinitely many 2's in the sequence, then the n-th occurrence of 2 is followed by 2*(n+e) with |e| <= 1, and every even %C A290633 number appears in the sequence, %C A290633 - the same conclusion applies if there are infinitely many 4's, %C A290633 - hence every even number appear in the sequence. %C A290633 For any n > 1, the first occurrence of n in the sequence must be either preceded or followed by the least prime factor of n (A020639). %H A290633 Rémy Sigrist, <a href="/A290633/b290633.txt">Table of n, a(n) for n = 1..10000</a> %H A290633 Rémy Sigrist, <a href="/A290633/a290633.gp.txt">PARI program for A290633</a> %H A290633 Rémy Sigrist, <a href="/A290633/a290633.png">Scatterplot of the first 10000 pairs of consecutive terms</a> %H A290633 Rémy Sigrist, <a href="/A290633/a290633_1.png">Colorized scatterplot of the first 100000 pairs of consecutive terms</a> %e A290633 a(1) = 2 is suitable. %e A290633 a(2) = 2 is suitable. %e A290633 a(3) cannot be either 2 (=a(1)) or 3 (gcd(2,3)=1). %e A290633 a(3) = 4 is suitable. %e A290633 a(4) cannot be either 2 (=a(2)) or 3 (gcd(4,3)=1). %e A290633 a(4) = 4 is suitable. %e A290633 a(5) = 2 is suitable. %e A290633 a(6) cannot be 2 (pair (2,2) already seen), 3 (gcd(2,3)=1), 4 (pair (2,4) already seen) or 5 (gcd(2,5)=1). %e A290633 a(6) = 6 is suitable. %o A290633 (PARI) See Links section. %Y A290633 Cf. A002487, A020639, A067992. %K A290633 nonn,look %O A290633 1,1 %A A290633 _Rémy Sigrist_, Aug 08 2017