login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

a(n) is the greatest product of the digits of n in any base b in the range 2..n.
2

%I #12 Aug 26 2019 18:45:44

%S 0,1,1,2,2,3,4,4,4,6,5,6,8,9,8,10,9,12,12,10,12,15,16,14,16,18,16,20,

%T 18,21,20,20,24,25,20,22,24,28,25,30,27,30,32,27,30,35,36,36,33,36,35,

%U 40,40,42,36,36,40,45,36,42,48,49,48,50,45,48,48,54,50

%N a(n) is the greatest product of the digits of n in any base b in the range 2..n.

%H Rémy Sigrist, <a href="/A309965/b309965.txt">Table of n, a(n) for n = 2..10000</a>

%H Rémy Sigrist, <a href="/A309965/a309965.png">Scatterplot of (n, n-a(n)) for n = 2..50000</a>

%F a(n) < n.

%e For n = 8:

%e - the digits of 8 in bases b = 2..8 and the corresponding products are:

%e b digits product

%e - ------ -------

%e 2 "1000" 0

%e 3 "22" 4

%e 4 "20" 0

%e 5 "13" 3

%e 6 "12" 2

%e 7 "11" 1

%e 8 "10" 0

%e - hence a(8) = 4.

%o (PARI) a(n) = vecmax(vector(n-1, b, vecprod(digits(n,b+1))))

%Y See A309969 for the corresponding base b.

%Y Cf. A007954.

%K nonn,base

%O 2,4

%A _Rémy Sigrist_, Aug 25 2019