OFFSET
1,1
LINKS
Vincenzo Librandi, Table of n, a(n) for n = 1..1000
FORMULA
a(n) = x^3-(x-1)^3 where x = A165682(n).
EXAMPLE
a(3)= 61=3*5*(5-1)+1 generated by p=3. a(4)=127=3*7*(7-1)+1 generated by p=7. a(5)=331=3*11*(11-1)+1.
MATHEMATICA
Select[Table[3 p (p - 1) + 1, {p, Prime[Range[100]]}], PrimeQ] (* Vincenzo Librandi, Sep 13 2013 *)
PROG
(Magma) [a: p in PrimesUpTo(1000) | IsPrime(a) where a is 3*p*(p-1)+1]; // Vincenzo Librandi, Sep 13 2013 *
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Vincenzo Librandi, Sep 24 2009
EXTENSIONS
7 and 19 inserted by R. J. Mathar, Sep 26 2009
STATUS
approved