login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A351626 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 the largest and second largest value of all previous terms. 5
1, 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 15, 22, 24, 26, 28, 30, 21, 32, 34, 36, 38, 40, 42, 35, 44, 33, 46, 48, 50, 45, 52, 54, 39, 56, 58, 60, 62, 64, 66, 68, 51, 70, 72, 63, 74, 76, 78, 57, 80, 65, 75, 82, 84, 86, 88, 90, 55, 92, 69, 94, 96, 98, 100, 102, 85, 104, 106, 108, 110, 99, 105, 112, 77 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,2
COMMENTS
The sequence contains no primes or prime powers other than the powers of 2. As the sequence starts with 2 and 4, these terms being the largest and second largest values, the following terms will be even. This pattern continues until a term equal to the product of two or more odd primes occurs that shares a factor with the previous two largest even values and is smaller than the largest value plus 2. It is not possible for this value to be a prime larger than 2, or a power of such a prime, as the two terms with which it must share a factor differ by 2. It therefore cannot be between them either so it must be less than the second largest even term. Thus the next term after this odd composite must still share a factor with the two largest even values, and this will be the largest value plus 2 or another smaller odd composite. Therefore two more even values eventually become the two largest terms again, and thus the pattern of the two largest even terms, differing by two, interrupted by odd composites continues. Therefore no primes or prime powers other than powers of 2 will occur.
In the first 200000 terms the maximum run of even and odd terms is twelve and seven respectively; it is unknown if these runs have a maximum number of terms or are unbounded. The fixed points beyond 2 in the same range are 573, 597, 633, 6487, 21865, 22115, although it is likely more exist.
LINKS
Scott R. Shannon, Image of the first 200000 terms. The green line is y = n.
EXAMPLE
a(5) = 8 as the largest and second-largest values of all previous terms are a(4) = 6 and a(3) = 4, and 8 is the smallest unused number that shares a factor with both of these values.
a(12) = 15 as the largest and second-largest values of all previous terms are a(11) = 20 and a(10) = 18, and 15 is the smallest unused number that shares a factor with both of these values.
CROSSREFS
Sequence in context: A117463 A248609 A055960 * A007928 A257219 A092451
KEYWORD
nonn
AUTHOR
Scott R. Shannon, May 04 2022
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 19 08:08 EDT 2024. Contains 371782 sequences. (Running on oeis4.)