# K-function

In mathematics, the K-function, typically denoted K(z), is a generalization of the hyperfactorial to complex numbers, similar to the generalization of the factorial to the gamma function.

Formally, the K-function is defined as

${\displaystyle K(z)=(2\pi )^{(-z+1)/2}\exp \left[{\begin{pmatrix}z\\2\end{pmatrix}}+\int _{0}^{z-1}\ln(\Gamma (t+1))\,dt\right].}$

It can also be given in closed form as

${\displaystyle K(z)=\exp \left[\zeta ^{\prime }(-1,z)-\zeta ^{\prime }(-1)\right]}$

where ζ'(z) denotes the derivative of the Riemann zeta function, ζ(a,z) denotes the Hurwitz zeta function and

${\displaystyle \zeta ^{\prime }(a,z)\ {\stackrel {\mathrm {def} }{=}}\ \left[{\frac {\partial \zeta (s,z)}{\partial s}}\right]_{s=a}.}$

Another expression using polygamma function is[1]

${\displaystyle K(z)=\exp \left(\psi ^{(-2)}(z)+{\frac {z^{2}-z}{2}}-{\frac {z}{2}}\ln(2\pi )\right)}$
${\displaystyle K(z)=Ae^{\psi (-2,z)+{\frac {z^{2}-z}{2}}}}$
where A is Glaisher constant.

It can also be shown that for ${\displaystyle \alpha >0}$:

${\displaystyle \int _{\alpha }^{\alpha +1}\ln(K(x))dx-\int _{0}^{1}\ln(K(x))dx={\frac {1}{2}}\alpha ^{2}\left(\ln(\alpha )-{\frac {1}{2}}\right)}$

This can be shown by defining the function ${\displaystyle f}$ such that:

${\displaystyle f(\alpha )=\int _{\alpha }^{\alpha +1}\ln(K(x))dx}$

Deriving this identity now with respect to ${\displaystyle \alpha }$ yields:

${\displaystyle f'(\alpha )=\ln(K(\alpha +1))-\ln(K(\alpha ))}$

Applying the logarithm rule we get

${\displaystyle f'(\alpha )=\ln \left({\frac {K(\alpha +1)}{K(\alpha )}}\right)}$

By the definition of the K-Function we write

${\displaystyle f'(\alpha )=\alpha \ln(\alpha )}$

And so

${\displaystyle f(\alpha )={\frac {1}{2}}\alpha ^{2}\left(\ln(\alpha )-{\frac {1}{2}}\right)+C}$

Setting ${\displaystyle \alpha =0}$ we have

${\displaystyle \int _{0}^{1}\ln(K(x))dx=\lim _{n\rightarrow 0}\left({\frac {1}{2}}n^{2}\left(\ln(n)-{\frac {1}{2}}\right)\right)+C}$

${\displaystyle \int _{0}^{1}\ln(K(x))dx=C}$

Now one can deduce the identity above.

The K-function is closely related to the gamma function and the Barnes G-function; for natural numbers n, we have

${\displaystyle K(n)={\frac {(\Gamma (n))^{n-1}}{G(n)}}.}$

More prosaically, one may write

${\displaystyle K(n+1)=1^{1}\,2^{2}\,3^{3}\cdots n^{n}.}$

The first values are

1, 4, 108, 27648, 86400000, 4031078400000, 3319766398771200000, ... ((sequence A002109 in the OEIS)).