login
Numbers whose cubes are exclusionary: numbers k such that k has no repeated digits and k and k^3 have no digits in common.
3

%I #22 Sep 06 2021 19:00:37

%S 2,3,7,8,27,43,47,48,52,53,63,68,92,157,172,187,192,263,378,408,423,

%T 458,468,478,487,527,587,608,648,692,823,843,918,1457,1587,1592,4657,

%U 4732,5692,6058,6378,7658

%N Numbers whose cubes are exclusionary: numbers k such that k has no repeated digits and k and k^3 have no digits in common.

%C A number k with no repeated digits has an exclusionary cube k^3 if the latter is made up of digits not appearing in k. (This is a subsequence of A029785.) For the corresponding exclusionary cubes see A112993. Conjectured to be complete.

%C Data are complete: there are 42 terms. - _Michael S. Branicky_, Aug 27 2021

%D H. Ibstedt, Solution to Problem 2623, "Exclusionary Powers", pp. 346-9, Journal of Recreational Mathematics, vol. 32 No.4 2003-4, Baywood NY.

%D Clifford A. Pickover, A Passion for Mathematics, Wiley, 2005; see p. 60.

%H Clifford A. Pickover, <a href="http://sprott.physics.wisc.edu/Pickover/extremec.html">Extreme Challenges in Mathematics and Morals</a>

%t Select[Range[8000],Max[DigitCount[#]]==1&&Intersection[IntegerDigits[ #],IntegerDigits[#^3]]=={}&] (* _Harvey P. Dale_, Sep 06 2021 *)

%o (PARI) isok(n) = my(digs = digits(n)); (#digs == #Set(digs)) && (#setintersect(Set(digs), Set(digits(n^3))) == 0); \\ _Michel Marcus_, Oct 26 2013

%o (Python)

%o def ok(n):

%o s = str(n)

%o return len(s) == len(set(s)) and set(s) & set(str(n**3)) == set()

%o print([k for k in range(7659) if ok(k)]) # _Michael S. Branicky_, Aug 27 2021

%o (Python) # version for verifying full sequence

%o from itertools import permutations

%o def no_repeated_digits():

%o for d in range(1, 11):

%o for p in permutations("0123456789", d):

%o if p[0] == '0': continue

%o yield int("".join(p))

%o def afull():

%o alst = []

%o for k in no_repeated_digits():

%o if set(str(k)) & set(str(k**3)) == set():

%o alst.append(k)

%o return alst

%o print(afull()) # _Michael S. Branicky_, Aug 27 2021

%Y Subsequence of A029785.

%Y The corresponding cubes are in A112993.

%K nonn,base,fini,full

%O 1,1

%A _Lekraj Beedassy_, Oct 13 2005

%E Missing term 468 added by _N. J. A. Sloane_, May 22 2008

%E Definition clarified by _Harvey P. Dale_, Sep 06 2021