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-1 of 1 results.

A358488 a(1) = 1, a(2) = 2. Thereafter a(n) is least novel m satisfying: 1. If i = a(n-2) and j = a(n-1) are closed, choose m closed to i and open to j. 2. If i and j are open, choose m closed to h = a(n-3) and open to i + j, unless such a solution does not exist, in which case the constraint that m is closed to h is dropped, leaving a(n) as least novel m open to i + j. See comments.

Original entry on oeis.org

1, 2, 4, 3, 9, 15, 8, 14, 11, 33, 55, 6, 12, 16, 7, 21, 35, 10, 5, 18, 22, 24, 23, 115, 161, 20, 25, 27, 36, 28, 26, 30, 32, 31, 93, 155, 34, 17, 39, 13, 38, 19, 42, 40, 41, 123, 287, 44, 46, 45, 51, 57, 52, 50, 56, 53, 159, 265, 48, 54, 58, 49, 63, 77, 60, 62
Offset: 1

Views

Author

Keywords

Comments

(i,j) "closed" means gcd(i,j) = 1, whereas "open" means gcd(i,j)>1.
When (i,j) is closed condition 1 applies, and a solution for a(n) exists, since we can choose m as any multiple k*p of a prime p which divides j but not i, where k is any number prime to i.
When (i,j) is open condition 2 applies. If there is a prime p which divides i+j but does not divide h, then a solution for a(n) exists. If there is no such prime (rad(i+j)|rad(h)), then there is no number closed to h and open to i+j, so the requirement for (h,a(n))=1 is dropped, whereby a solution for a(n) is assured because there are infinitely many numbers open to i + j. This happens first at a(32), see Example, and occurs a total of 46 times in the first 16000 terms.
a(n) can be derived from its predecessors as the least novel term satisfying the definition, hence the sequence is infinite.
The primes do not appear in natural order (11 precedes 5). Is this a permutation?

Examples

			gcd(a(1),a(2)) = 1, so  a(3) = 4, the least novel m prime to 1 but not to 2.
2, 4 have common divisor 2 so a(4) = 3, the least novel m prime to 1 but not to 2 + 4 = 6.
Since 4 and 3 are coprime, a(5) = 9, the least novel m prime to 4 but not to 3.
The first occurrence of i open to j but rad(i+j) | rad(h) happens at the computation  of a(32), since a(29,30,31) = 36,28,26, and rad(36) = rad(54) = 6. Here we drop the requirement for a(n) to be prime to 36, and require only that it is open to 28 + 26 = 54; thus a(31) is 30.
		

Crossrefs

Programs

  • Mathematica
    Block[{a, c, f, h, i, j, k, u, nn}, nn = 120; c[] = False; f[n] := Times @@ FactorInteger[n][[All, 1]]; Array[Set[{a[#], c[#]}, {#, True}] &, 2]; i = 1; j = 2; u = 3; Do[k = u; Which[CoprimeQ[i, j], While[Nand[! c[k], CoprimeQ[i, k], ! CoprimeQ[j, k]], k++], Divisible[f[h], f[i + j]], While[Nand[! c[k], ! CoprimeQ[i + j, k]], k++], True, While[Nand[! c[k], CoprimeQ[h, k], ! CoprimeQ[i + j, k]], k++] ]; Set[{a[n], c[k], h, i, j}, {k, True, i, j, k}]; If[k == u, While[c[u], u++]], {n, 3, nn}]; Array[a, nn] ] (* Michael De Vlieger, Nov 26 2022 *)
  • PARI
    \\ See Links section.
Showing 1-1 of 1 results.