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.

Showing 1-6 of 6 results.

A352867 a(1) = 1, a(2) = 2; for n > 2, a(n) is the smallest positive number that has not appeared that shares a factor with a(n-1), a(n-2), and a(n-1)+a(n-2).

Original entry on oeis.org

1, 2, 6, 4, 8, 10, 12, 14, 16, 18, 20, 22, 24, 26, 28, 30, 32, 34, 36, 38, 40, 42, 44, 46, 48, 50, 52, 54, 56, 58, 60, 62, 64, 66, 68, 70, 72, 74, 76, 78, 80, 82, 84, 86, 88, 90, 92, 94, 96, 98, 100, 102, 104, 106, 108, 110, 112, 105, 7, 21, 35, 49, 63, 77, 91, 119, 126, 133, 140, 114, 116
Offset: 1

Views

Author

Scott R. Shannon, Apr 06 2022

Keywords

Comments

The sequence shows long runs of even terms differing by 2 which are eventually broken by a number with a product of odd primes less than the last even term. The term after such run-breaking terms is often significantly less than the previous terms, leading to the sequence showing abrupt dips in its values. In the first 200000 terms the longest even-numbered run is 106 terms, and it is likely these runs can grow arbitrarily long. Likewise long runs of odd terms also exist, the longest such run being 133 terms in the same range. However unlike the even-numbered runs which increase by 2 each term the odd-numbered runs increase with differing amounts between each term. Between the large dips in value the majority of terms are concentrated along a line with gradient ~ 1.125. See the linked images.
It takes many terms for the primes to appear, e.g. a(166) = 3, a(239) = 5, a(1841) = 23, a(13325) = 61, a(158205) = 191. They do not appear in their natural order.
Other than the first few terms the only fixed point up to 200000 terms is 63. It is possible more exist although this is unknown. The sequence is almost certainly a permutation of the positive integers.

Examples

			a(4) = 4 as a(2)=2, a(3)=6, a(2)+a(3)=8, and 4 is the smallest unused number that shares a factor with 2, 6, and 8.
a(58) = 105 as a(56)=110, a(57)=112, a(56)+a(57)=222, and 105 = 3*5*7 is the smallest unused number that shares a factor with 110, 112, and 222. This breaks a run of fifty-three consecutive even terms differing by 2.
a(59) = 7 as a(57)=112, a(58)=105, a(57)+a(58)=217, and 7 is the smallest unused number that shares a factor with 112, 105, and 217. This is the second prime to appear after a(2)=2.
		

Crossrefs

Programs

A352768 a(1) = 1, a(2) = 2; for n > 2, a(n) is the smallest positive number that has not appeared that shares a factor with both a(n-2)+a(n-1) and a(n-2)*a(n-1).

Original entry on oeis.org

1, 2, 6, 4, 8, 10, 12, 14, 16, 18, 20, 22, 15, 74, 178, 24, 26, 28, 21, 7, 30, 111, 3, 9, 27, 33, 36, 39, 40, 158, 32, 34, 38, 42, 35, 44, 316, 46, 48, 50, 52, 45, 194, 478, 54, 56, 58, 60, 62, 64, 66, 55, 11, 70, 63, 49, 72, 77, 298, 78, 68, 76, 51, 254, 75, 84, 57, 69, 81, 87, 90, 93, 96, 98
Offset: 1

Views

Author

Scott R. Shannon, Apr 02 2022

Keywords

Comments

In the first 250000 terms the lowest number not to appear is 811; it is likely this sequence is a permutation of the positive integers. In this range the fixed points are 1, 2, 4, 35, 6731, 167821. It is possible more exist although this is unknown. In the same range the longest runs of consecutive even terms and odd terms is 29 and 33 respectively. This suggests such runs are likely arbitrarily long.

Examples

			a(3) = 6 as a(1)+a(2)=3, a(1)*a(2)=2, and 6 is the smallest unused number that shares a factor with both 3 and 2.
		

Crossrefs

Programs

A352774 a(1) = 1, a(2) = 2; for n > 2, a(n) is the smallest positive number that has not appeared that does not share a factor with a(n-2) + a(n-1) or a(n-2)*a(n-1).

Original entry on oeis.org

1, 2, 5, 3, 7, 11, 13, 17, 19, 23, 25, 29, 31, 37, 9, 35, 41, 27, 43, 47, 49, 53, 55, 59, 61, 67, 15, 71, 73, 65, 77, 51, 79, 83, 85, 89, 91, 97, 33, 101, 95, 39, 103, 107, 109, 113, 115, 119, 121, 127, 21, 125, 131, 57, 137, 139, 133, 45, 143, 149, 63, 145, 151, 69, 157, 155, 161, 81, 163, 167
Offset: 1

Views

Author

Scott R. Shannon, Apr 02 2022

Keywords

Comments

As a(2) is even, which forces a(3) and a(4) to be odd, all following terms will be odd as the sum of two odd terms is even. Beyond a(5) = 7 all subsequent primes appear in their natural order.

Examples

			a(2) = 5 as a(1) + a(2) = 3, a(1)*a(2) = 2, and 5 is the smallest unused number that does not share a factor with 3 or 2.
		

Crossrefs

A352790 a(1) = 1, a(2) = 2; for n > 2, a(n) is the smallest positive number that has not appeared that is a divisor of either a(n-2)+a(n-1) or a(n-2)*a(n-1).

Original entry on oeis.org

1, 2, 3, 5, 4, 9, 6, 15, 7, 11, 18, 22, 8, 10, 16, 13, 26, 39, 65, 52, 20, 12, 24, 32, 14, 23, 37, 30, 67, 97, 41, 46, 29, 25, 27, 45, 36, 54, 72, 21, 28, 42, 35, 49, 84, 19, 38, 57, 95, 76, 171, 114, 285, 90, 50, 60, 40, 48, 44, 33, 66, 99, 55, 77, 121, 198, 242, 88, 110, 80, 100, 64, 82, 73
Offset: 1

