Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).
%I #26 Feb 01 2021 18:29:49
%S 10,16,18,22,24,30,34,36,42,46,48,54,60,64,66,72,76,78,84,90,102,106,
%T 108,112,114,120,126,132,138,142,144,150,154,156,162,168,174,180,184,
%U 186,192,196,198,202,204,210,216,222,228,232,234,240,244,246,252,258,264,270,274,276,282,286
%N Numbers having at least two different ordered partitions p+q and (p+2)+(q-2) where p, q, p+2 and q-2 are all prime.
%C Numbers k with at least one pair of externally tangent circles with radius sqrt(2) and center (p,q) where p and q are prime, p + q = k and p <= q. - _Wesley Ivan Hurt_, Aug 11 2020
%e For n=10, the partition solutions are 3+7 and 5+5, giving p=3, q=7, p+2=5, q-2=5.
%p isA187797 := proc(n)
%p local i,p,q ;
%p for i from 1 do
%p p := ithprime(i) ;
%p q := n-p ;
%p if q <= p+2 then
%p return false;
%p end if;
%p if isprime(q) then
%p if isprime(p+2) and isprime(q-2) then
%p return true;
%p end if;
%p end if;
%p end do:
%p return false;
%p end proc:
%p for n from 4 to 600 do
%p if isA187797(n) then
%p printf("%d,",n);
%p end if;
%p end do: # _R. J. Mathar_, Oct 03 2013
%t Table[If[Sum[(PrimePi[i] - PrimePi[i - 1]) (PrimePi[2 n - i] - PrimePi[2 n - i - 1]) (PrimePi[i + 2] - PrimePi[i + 1]) (PrimePi[2 n - i - 2] - PrimePi[2 n - i - 3]), {i, n - 2}] > 0, 2 n, {}], {n, 100}] // Flatten (* _Wesley Ivan Hurt_, Apr 13 2020 *)
%K nonn
%O 1,1
%A _Bob Gilson_, Aug 30 2013