%I #13 May 31 2018 12:28:18
%S 1,2,3,4,5,6,7,8,9,25,36,64,128,175,384,735,768,784,1296,1764,2916,
%T 3675,5625,7938,18432,28672,34992,36864,39366,46656,69984,82944,96768,
%U 139968,165375,236196,275625,297675,354375,442368,497664,524288,589824,746496
%N Numbers n such that the product of the squares of digits of n is nonzero and divisible by n.
%C There are 325 terms below 10^200, with the largest one having 83 decimal digits. - _Max Alekseyev_, May 31 2018
%H Max Alekseyev, <a href="/A128606/b128606.txt">Table of n, a(n) for n = 1..325</a>
%p P:=proc(n) local i,k,w; for i from 1 by 1 to n do w:=1; k:=i; while k>0 do w:=w*(k-(trunc(k/10)*10))^2; k:=trunc(k/10); od; if w>0 then if trunc(w/i)=w/i then print(i); fi; fi; od; end: P(1000000);
%t fQ[n_] := Block[{d = Times @@ (IntegerDigits[n]^2)}, And[d != 0, Mod[d, n] == 0]]; Select[Range@ 1000000, fQ] (* _Michael De Vlieger_, Apr 29 2015 *)
%o (PARI) for(n=1,10^6,d=digits(n);p=prod(i=1,#d,d[i]);if(p&&!(p^2%n),print1(n,", "))) \\ _Derek Orr_, Apr 29 2015
%Y Cf. A007954.
%K nonn,base
%O 1,2
%A _Paolo P. Lava_ and _Giorgio Balzarotti_, May 08 2007
|