I have the following sum $\sum_{j=1}^K {K \choose j} (-1)^{j+1}/j$. Now I can write this as the integral $\int_{-1}^0 \frac{(1+x)^K - 1}{x} dx$. However, I wonder whether there is a closed form expression for that integral? Thanks.
-
2$\begingroup$ Let $u=x+1$. $\int_{-1}^0 \frac{(1+x)^K-1}{x}dx = \int_0^1 \frac{u^K-1}{u-1}du = \int_0^1 (u^{K-1} + u^{K-2} + ... + u + 1) du$. The result is the $K$th harmonic number $H_K = 1/K + 1/(K-1) + ... + 1/2 + 1$. $\endgroup$– Douglas ZareCommented Jan 19, 2014 at 6:36
2 Answers
The closed form of the integral is
$$ \int_{-1}^{0}\frac{(1+x)^k - 1}{x} = \frac{s(k+1,2)}{k!} $$
where $s(k+1,2)$ denote the Stirling number of the first kind.
-
$\begingroup$ Is there a similar integral representation for $s(n,r)$ ? $\endgroup$ Commented Feb 4, 2013 at 12:32
-
1$\begingroup$ Are you sure about this? Then this would just reduce to $\sum_{j=1}^k 1/k$, right? $\endgroup$– DanneCommented Feb 4, 2013 at 14:20
-
$\begingroup$ I think one has to involve Stirling functions of the second kind, not Stirling numbers of the first kind. $\endgroup$– DanneCommented Feb 4, 2013 at 14:36
-
$\begingroup$ @Pietro Yes there is such an integral which is in fact a contour integral. $$ s(n,r) = \frac{n!}{2\pi r!}\int_{|z|=1} z^{-n-1} \log^r (z+1)dz $$ @Danne, Yes I am sure. $\endgroup$ Commented Feb 4, 2013 at 16:10
-
$\begingroup$ But when I evalute that integral and the Stirling formula you gave, I don't get the same answer. How do you find that formula? $\endgroup$– DanneCommented Feb 4, 2013 at 16:15
$\newcommand{\+}{^{\dagger}}% \newcommand{\angles}[1]{\left\langle #1 \right\rangle}% \newcommand{\braces}[1]{\left\lbrace #1 \right\rbrace}% \newcommand{\bracks}[1]{\left\lbrack #1 \right\rbrack}% \newcommand{\ceil}[1]{\,\left\lceil #1 \right\rceil\,}% \newcommand{\dd}{{\rm d}}% \newcommand{\down}{\downarrow}% \newcommand{\ds}[1]{\displaystyle{#1}}% \newcommand{\equalby}[1]{{#1 \atop {= \atop \vphantom{\huge A}}}}% \newcommand{\expo}[1]{\,{\rm e}^{#1}\,}% \newcommand{\fermi}{\,{\rm f}}% \newcommand{\floor}[1]{\,\left\lfloor #1 \right\rfloor\,}% \newcommand{\half}{{1 \over 2}}% \newcommand{\ic}{{\rm i}}% \newcommand{\iff}{\Longleftrightarrow} \newcommand{\imp}{\Longrightarrow}% \newcommand{\isdiv}{\,\left.\right\vert\,}% \newcommand{\ket}[1]{\left\vert #1\right\rangle}% \newcommand{\ol}[1]{\overline{#1}}% \newcommand{\pars}[1]{\left( #1 \right)}% \newcommand{\partiald}[3][]{\frac{\partial^{#1} #2}{\partial #3^{#1}}} \newcommand{\pp}{{\cal P}}% \newcommand{\root}[2][]{\,\sqrt[#1]{\,#2\,}\,}% \newcommand{\sech}{\,{\rm sech}}% \newcommand{\sgn}{\,{\rm sgn}}% \newcommand{\totald}[3][]{\frac{{\rm d}^{#1} #2}{{\rm d} #3^{#1}}} \newcommand{\ul}[1]{\underline{#1}}% \newcommand{\verts}[1]{\left\vert\, #1 \,\right\vert}$ \begin{align} &\color{#0000ff}{\large\int_{-1}^{0}{\pars{1 + x}^{K} - 1 \over x}\,\dd x} =\int_{0}^{1}{1 - x^{K} \over 1 - x}\,\dd x =-\int_{x = 0}^{x = 1}\pars{1 - x^{K}}\,\dd\ln\pars{1 - x} \\[3mm]&=\int_{0}^{1}\ln\pars{1 - x}\pars{-Kx^{K - 1}}\,\dd x =-K\lim_{\mu \to 0}\partiald{}{\mu}\int_{0}^{1}\pars{1 - x}^{\mu}x^{K - 1}\,\dd x \\[3mm]&= -K\lim_{\mu \to 0}\partiald{{\rm B}\pars{1 + \mu,K}}{\mu} = -K\lim_{\mu \to 0}\partiald{}{\mu} \bracks{\Gamma\pars{1 + \mu}\Gamma\pars{K} \over \Gamma\pars{1 + \mu + K}} \\[3mm]&=-K\,\Gamma\pars{K}\lim_{\mu \to 0}\bracks{% {\Gamma\pars{1 + \mu}\Psi\pars{1 + \mu} \over \Gamma\pars{1 + \mu + K}} - {\Gamma\pars{1 + \mu}\Psi\pars{1 + \mu + K} \over \Gamma\pars{1 + \mu + K}}} \\[3mm]&= -\Gamma\pars{1 + K}\bracks{% {-\gamma \over \Gamma\pars{1 + K}} - {\Psi\pars{1 + K} \over \Gamma\pars{1 + K}}} = \color{#0000ff}{\large\gamma + \Psi\pars{1 + K}} \end{align}
$$ \begin{array}{rcl} {\rm B}\pars{\alpha,\beta}=\int_{0}^{1}t^{\alpha - 1}\pars{1 - t}^{\beta - 1}\,\dd t: && Beta\ \mbox{function} \\[2mm] \Gamma\pars{z}:&& Gamma\ \mbox{function} \\[2mm] \Psi\pars{z} \equiv \totald{\ln\pars{\Gamma\pars{z}}}{z}:&& Digamma\ \mbox{function} \\[2mm]\gamma \approx 0.577216:&& Euler-Mascheroni\ constant \end{array} $$