cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A383749 Positive numbers k whose decimal expansion does not contain the decimal expansion of any proper divisor of k.

This page as a plain text file.
%I A383749 #23 May 12 2025 14:00:57
%S A383749 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,
%T A383749 68,69,73,74,76,78,79,83,86,87,89,94,97,98,203,207,209,223,227,229,
%U A383749 233,239,247,249,253,257,259,263,267,269,277,283,289,293,299,307
%N A383749 Positive numbers k whose decimal expansion does not contain the decimal expansion of any proper divisor of k.
%C A383749 Also fixed points of A121042.
%C A383749 This sequence is infinite as it contains A173041.
%C A383749 a(n) > 5 contains no decimal digit 1 and does not end in 2 or 5. - _Michael S. Branicky_, May 11 2025
%H A383749 Rémy Sigrist, <a href="/A383749/b383749.txt">Table of n, a(n) for n = 1..10000</a>
%e A383749 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.
%t A383749 A383749Q[k_] := SelectFirst[Divisors[k], StringContainsQ[IntegerString[k], IntegerString[#]] &] == k;
%t A383749 Select[Range[500], A383749Q] (* _Paolo Xausa_, May 12 2025 *)
%o A383749 (PARI) is(n, base = 10) = {
%o A383749     my (d = digits(n, base));
%o A383749     for (i = 1, #d,
%o A383749         if (d[i],
%o A383749             for (j = i, #d,
%o A383749                 if ((i!=1 || j!=#d) && n % fromdigits(d[i..j], base)==0,
%o A383749                     return (0);););););
%o A383749     return (1);}
%o A383749 (Python)
%o A383749 from itertools import count, islice
%o A383749 from sympy import divisors
%o A383749 def A383749_gen(startvalue=1): # generator of terms >= startvalue
%o A383749     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)))
%o A383749 A383749_list = list(islice(A383749_gen(),40)) # _Chai Wah Wu_, May 10 2025
%o A383749 (Python)
%o A383749 def ok(n):
%o A383749     s = str(n)
%o A383749     subs = (s[i:j] for i in range(len(s)) for j in range(i+1, len(s)+1) if s[i]!='0')
%o A383749     return n and not any(n%v == 0 for ss in subs if n > (v:=int(ss)) > 0)
%o A383749 print([k for k in range(308) if ok(k)]) # _Michael S. Branicky_, May 11 2025
%Y A383749 Cf. A011531, A027751, A038772, A121042, A383592.
%Y A383749 A038603 and A173041 are subsequences.
%K A383749 nonn,base
%O A383749 1,2
%A A383749 _Rémy Sigrist_, May 08 2025