OFFSET
1,2
LINKS
Vincenzo Librandi, Table of n, a(n) for n = 1..1000
FORMULA
a(n) = A165682(n)-1. - R. J. Mathar, Jan 04 2011
EXAMPLE
for n=10, 10+1=11 and 11^3-10^3=331; n=28, 28+1=29 and 29^3-28^3=2437
MATHEMATICA
Select[Range[1500], PrimeQ[# + 1]&&PrimeQ[(# + 1)^3 - #^3]&] (* Vincenzo Librandi, Apr 05 2013 *)
PROG
(Magma) [n: n in [1..1500] | IsPrime(n+1) and IsPrime( (n+1)^3-n^3)]; // Vincenzo Librandi, Apr 05 2013
(PARI) is(n)=isprime(n+1) && isprime(3*n^3+3*n+1) \\ Charles R Greathouse IV, Jun 13 2017
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Vincenzo Librandi, Dec 09 2009
STATUS
approved