Views

Author

Scott R. Shannon, Apr 03 2022

Keywords

Comments

The sequence shows large variations in its values due to some terms being required to equal the product of two large primes as all other divisors of both the sum and product have been used, e.g., a(25893) = 68485691. In the first 50000 terms there are 28233 occasions where the chosen term is a divisor of the sum and 22777 occasions where it is a divisor of the product. In the same range the fixed points are 1, 2, 3, 42, 3674, 11520, 18515, 39501 - it is likely more exist. The smallest number not to appear is 761, while the primes do not occur in their natural order. It is possible the sequence is finite as two terms could appear whose sum and product divisors have all been used. If not then the sequence is likely a permutation of the positive integers.
From Michael De Vlieger, Apr 03 2022: (Start)
Let S = a(n-1)+a(n+2) and let P = a(n-1)*a(n-2). Let u be the smallest missing number in a(1..n-1).
It is possible that S is prime, but P is prime iff either a(n-1)=1 or a(n-2)=1; since a(1) = 1 is given and followed by 2, for n > 2, P is always composite.
The axiom a(n) = (k | S) or (k | P) implies (k <= S) or (k <= P). Consequently, u <= k <= max(S,P). Let D contain divisors {d : d | S and d >= u} and let E contain factors {d : d | P and d >= u}. A solution k must appear in T = D U E.
For sufficiently large n, S is large, but P is large and composite.
In this sequence we may have equality of (one) input and output, since input S or P does not necessarily already exist in a.
(End)

Examples

			a(4) = 5 as a(2)+a(3) = 5 and a(2)*a(3) = 6. The combined divisors of these two numbers are 1,2,3,5,6, and of those 5 is the smallest that has not appeared.
		

Crossrefs

Programs

A361606 Lexicographically earliest infinite sequence of distinct positive numbers such that, for n > 3, a(n) shares a factor with a(n-1) and a(n-2) but not with a(n-1) + a(n-2).

Original entry on oeis.org

1, 6, 10, 15, 12, 20, 45, 18, 40, 75, 24, 50, 105, 14, 30, 21, 28, 36, 63, 56, 48, 147, 98, 54, 189, 70, 60, 231, 22, 42, 33, 44, 72, 99, 88, 78, 143, 66, 26, 39, 84, 52, 91, 112, 104, 455, 80, 126, 35, 90, 154, 55, 100, 132, 135, 110, 96, 165, 130, 102, 85, 120, 34, 51, 108, 68, 153, 114
Offset: 1

Views

Author

Scott R. Shannon, Mar 17 2023

Keywords

Comments

All terms must contain two or more distinct prime factors. If a(n) was a prime power then a(n+1) would contain the same prime factor, which in turn would imply that a(n) + a(n+1) is a multiple of the prime. But that would make finding a(n+2) impossible as any factor of a(n) would also be a factor of the sum.
To ensure the sequence is infinite a(n) must also contain a prime factor not in a(n-1). If this were not the case the sum a(n-1) + a(n) would be a multiple of the distinct prime factors of a(n), implying a(n+1) would not exist as any factor of a(n) would be a factor of the sum.
The last even term is a(114) = 210. As a(115) = 119 and a(116) = 255, the first occurrence of consecutive odd values, the resulting sum is even, so a(117) must be odd. This forces all subsequent terms to also be odd.
There is a concentration of terms at a(n) ~ 3.4*n. See the linked image. The only fixed point in the first 50000 terms is 14, although it is possible more exist.

Examples

			a(8) = 18 = 2*3*3 as a(6) = 20 = 2*2*5 and a(7) = 45 = 3*3*5 and a(6) + a(7) = 20 + 45 = 65 = 5*13. As the sum contains 5 as a factor a(8) cannot, but it must contain both 2 and 3 while containing a factor not in 45 = 3*3*5. The smallest unused number satisfying these conditions is 18.
		

Crossrefs

Programs

A349491 a(1)=1, a(2)=4; for n > 2, a(n) is the smallest unused positive number such that gcd(a(n-1)*n,a(n)) > 1, where a(n) != a(n-1) and a(n) != n.

Original entry on oeis.org

1, 4, 2, 6, 3, 8, 10, 5, 12, 9, 15, 14, 7, 16, 18, 20, 22, 11, 33, 21, 24, 26, 13, 27, 30, 25, 35, 32, 28, 34, 17, 36, 38, 19, 40, 39, 42, 44, 45, 46, 23, 48, 50, 52, 51, 54, 56, 49, 63, 55, 57, 58, 29, 60, 62, 31, 66, 64, 68, 65, 70, 72, 69, 74, 37, 75, 78, 76, 80, 77, 84, 81, 87
Offset: 1

Views

Author

Scott R. Shannon, Nov 19 2021

Keywords

Comments

This sequence shows similar behavior to the EKG sequence A064413. See the linked image.

Examples

			a(3) = 2 as a(2)*3 = 6, 2!=4, 2!=3, 2 is unused and gcd(6,2) > 1.
a(4) = 6 as a(3)*4 = 8, 6!=2, 6!=4, 6 is unused and gcd(8,6) > 1.
		

Crossrefs

Programs

  • Python
    from math import gcd
    terms, appears = [1], {}
    for n in range(2, 100):
        t = 2
        while not(appears.get(t) is None and gcd(terms[-1]*n, t)>1 and t!=terms[-1] and t!=n):
            t += 1
        appears[t] = True; terms.append(t);
    print(terms) # Gleb Ivanov, Nov 20 2021
Showing 1-6 of 6 results.