OFFSET
1,1
COMMENTS
A301274(k) != k implies that k is a term of this sequence.
Conjecture: a(n) ~ C*n as n -> infinity, where 5.25 < C < 5.35.
EXAMPLE
18 is a term of this sequence since the sum of the first 18 primes is 501 and GCD(501,18) = 3 != 1.
MATHEMATICA
s[n_] := Sum[Prime[k], {k, 1, n}];
Complement[Table[n, {n, 1, 1000}], Flatten[Position[Table[GCD[s[n], n], {n, 1, 1000}], 1]]]
PROG
(PARI) isok(k) = gcd(vecsum(primes(k)), k) != 1; \\ Michel Marcus, Mar 18 2023
(Python)
from math import gcd
from itertools import count, islice
from sympy import nextprime
def A361627_gen(): # generator of terms
p, s = 2, 2
for n in count(1):
if gcd(n, s) > 1:
yield n
s += (p:=nextprime(p))
CROSSREFS
KEYWORD
nonn
AUTHOR
Luca Onnis, Mar 18 2023
STATUS
approved