%I #8 Feb 08 2021 02:57:22
%S 0,0,0,1,2,1,0,2,3,0,2,5,0,0,5,0,2,5,0,0,3,0,2,6,0,1,6,0,0,9,0,2,4,1,
%T 0,4,0,4,7,0,2,9,0,0,13,0,0,2,2,1,8,0,4,6,2,5,14,0,0,17,0,0,10,1,0,8,
%U 0,2,7,2,4,11,0,0,14,1,2,6,0,2,7,0,0,12,0,1,8,0,0,14,0,4,9,2,2,6,2
%N a(k) is the number of pairs of consecutive primes (p,q) such that (2*k-q,2*k-p) is also a pair of consecutive primes.
%H Robert Israel, <a href="/A341237/b341237.txt">Table of n, a(n) for n = 1..10000</a>
%e a(9) = 3 because (5,7), (7,11) and (11,13) are pairs of consecutive primes (p,q) with (18-q,18-p) = (11,13), (7,11) and (5,7) also consecutive primes.
%p f:= proc(n) local p,q,count;
%p q:= 2: count:= 0:
%p while q < 2*n -2 do
%p p:= q; q:= nextprime(q);
%p if isprime(2*n-p) and prevprime(2*n-p)=2*n-q then count:= count+1 fi;
%p od;
%p count
%p end proc:
%p map(f, [$1..100]);
%Y Cf. A002372.
%K nonn
%O 1,5
%A _J. M. Bergot_ and _Robert Israel_, Feb 07 2021