login
a(n) is the number of primes that divide at least one of the numbers prime(n)-prime(k) for 1 <= k < n.
2

%I #10 Jan 19 2021 21:02:26

%S 0,0,2,2,2,4,4,4,4,5,6,6,8,7,6,7,8,8,8,9,9,10,8,11,12,10,10,10,13,13,

%T 13,13,14,14,14,15,15,16,15,13,17,17,16,18,16,17,18,20,15,21,20,21,20,

%U 20,21,19,22,22,21,24,22,21,24,23,24,22,25,28,22,26,25,24,26,28,23,25,28,28,30,30

%N a(n) is the number of primes that divide at least one of the numbers prime(n)-prime(k) for 1 <= k < n.

%C Numbers not in the sequence appear to include 1, 3, 27, 51, 108, 218, 392, 486, 937.

%C a(n) >= the number of m with A340752(m) <= prime(n).

%H Robert Israel, <a href="/A340743/b340743.txt">Table of n, a(n) for n = 1..10000</a>

%e For n=6 the a(6) = 4 primes are 2, 3, 5 and 11: 2 divides all but 13-2, 3 divides 13-8, 5 divides 13-3 and 11 divides 13-2.

%p f:= proc(n) local L,P,i,t;

%p L:= [seq(ithprime(n)-ithprime(i),i=1..n-1)];

%p P:= `union`(seq(numtheory:-factorset(t),t=L));

%p nops(P)

%p end proc:

%p map(f, [$1..100]);

%K nonn

%O 1,3

%A _J. M. Bergot_ and _Robert Israel_, Jan 18 2021