login
The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A199327 Primes with digits '0', '1' and '7' only. 5
7, 11, 17, 71, 101, 107, 701, 1117, 1171, 1777, 7001, 7177, 7717, 10007, 10111, 10177, 10711, 10771, 11071, 11117, 11171, 11177, 11701, 11717, 11777, 17011, 17077, 17107, 17117, 17707, 70001, 70111, 70117, 70177, 70717, 71011, 71171, 71707, 71711, 71777, 77017, 77101, 77171, 77711, 101107, 101111, 101117 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,1

LINKS

Harvey P. Dale, Table of n, a(n) for n = 1..10000

James Maynard and Brady Haran, Primes without a 7, Numberphile video (2019).

MATHEMATICA

f[i_, nn_]:=Select[Flatten[Table[FromDigits/@(Join[{i}, #]&/@Tuples[ {0, 1, 7}, n]), {n, 0, nn}]], PrimeQ]; Union[Join[f[1, 6], f[7, 6]]] (* Harvey P. Dale, Nov 19 2011 *)

Select[Prime[Range[2 10^4]], Complement[IntegerDigits[#], {0, 1, 7}]=={}&] (* Vincenzo Librandi, Jan 16 2020 *)

PROG

(PARI) a(n, list=0, L=[0, 1, 7])={for(d=1, 1e9, my(t, u=vector(d, i, 10^(d-i))~); forvec(v=vector(d, i, [1+!(L[1]||(i>1&&i<d)), #L]), ispseudoprime( t=vecextract(L, v)*u)||next; list&&print1(t", "); n--||return(t)))} \\ Syntax updated for newer PARI versions by M. F. Hasler, Jul 26 2015

(MAGMA) [p: p in PrimesUpTo(80000) | Intseq(p) subset {0, 1, 7}]; // Vincenzo Librandi, Jan 16 2020

CROSSREFS

Cf. A020449 - A020472, A036953, A260044, A260267 - A260271, A199325 - A199329, A061247, A199340 - A199349.

Sequence in context: A167513 A260891 A276039 * A260892 A020455 A178617

Adjacent sequences:  A199324 A199325 A199326 * A199328 A199329 A199330

KEYWORD

nonn,base

AUTHOR

M. F. Hasler, Nov 05 2011

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified September 29 17:04 EDT 2020. Contains 337432 sequences. (Running on oeis4.)