login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 


Numbers that are the product of two distinct primes a and b, such that a^3+b^3 is the average of a twin prime pair.
5

%I #9 Apr 10 2019 02:54:33

%S 143,215,341,485,515,551,713,1133,1241,1271,1541,1865,2183,2315,2501,

%T 3173,3215,3503,3713,4031,4661,5465,5633,6431,6485,7313,7361,7571,

%U 8201,8471,9353,9599,9713,9893,12083,12371,12443,12449,13361,13631,14711

%N Numbers that are the product of two distinct primes a and b, such that a^3+b^3 is the average of a twin prime pair.

%C All terms == 5 (mod 6). - _Robert Israel_, Apr 09 2019

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

%e 143=11*13; 11^3+13^3=3528+-1 -> primes,...

%p N:= 20000: # to get all terms <= N

%p P1:= select(isprime, [seq(i,i=7..N/5,6)]):n1:= nops(P1):

%p P2:= select(isprime, [seq(i,i=5..N/7,6)]):n2:= nops(P2):

%p Res:= NULL:

%p for i from 1 to n1 do

%p a:= P1[i];

%p for j from 1 to n2 do

%p b:= P2[j];

%p if a*b > N then break fi;

%p q:= a^3 + b^3;

%p if isprime(q-1) and isprime(q+1) then Res:= Res, a*b fi;

%p od

%p od:

%p sort([Res]); # _Robert Israel_, Apr 09 2019

%t l[n_]:=Last/@FactorInteger[n]; f[n_]:=First/@FactorInteger[n]; lst={};Do[If[l[n]=={1,1},a=f[n][[1]];b=f[n][[2]];If[PrimeQ[a^3+b^3-1]&&PrimeQ[a^3+b^3+1],AppendTo[lst,n]]],{n,8!}];lst

%Y Cf. A006881, A014574, A176875

%K nonn

%O 1,1

%A _Vladimir Joseph Stephan Orlovsky_, Apr 27 2010

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified September 20 17:28 EDT 2024. Contains 376075 sequences. (Running on oeis4.)