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

 

Logo

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 56th year, we are closing in on 350,000 sequences, and we’ve crossed 9,700 citations (which often say “discovered thanks to the OEIS”).

Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A034302 Zeroless primes that remain prime if any digit is deleted. 15
23, 37, 53, 73, 113, 131, 137, 173, 179, 197, 311, 317, 431, 617, 719, 1499, 1997, 2239, 2293, 3137, 4919, 6173, 7433, 9677, 19973, 23833, 26833, 47933, 73331, 74177, 91733, 93491, 94397, 111731, 166931, 333911, 355933, 477797, 477977 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,1

LINKS

Chai Wah Wu, Table of n, a(n) for n = 1..118 (terms 1..79 from T. D. Noe, terms 80..103 from Charles R Greathouse IV)

StackExchange, Deleting any digit yields a prime

MATHEMATICA

rpnzQ[n_]:=Module[{idn=IntegerDigits[n]}, Count[idn, 0]==0 && And@@ PrimeQ[FromDigits/@Subsets[IntegerDigits[n], {Length[idn]-1}]]]; Select[Prime[Range[40000]], rpnzQ]  (* Harvey P. Dale, Mar 24 2011 *)

PROG

(Haskell)

import Data.List (inits, tails)

a034302 n = a034302_list !! (n-1)

a034302_list = filter f $ drop 4 a038618_list where

   f x = all (== 1) $ map (a010051 . read) $

             zipWith (++) (inits $ show x) (tail $ tails $ show x)

-- Reinhard Zumkeller, Dec 17 2011

(PARI) is(n)=my(d=digits(n), t=2^#d-1); if(vecmin(d)==0, return(0)); for(i=0, #d-1, if(!isprime(fromdigits(vecextract(d, t-2^i))), return(0))); isprime(n) \\ Charles R Greathouse IV, Jun 23 2017

(Python)

from itertools import product

from sympy import isprime

A034302_list, m = [23, 37, 53, 73], 7

for l in range(1, m-1): # generate all terms less than 10^m

    for d in product('123456789', repeat=l):

        for e in product('1379', repeat=2):

            s = ''.join(d+e)

            if isprime(int(s)):

                for i in range(len(s)):

                    if not isprime(int(s[:i]+s[i+1:])):

                        break

                else:

                    A034302_list.append(int(s)) # Chai Wah Wu, Apr 05 2021

CROSSREFS

Cf. A034303, A034304, A034305, A051362, A010051, A038618.

Sequence in context: A057876 A244282 A051362 * A057878 A019549 A272157

Adjacent sequences:  A034299 A034300 A034301 * A034303 A034304 A034305

KEYWORD

base,nonn,nice

AUTHOR

David W. Wilson

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 November 30 05:12 EST 2021. Contains 349419 sequences. (Running on oeis4.)