login
Indices of records in A352187.
4

%I #7 Mar 14 2022 14:03:39

%S 1,2,3,4,6,7,11,12,15,16,19,20,23,25,28,29,34,38,41,45,49,82,141,216,

%T 219,239,266,273,420,610,666,756,841,928,1199,1216,1271,2023,2050,

%U 2584,3090,3818,4934,5744,5752,5780,6040,6052,6155,7559,9006,9419,9611,10114,10205,10605,10818,13539,17136,17992,18172

%N Indices of records in A352187.

%o (Python)

%o from math import gcd

%o from itertools import count, islice

%o from sympy import primefactors

%o def A352192_gen(): # generator of terms

%o bset, blist, mmax, c = {1,2}, [1,2], 3, 2

%o yield from blist

%o for n in count(3):

%o for m in count(mmax):

%o if gcd(m,blist[-1]) > 1 and m not in bset:

%o if all(blist[-2] % p == 0 for p in primefactors(blist[-1])) or gcd(m,blist[-2]) == 1:

%o if m > c:

%o yield n

%o c = m

%o blist = [blist[-1],m]

%o bset.add(m)

%o while mmax in bset:

%o mmax += 1

%o break

%o A352192_list = list(islice(A352192_gen(),30)) # _Chai Wah Wu_, Mar 14 2022

%Y Cf. A352187, A352191.

%K nonn

%O 1,2

%A _N. J. A. Sloane_, Mar 13 2022