OFFSET
1,1
COMMENTS
If k is in the sequence, then all composite divisors of k are in the sequence. - Robert Israel, Jul 11 2019
LINKS
Robert Israel, Table of n, a(n) for n = 1..10000
EXAMPLE
254 has divisors 1, 2, 127 and 254, all of which except for 1 contain the digit 2.
MAPLE
filter:= proc(n) local D;
if isprime(n) then return false fi;
andmap(con2, numtheory:-divisors(n) minus {1})
end proc:
con2:= proc(n) option remember; member(2, convert(n, base, 10)) end proc:
select(filter, [$4..10000]); # Robert Israel, Jul 11 2019
MATHEMATICA
fQ[n_, dgt_] := Union[ MemberQ[#, dgt] & /@ IntegerDigits@ Rest@ Divisors@ n][[1]]; Select[ Range[2, 4230], !PrimeQ[#] && fQ[#, 2] &] (* Robert G. Wilson v, Jun 11 2014 *)
PROG
(Magma) [m:m in [2..4300] | not IsPrime(m) and #[d:d in Divisors(m)|2 in Intseq(d)] eq #Divisors(m)-1]; // Marius A. Burtea, Jul 11 2019
CROSSREFS
KEYWORD
base,easy,nonn
AUTHOR
Erich Friedman, Jul 04 2001
EXTENSIONS
Offset changed by Robert Israel, Jul 11 2019
STATUS
approved