|
|
A331346
|
|
Primes using all the square digits {0, 1, 4, 9} and no others.
|
|
1
|
|
|
1049, 1409, 4019, 4091, 9041, 10499, 10949, 14009, 49019, 49109, 90149, 90401, 94109, 99041, 99401, 100049, 101149, 101419, 101449, 104009, 104119, 104149, 104491, 104911, 104999, 109049, 109141, 109441, 110419, 110491, 111049, 111409, 114901, 140009, 140191, 140419
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,1
|
|
COMMENTS
|
|
|
LINKS
|
|
|
EXAMPLE
|
a(1) = 1049 is prime containing all the square digits (0, 1, 4, 9) and no others.
a(2) = 1409 is prime containing all the square digits (0, 1, 4, 9) and no others.
|
|
MAPLE
|
f:= proc(n) local L, x;
L:= convert(n, base, 4);
if convert(L, set) <> {0, 1, 2, 3} then return NULL fi;
L:= subs(2=4, 3=9, L);
x:= add(L[i]*10^(i-1), i=1..nops(L));
if isprime(x) then x else NULL fi
end proc:
|
|
MATHEMATICA
|
Select[FromDigits /@ Tuples[{0, 1, 4, 9}, 6], PrimeQ[#] && Union[IntegerDigits[#]] == {0, 1, 4, 9} &]
|
|
PROG
|
(Magma) [p:p in PrimesUpTo(150000)|Set(Intseq(p)) eq {0, 1, 4, 9}]; // Marius A. Burtea, Jan 14 2020
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn,base
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|