OFFSET
1,1
EXAMPLE
MATHEMATICA
digsum[n_] := Total@IntegerDigits[n]; smithQ[n_] := CompositeQ[n] && Plus @@ (Last[#]*digsum[First@#] & /@ FactorInteger[n]) == digsum[n]; d[0] = d[1] = 0; d[n_] := n*Plus @@ ((Last[#]/First[#]) & /@ FactorInteger[n]); Select[Range[10^4], smithQ[#] && smithQ[d[#]] &] (* Amiram Eldar, Oct 21 2022 *)
PROG
(Magma) sm:=func<n| not IsPrime(n) and (&+Intseq(n) eq &+[ Factorisation(n)[i][2]* &+Intseq(Factorisation(n)[i][1]) : i in [1..#PrimeDivisors(n)]])>; f:=func<h |h le 1 select 0 else h*(&+[Factorisation(h)[i][2] / Factorisation(h)[i][1]: i in [1..#Factorisation(h)]])>; [n:n in [2..10700]|sm(n) and sm(Floor(f(n)))];
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Marius A. Burtea, Oct 20 2022
STATUS
approved