cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A210514 Prime numbers generated by concatenating k, k, and 9.

This page as a plain text file.
%I A210514 #27 Jul 26 2022 21:58:58
%S A210514 229,449,11119,14149,22229,28289,31319,37379,44449,49499,52529,56569,
%T A210514 67679,70709,71719,80809,86869,89899,94949,95959,1061069,1101109,
%U A210514 1131139,1151159,1161169,1191199,1241249,1251259,1331339,1401409,1431439,1481489,1571579,1601609
%N A210514 Prime numbers generated by concatenating k, k, and 9.
%C A210514 This series is similar to A030458 and A052089.
%C A210514 Base considered is 10.
%H A210514 Michael S. Branicky, <a href="/A210514/b210514.txt">Table of n, a(n) for n = 1..10000</a>
%e A210514 For k=2, a(1)= 229.
%e A210514 For k=4, a(2)= 449.
%e A210514 For k=11, a(3)= 11119.
%e A210514 For k=14, a(4)= 14149.
%t A210514 Select[Table[FromDigits[Flatten[Join[IntegerDigits/@{n,n},{9}]]],{n,200}],PrimeQ] (* _Harvey P. Dale_, Apr 23 2015 *)
%o A210514 (Python)
%o A210514 import numpy as np
%o A210514 from functools import reduce
%o A210514 def factors(n):
%o A210514     return reduce(list.__add__, ([i, n//i] for i in range(1, int(n**0.5) + 1) if n % i == 0))
%o A210514 for i in range(1, 2000):
%o A210514     p1=int(str(i)+str(i)+"1")
%o A210514     if len(factors(p1))<3:
%o A210514         print(p1, end=',')
%o A210514 (Python)
%o A210514 from sympy import isprime
%o A210514 from itertools import count, islice
%o A210514 def agen(): yield from filter(isprime, (int(str(k)+str(k)+'9') for k in count(1)))
%o A210514 print(list(islice(agen(), 34))) # _Michael S. Branicky_, Jul 26 2022
%Y A210514 Cf. A030458, A052089.
%K A210514 base,nonn,easy
%O A210514 1,1
%A A210514 _Abhiram R Devesh_, Jan 26 2013
%E A210514 a(27) and beyond from _Michael S. Branicky_, Jul 26 2022