|
|
A364136
|
|
a(n) is the number of distinct products of nonempty submultisets of the digits of n.
|
|
1
|
|
|
1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 2, 2, 3, 2, 3, 3, 3, 3, 3, 3, 2, 2, 3, 3, 2, 3, 3, 3, 3, 3, 2, 2, 3, 3, 3, 2, 3, 3, 3, 3, 2, 2, 3, 3, 3, 3, 2, 3, 3, 3, 2, 2, 3, 3, 3, 3, 3, 2, 3, 3, 2, 2, 3, 3, 3, 3, 3, 3, 2, 3, 2
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
0,11
|
|
COMMENTS
|
|
|
LINKS
|
|
|
EXAMPLE
|
n = 10: products of digits are {0, 1, 0*1}, distinct products of digits are {0, 1}, thus a(10) = 2.
n = 11: products of digits are {1, 1*1}, distinct product of digits is {1}, thus a(11) = 1.
n = 23: products of digits are {2, 3, 2*3}, distinct products of digits are {2, 3, 6}, thus a(23) = 3.
|
|
PROG
|
(PARI) a(n) = {if(n==0, return(1));
my(d = vecsort(digits(n)), l = List());
for(i = 1, #d,
forvec(x = vector(i, j, [1, #d]),
c = vecprod(vector(i, j, d[x[j]]));
listput(l, c)
,
2
)
);
#Set(l)
|
|
CROSSREFS
|
|
|
KEYWORD
|
base,nonn
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|