OFFSET
1,1
COMMENTS
The product of digits must be divisible by 9, but is not 0. - Robert Israel, Aug 24 2014
LINKS
Jens Kruse Andersen, Table of n, a(n) for n = 1..10000
EXAMPLE
239 + 2*3*9 = 293 is a permutation of the digits of 239. Thus 239 is a member of this sequence.
MAPLE
filter:= proc(n)
local L, m;
L:= convert(n, base, 10);
m:= convert(L, `*`);
if m=0 then return false fi;
sort(L) = sort(convert(n+m, base, 10));
end proc:
select(filter, [$1..1000]); # Robert Israel, Aug 24 2014
MATHEMATICA
Cases[{#, DigitCount@#} & /@ (If[(prod = Times @@ IntegerDigits@#) == 0 || Mod[prod, 9] != 0, Nothing, # + {0, prod}] & /@ Range@7500), {{x_, _}, {y_, y_}} :> x] (* Hans Rudolf Widmer, Aug 24 2024 *)
PROG
(PARI) for(n=1, 10^5, d=digits(n); p=prod(i=1, #d, d[i]); v=digits(n+p); if(v!=d, v=vecsort(v); d=vecsort(d); if(v==d, print1(n, ", "))))
(Python)
from operator import mul
from functools import reduce
A243102 = [int(n) for n in (str(x) for x in range(1, 10**5)) if not n.count('0') and sorted(str(int(n)+reduce(mul, (int(d) for d in n)))) == sorted(n)]
# Chai Wah Wu, Aug 26 2014
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Derek Orr, Aug 19 2014
EXTENSIONS
Definition edited by Robert Israel, Aug 24 2014
STATUS
approved