A032667 Digit '4' concatenated with a(n) is a prime.
1, 3, 7, 19, 21, 31, 33, 39, 43, 49, 57, 61, 63, 67, 79, 87, 91, 99, 111, 127, 129, 133, 139, 153, 157, 159, 177, 201, 211, 217, 219, 229, 231, 241, 243, 253, 259, 261, 271, 273, 283, 289, 297, 327, 337, 339, 349, 357, 363, 373, 391, 397, 409
Offset: 1
Examples
Concatenate 4 and 1 to get 41, which is prime, so 1 is in the sequence. Concatenate 4 and 3 to get 43, which is prime, so 3 is in the sequence. Concatenate 4 and 5 to get 45 = 3^2 * 5, which is not prime, so 5 is not in the sequence.
Links
- Seiichi Manyama, Table of n, a(n) for n = 1..10000 (terms 1..1740 from Vincenzo Librandi)
Crossrefs
Programs
-
Mathematica
Select[2Range[250] - 1, PrimeQ[FromDigits[Join[{4}, IntegerDigits[#]]]] &] (* Alonso del Arte, Jun 18 2017 *)
-
PARI
isok(n) = isprime(eval(concat(4, Str(n)))); \\ Michel Marcus, Jun 19 2017
Extensions
Offset adjusted at the suggestion of Michel Marcus by Alonso del Arte, Jun 18 2017
Comments