OFFSET
1,2
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?
LINKS
Michael De Vlieger, Table of n, a(n) for n = 1..10000
Michael De Vlieger, Scatterplot of a(n), n = 1..2^14.
Michael De Vlieger, Log log scatterplot of a(n), n = 1..2^12 showing records in red, local minima in blue, highlighting primes in green, and other prime powers in gold.
Rémy Sigrist, PARI program
EXAMPLE
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.
MATHEMATICA
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 *)
PROG
(PARI) See Links section.
CROSSREFS
KEYWORD
nonn
AUTHOR
David James Sycamore and Michael De Vlieger, Nov 18 2022
STATUS
approved