A255165 a(n) = Sum_{k=2..n} floor(log(n)/log(k)), n >= 1.
0, 1, 2, 4, 5, 6, 7, 9, 11, 12, 13, 14, 15, 16, 17, 20, 21, 22, 23, 24, 25, 26, 27, 28, 30, 31, 33, 34, 35, 36, 37, 39, 40, 41, 42, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72
Offset: 1
Examples
The first jump is at n = 4 where, in the summation, log(4)/log(2), as it reaches a new floor. Note: Possible complications exist calculating the floor function on ratios of logs that produce exact integers (e.g., in Mathematica). Adding an infinitesimal amount to n solves it.
Links
- Vaclav Kotesovec, Table of n, a(n) for n = 1..10000
- Jan Mycielski, Sur les représentations des nombres naturels par des puissances à base et exposant naturels, Colloquium Mathematicum 2 (1951), 254-260. See T(n) pp. 258-259.
Programs
-
Magma
[0] cat [&+[Floor(Log(n)/Log(k)):k in [2..n]]:n in [2..70]]; // Marius A. Burtea, Nov 13 2019
-
Mathematica
Table[Sum[Floor[Log[n]/Log[k]], {k, 2, n}], {n, 1, 100}]
-
PARI
a(n)=sum(k=2,n,log(n)\log(k)) \\ Anders Hellström, Dec 06 2015
Formula
a(n) = Sum_{k=2..n} floor(log(n)/log(k)), n >= 1.
It appears that a(n) = A089361(n) + n - 1. - Michel Marcus, Feb 17 2015
From Ridouane Oudra, Nov 13 2019: (Start)
a(n) = Sum_{i=2..n} floor(n^(1/i)).
a(n) = Sum_{i=1..floor(log_2(n))} floor(n^(1/i) - 1).
a(n) = A043000(n) - n + 1. (End)
a(n) ~ n. - Vaclav Kotesovec, Apr 06 2021
Comments