# Formula for Sum of Logarithms $\ln(n)^m$

As you know $\sum_{n=1}^k \ln(n) =\ln(k!)$ is there a formula for $\sum_{n=1}^k \ln(n)^m$?

• Perhaps an idea - not sure if it will help. $$\sum \ln^2 n = \sum \ln n^{\ln n} = \ln \left( \prod n^{\ln n} \right).$$ – gt6989b May 17 '13 at 14:27
• If m is constant, then $\sum_{n=1}^{k}ln(n)^m=\sum_{n=1}^{k}mln(n)=mln(k!)$ – Noy Soffer May 17 '13 at 14:30
• look for (ln(n))^m – Kevin 67 May 17 '13 at 14:39
• it ln(n)^m not ln(n^m) – Kevin 67 May 17 '13 at 14:47
• m is a natural number – Kevin 67 May 17 '13 at 14:51

The Euler-Maclaurin Sum Formula gives the asymptotic approximation:

\begin{align} \sum_{n=1}^k\log(n)^m &\sim k\left(\log(k)^m-m\log(k)^{m-1}+m(m-1)\log(k)^{m-2}-\dots+(-1)^mm!\right)\\ &+\frac12\log(k)^m+C+\frac{m}{12k}\log(k)^{m-1}+O\left(\frac{\log(k)^{m-1}}{k^3}\right) \end{align} The constant $C$ depends on $m$ and needs to be determined separately. For $m=1$, Stirling's approsimation says that $C=\frac12\log(2\pi)$.

• I would doubt there is an exact formula for $m\gt1$, but that is not to say there might not be one. – robjohn May 23 '13 at 1:53
• This seems to be an approximation and was not meant. – Kevin 67 May 23 '13 at 9:20
• @KeyvanGhaffari: Yes. For $m=1$, this is Stirling's approximation. The error term, $O\left(\dfrac{\log(k)^{m-1}}{k^3}\right)$, gets smaller as $k$ gets bigger. As I said, I doubt there is an exact formula for $m\gt1$. The exact formula for $m=1$ exists only because we've defined $n!=n(n-1)(n-2)\dots1$ – robjohn May 23 '13 at 12:17
• @robjohn: Just a "ping" : the question sleeps since when you wrote your answer which was regarded as not helpful by the OP. Because you're much more expert than me (amateur): would you mind to look at my proposal in my new answer in which I tried to apply an Bernoulli-/Faulhaber-analogy to the question of sums of like powers of logarithms ? – Gottfried Helms Jul 11 '14 at 8:54

In 2010 I'd worked out a recipe how to sum equal-powers-of-consecutive-logarithms with the same basic idea as in the Bernoulli/Faulhaber-ansatz for equal-powers-of-consecutive-integers.

It employs the use of Carleman- and Neumann-matrices and an idea which I've found printed in an article by P Walker[91](ref. see end of article) but was rediscovered in the discussion of tetration for the Pseudo-inversion of a noninvertible infinite matrix.

