OFFSET
1,1
COMMENTS
If a(i) = prime(j), then a(j) <= prime(i). - Rémy Sigrist, Mar 03 2018. [Note that this does not imply that a prime p always exists! In fact if r and s are large primes, r*s will surely contain a nonprime digit, although this kind of question is beyond the reach of present-day mathematics. - N. J. A. Sloane, Mar 03 2018]
LINKS
Harvey P. Dale, Table of n, a(n) for n = 1..1000
EXAMPLE
11 is the smallest prime such that 11*prime(1)=22 consists of only prime digits. Therefore a(1) = 11.
MATHEMATICA
p[n_] := Module[{k = 1}, While[Union[PrimeQ /@ IntegerDigits[n*Prime[k]]] != {True}, k++]; Prime[k]]; p /@ Prime[Range[100]]
spp[p_]:=Module[{k=2}, While[AnyTrue[IntegerDigits[p*k], !PrimeQ[#]&], k=NextPrime[k]]; k]; Table[spp[p], {p, Prime[Range[70]]}] (* Harvey P. Dale, Jun 20 2023 *)
PROG
(PARI) a(n) = {forprime(p=2, , if (#select(x->(! isprime(x)), digits(p*prime(n))) == 0, return (p)); ); } \\ Michel Marcus, Mar 02 2018
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Ivan N. Ianakiev, Mar 02 2018
EXTENSIONS
Escape clause added to definition by N. J. A. Sloane, Mar 03 2018
STATUS
approved