login
Primes that remain prime through 2 iterations of function f(x) = 7x + 6.
4

%I #25 Jan 26 2024 15:41:30

%S 5,11,31,59,61,71,149,179,269,439,499,541,571,719,761,1049,1091,1181,

%T 1319,1451,1489,1579,1601,1831,1861,1879,1949,2069,2089,2269,2311,

%U 2389,2441,2621,2699,2819,2851,2909,3001,3079,3119,3391,3529,3631,3701,3709

%N Primes that remain prime through 2 iterations of function f(x) = 7x + 6.

%C Primes p such that 7*p+6 and 49*p+48 are also primes. - _Vincenzo Librandi_, Aug 04 2010

%H John Cerkan, <a href="/A023259/b023259.txt">Table of n, a(n) for n = 1..10000</a>

%F a(n) = 1 or 9 (mod 10) for n > 1. - _John Cerkan_, Sep 14 2016

%t Select[Prime[Range[600]],AllTrue[Rest[NestList[7#+6&,#,2]],PrimeQ]&] (* _Harvey P. Dale_, Jan 26 2024 *)

%o (Magma) [n: n in [1..100000] | IsPrime(n) and IsPrime(7*n+6) and IsPrime(49*n+48)] // _Vincenzo Librandi_, Aug 04 2010

%Y Subsequence of A023225, A024900. - _John Cerkan_, Sep 14 2016

%K nonn

%O 1,1

%A _David W. Wilson_