While this is all just experimental and approximated by $32x32$ resp $64x64$-matrices (instead of infinite size) it gives finally the leading coefficients of power series for the expressions $$s_c(\log(a),\log(b)) = \sum_{k=a}^{b} \log(k)^c =\log(a)^c+\log(a+1)^c+...+ \log(b)^c$$ by a helper function with coefficients $h_{r,c}$ $$h_c(x) = \sum_{r=0}^\infty x^r \cdot h_{r,c}$$ and $$s_c(\log(a),\log(b)) = h_c(\log(a))-h_c(\log(b+1))$$ and is explicitely with $x=\log(a)$ and $y=\log(b+1)$ $$s_c(x,y) = \sum_{k=1}^\infty (x^k-y^k) \cdot h_{r,c}$$ (Note 1: because the constant at $k=0$ for $h(x)$ cancels, we need only begin at index k=1)
(Note 2: $h_c(0)$ which is equal to $h_c(log(1))$ alone give the (regularized) infinite sum of $\log(1)^c+\log(2)^c+\log(3)^c+\ldots$ by the $c$'th derivative of zeta at zero: $\zeta^{(c)}(0)$)

The matrix $H$ (where $r$ and $c$ denote row and column, beginning at zero) read along its columns gives that coefficients $h_{r,c}$ for the power series $h_c()$ $$\small \begin{array} {rrrrr} h_0() & h_1() & h_2()&h_3()&h_4() \\ \hline -1/2, & -0.91893853& -2.0063565& -6.0047112& -23.997103 \\ -1.0000000 & 0.57721566 & -0.14563169 & -0.029071090 & 0.0082153377 \\ -0.50000000 & -0.53385920 & 0.63456997 & -0.18581113 & -0.060502531 \\ -0.16666667 & -0.32557879 & -0.38685888 & 0.67130432 & -0.21049260 \\ -0.041666667 & -0.12527414 & -0.24071138 & -0.31275691 & 0.69581026 \\ -0.0083333333 & -0.033725651 & -0.099162025 & -0.19189685 & -0.26703502 \\ -0.0013888889 & -0.0068593536 & -0.028473038 & -0.081466529 & -0.16031194 \\ -0.00019841270 & -0.0011726081 & -0.0059237927 & -0.024525073 & -0.068911838 \\ -0.000024801587 & -0.00018318327 & -0.00098840226 & -0.0052803372 & -0.021431797 \\ -0.0000027557319 & -0.000022576504 & -0.00016200352 & -0.00086132363 & -0.0047789811 \\ -0.00000027557319 & -0.0000015258454 & -0.000024146726 & -0.00013673423 & -0.00077672072 \\ -0.000000025052108 & -0.00000027560637 & -0.0000012164517 & -0.000024208043 & -0.00011516519 \end{array}$$ and some small experiments with the evaluations of $s_0(x,y),s_1(x,y),s_2(x,y),...$ where $x=\log(2)$ and $y=\log(4)$ such that we have $$\begin{eqnarray} s_0(x,y) &=& \log(2)^0 +\log(3)^0 +\log(4)^0 & =3\\ s_1(x,y) &=& \log(2) +\log(3) +\log(4) & \\ s_2(x,y) &=& \log(2)^2 +\log(3)^2 +\log(4)^2 & \\ ... &=& ...\\ s_{20}(x,y) &=& \log(2)^{20}+log(3)^{20}+\log(4)^{20} & \\ \end{eqnarray}$$ gives remarkable good approximations when the matrix/series-calculation are based on the truncation size of $64x64$ (even $32x32$ seems to suffice for the displayed precision): $$\small \begin{array} {r|llr} c & \text{by series} & \text{by finite sum} &\text{error}\\ \hline 0 & 3.00000000000 & 3 & -1.43995490313E-80 \\ 1 & 3.17805383035 & 3.17805383035 & -3.53953620855E-25 \\ 2 & 3.60921403040 & 3.60921403040 & 7.36584905152E-25 \\ 3 & 4.32319082804 & 4.32319082804 & 9.69440142925E-24 \\ 4 & 5.38092246992 & 5.38092246992 & -9.80800381594E-23 \\ 5 & 6.88046588450 & 6.88046588450 & 4.67474407314E-22 \\ 6 & 8.96704590737 & 8.96704590737 & -1.14897898370E-21 \\ 7 & 11.8482905963 & 11.8482905963 & -5.40205206727E-22 \\ 8 & 15.8162546226 & 15.8162546226 & 1.68862757825E-20 \\ 9 & 21.2785746057 & 21.2785746057 & -6.66022792495E-20 \\ 10 & 28.8020909611 & 28.8020909611 & 8.57381760430E-20 \\ 11 & 39.1736180459 & 39.1736180459 & 3.42695111767E-19 \\ 12 & 53.4843938902 & 53.4843938902 & -1.93910736674E-18 \\ 13 & 73.2472921633 & 73.2472921633 & 2.90694223029E-18 \\ 14 & 100.559407248 & 100.559407248 & 8.45942723476E-18 \\ 15 & 138.327508405 & 138.327508405 & -4.65886293588E-17 \\ 16 & 190.580627020 & 190.580627020 & 4.31226340552E-17 \\ 17 & 262.903420445 & 262.903420445 & 2.80945299213E-16 \\ 18 & 363.036956764 & 363.036956764 & -9.15786903334E-16 \\ 19 & 501.711586276 & 501.711586276 & -5.29715318822E-16 \\ 20 & 693.801547683 & 693.801547683 & 8.08552472457E-15 \\ 21 & 959.925588861 & 959.925588861 & -7.94115573619E-15 \\ 22 & 1328.66589168 & 1328.66589168 & -5.25630313408E-14 \\ 23 & 1839.64414543 & 1839.64414543 & 1.22429416432E-13 \end{array}$$

[update]: Two examples why this is (while still hypothetically) an "exact" solution.

0) First look at the column $c=0$ which should provide the solution for $$\begin{array}{rll} s_0(\log(a),\log(b)) &= h_0(\log(a))-h_0(\log(b+1)) \\ &=\sum_{k=a}^{b} \log(a)^0 + \log(a+1)^0 + ... + \log(b)^0 \\ & = 1+1+...+1 \\ &= b+1-a \end{array}$$ Looking at the (empirically found) coefficients of the first column in $H$ we see, that they appear to form the exponential-series defining $$h_0(x) = C - (\exp(x)-1) \qquad \qquad \text{ where } C=-1/2=\zeta(0)$$ and thus $$h_0(\log(a))-h_0(\log(b+1)) = (C - (a-1)) - (C - ((b+1)-1)) = b+1 -a$$ which is the expected value.

