OFFSET
1,2
COMMENTS
a(n) always exists. Proof: let p_1 < p_2 < ... < p_k, we can prove p_k <= 2*n^2 + n. If p_k > 2*n^2 + n, then 2*p_k > p_i + n, thus p_k - n is in the set. If p_k - m*n is in the set and m < n, then 2*(p_k - m*n) > p_i + n, thus p_k - (m+1)*n is in the set. Therefore, p_k - m*n are in the set for 0 <= m <= n. Since p_k - n*n > n + 1, p_k - m*n can be divisible by n + 1 for some m <= n, which is a contradiction to the p_i being primes.
EXAMPLE
For n = 3, {3}, {2, 3}, {2, 5} and {2, 3, 5} are such sets, thus a(3) = 4.
PROG
(PARI) a(n, k=primepi(2*n^2+n)) = {my(c=-1, p=primes(k)); forsubset(k, v, if(vecprod(vector(#v, i, p[v[i]]+n))%vecprod(vector(#v, i, p[v[i]])) == 0, c++)); c; }
CROSSREFS
KEYWORD
nonn,more
AUTHOR
Jinyuan Wang, May 10 2020
STATUS
approved