login
A383749
Positive numbers k whose decimal expansion does not contain the decimal expansion of any proper divisor of k.
2
1, 2, 3, 4, 5, 6, 7, 8, 9, 23, 27, 29, 34, 37, 38, 43, 46, 47, 49, 53, 54, 56, 57, 58, 59, 67, 68, 69, 73, 74, 76, 78, 79, 83, 86, 87, 89, 94, 97, 98, 203, 207, 209, 223, 227, 229, 233, 239, 247, 249, 253, 257, 259, 263, 267, 269, 277, 283, 289, 293, 299, 307
OFFSET
1,2
COMMENTS
Also fixed points of A121042.
This sequence is infinite as it contains A173041.
a(n) > 5 contains no decimal digit 1 and does not end in 2 or 5. - Michael S. Branicky, May 11 2025
LINKS
EXAMPLE
The proper divisors of 54 are 1, 2, 3, 6, 9, 18 and 27; none of them appear in the decimal expansion of 54 so 54 belongs to this sequence.
MATHEMATICA
A383749Q[k_] := SelectFirst[Divisors[k], StringContainsQ[IntegerString[k], IntegerString[#]] &] == k;
Select[Range[500], A383749Q] (* Paolo Xausa, May 12 2025 *)
PROG
(PARI) is(n, base = 10) = {
my (d = digits(n, base));
for (i = 1, #d,
if (d[i],
for (j = i, #d,
if ((i!=1 || j!=#d) && n % fromdigits(d[i..j], base)==0,
return (0); ); ); ); );
return (1); }
(Python)
from itertools import count, islice
from sympy import divisors
def A383749_gen(startvalue=1): # generator of terms >= startvalue
return filter(lambda n:not any(d<n and str(d) in str(n) for d in divisors(n, generator=True)), count(max(startvalue, 1)))
A383749_list = list(islice(A383749_gen(), 40)) # Chai Wah Wu, May 10 2025
(Python)
def ok(n):
s = str(n)
subs = (s[i:j] for i in range(len(s)) for j in range(i+1, len(s)+1) if s[i]!='0')
return n and not any(n%v == 0 for ss in subs if n > (v:=int(ss)) > 0)
print([k for k in range(308) if ok(k)]) # Michael S. Branicky, May 11 2025
CROSSREFS
A038603 and A173041 are subsequences.
Sequence in context: A061672 A272814 A322516 * A132080 A307636 A373722
KEYWORD
nonn,base
AUTHOR
Rémy Sigrist, May 08 2025
STATUS
approved