1) Looking at the (empirically found) coefficients of the second column in $H$ we see, that they appear to form the power-series defining $$h_1(x) = C - (\log(\Gamma(\exp(x))) \qquad \qquad \text{where} C= \zeta'(0)$$ and thus $$h_1(\log(a))-h_1(\log(b+1)) = (C - \log(\Gamma(a))) - (C - \log(\Gamma(b+1))) \\ = -\log( 1\cdot 2 \cdot 3 \cdot \ldots \cdot a-1) +\log( 1\cdot 2 \cdot 3 \cdot \ldots \cdot b) \\ = \log(a) + \log(a+1) + ... + \log(b)$$ which is again the expected value.

The entries in the following columns allow the same scheme (with $C$ the higher derivatives of the $\zeta$ at zero) but are not yet known in power series expressions of documented common functions, and because they are "new" I've no further example in this style of argumentation for the other columns.

The remaining problem with this (concerning the exactness of the results) is that the hypothese, that the involved Walker's "Pseudo"-matrix-inversion returns the correct result when the matrix size goes to infinity, has not yet been proven.

[Walker91] Walker, P. L. (1991). On the solutions of an {A}belian functional equation. J. Math. Anal. Appl., 155(1), 93–110, see page 108-109

• The main complaint about my answer was that the OP wanted an exact formula, like we have for $m=1$ and $\log(k!)$. I haven't had a chance to look very closely at your answer yet. Does it provide an exact answer, or a series (infinite sum) approximation? – robjohn Jul 11 '14 at 9:14
• @Robjohn: I think I should regard it as an "exact" answer; it provides a power series for which I have the hypothese, that it is an exact representation for the problem, like the mercator-series is assumed as an exact solution for the problem of the logarithm. Only the matrix-inversion of the infinite matrix is not yet analytically justified; Peter Walker in his article remarks the lack of such rigorous justification but mentions the apparent convergence to the coefficients of the required series. I think it would be good to do analytical research for this detailproblem - to nail it once down. – Gottfried Helms Jul 11 '14 at 9:20
• @RobJohn: (continued) A simple argument for "exactness" . The coefficients in column $0$ should provide the power series for the evaluation $\sum_{k=a}^{b-1} \log(k)^0 = \log(a)^0+\log(a+1)^0+... + \log(b-1)^0 = 1+1+1+...+1 = b-a$ which is the number of terms and obviously the expected answer. The column provides an "exact" solution because it is simply the exponential-series (with a modification of the constant term) and the arguments $\log(a)$ and $\log(b-1)$ can be evaluated "exactly" to the expected integer values. – Gottfried Helms Jul 11 '14 at 9:31