This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A284950 #15 Jul 21 2020 06:02:23 %S A284950 0,0,0,1,1,1,1,1,1,1,0,2,1,0,3,0,1,3,0,1,3,1,0,3,1,0,3,1,0,5,0,1,4,0, %T A284950 1,3,0,1,4,0,0,4,1,0,6,0,0,4,0,1,2,1,1,4,1,0,4,0,0,9,0,0,5,0,0,5,1,0, %U A284950 4,0,0,5,0,0,6,0,1,5,0,1,5,0,0,7,1,0,5,1,0,7,0,0,6,0,0,4,1,1,4,0 %N A284950 Number of primes p <= n such that 2*n-p and 2*n+p are prime. %C A284950 If n is not divisible by 3, a(n)<=1, as the only possible p is 3. - _Robert Israel_, Jul 20 2020 %H A284950 Robert Israel, <a href="/A284950/b284950.txt">Table of n, a(n) for n = 1..10000</a> %e A284950 a(5) is 1, because of all the pairs of primes p1 <= p2 which sum to 5*2=10, namely {3,7} and {5,5}, only (3,7) has p1+10 prime. %p A284950 f:= proc(n) local p1,p2,t; %p A284950 t:= 0: p1:= 2: %p A284950 do %p A284950 p1:= nextprime(p1); %p A284950 if p1 > n then return t fi; %p A284950 if isprime(p1+2*n) and isprime(2*n-p1) then %p A284950 t:= t+1 %p A284950 fi %p A284950 od %p A284950 end proc: %p A284950 map(f, [$1..1000]); # _Robert Israel_, Jul 20 2020 %t A284950 For[i = 1, i < 1001, i++, %t A284950 ee = 2*i; %t A284950 a = 0; %t A284950 For[j = 3, j < ee/2, j += 2, %t A284950 If[PrimeQ[j] == True && PrimeQ[ee - j] == True, %t A284950 If[PrimeQ[ee + j] == True, a += 1, a = a]]]; %t A284950 Print[ee, " ", a]] %Y A284950 Cf. A237885, A284919, A284928. %K A284950 nonn,look %O A284950 1,12 %A A284950 _Neil Fernandez_, Apr 06 2017 %E A284950 Definition corrected by _Robert Israel_, Jul 20 2020