[seqfan] Re: both n and n^2 use just digits (2,3,5,7}

Charles Greathouse charles.greathouse at case.edu
Thu Aug 18 16:04:16 CEST 2016


If there are any others they must be larger than 10^30.

default(parisizemax,2^31)
has(n)=#setminus(Set(digits(lift(n^2))),[2,3,5,7])==0
step(v)=my(u=List(),K=10^#digits(v[1]),K1=10*K);forstep(d=2*K,9*K,[K,4*K,2*K],for(i=1,#v,if(has(Mod(v[i]+d,K1)),listput(u,v[i]+d))));Vec(u)
v=[2,3,5,7]; for(n=2,30, v=step(v); u=select(k->has(k),v); if(#u,
print("*** "u)); print(n" "#v))

Charles Greathouse
Case Western Reserve University

On Mon, Aug 15, 2016 at 7:35 AM, Zak Seidov <seqfan at list.seqfan.eu> wrote:

>  Are {5,235,72335}
> the only numbers n
> such that  both n and n^2 use just digits (2,3,5,7}?
> Cf. A191486, A275971.
> zak
>
> --
> Seqfan Mailing list - http://list.seqfan.eu/
>


More information about the SeqFan mailing list