# Trigamma function

Trigamma function $\psi_1(z)$ in the complex plane. The color of a point $z$ encodes the value of $\psi_1(z)$. Strong colors denote values close to zero and hue encodes the value's argument.

In mathematics, the trigamma function, denoted $\psi_1(z)$, is the second of the polygamma functions, and is defined by

$\psi_1(z) = \frac{d^2}{dz^2} \ln\Gamma(z)$.

It follows from this definition that

$\psi_1(z) = \frac{d}{dz} \psi(z)$

where $\psi(z)$ is the digamma function. It may also be defined as the sum of the series

$\psi_1(z) = \sum_{n = 0}^{\infty}\frac{1}{(z + n)^2},$

making it a special case of the Hurwitz zeta function

$\psi_1(z) = \zeta(2,z). \frac{}{}$

Note that the last two formulæ are valid when $1-z$ is not a natural number.

## Calculation

A double integral representation, as an alternative to the ones given above, may be derived from the series representation:

$\psi_1(z) = \int_0^1\int_0^y\frac{x^{z-1}y}{1 - x}\,dx\,dy$

using the formula for the sum of a geometric series. Integration by parts yields:

$\psi_1(z) = -\int_0^1\frac{x^{z-1}\ln{x}}{1-x}\,dx$

An asymptotic expansion as a Laurent series is

$\psi_1(z) = \frac{1}{z} + \frac{1}{2z^2} + \sum_{k=1}^{\infty}\frac{B_{2k}}{z^{2k+1}} = \sum_{k=0}^{\infty}\frac{B_k}{z^{k+1}}$

if we have chosen $B_1 = 1/2$, i.e. the Bernoulli numbers of the second kind.

### Recurrence and reflection formulae

The trigamma function satisfies the recurrence relation

$\psi_1(z + 1) = \psi_1(z) - \frac{1}{z^2}$

and the reflection formula

$\psi_1(1 - z) + \psi_1(z) = \frac{\pi^2}{\sin^2(\pi z)} \,$

which immediately gives the value for z=1/2.

### Special values

The trigamma function has the following special values:

$\psi_1\left(\frac{1}{4}\right) = \pi^2 + 8K$
$\psi_1\left(\frac{1}{2}\right) = \frac{\pi^2}{2}$
$\psi_1(1) = \frac{\pi^2}{6}$
$\psi_1\left(\frac{3}{2}\right) = \frac{\pi^2}{2} - 4$
$\psi_1(2) = \frac{\pi^2}{6} - 1$

where K represents Catalan's constant.

There are no roots on the real axis of $\psi_1$, but there exist infinitely many pairs of roots $z_n, \overline{z_n}$ for $\Re(z) < 0$. Each such pair of root approach $\Re(z_n)= -n+1/2$ quickly and their imaginary part increases slowly logarithmic with n. E.g. $z_1 = -0.4121345\ldots + i 0.5978119\ldots$ and $z_2 = -1.4455692\ldots + i 0.6992608\ldots$ are the first two roots with $\Im(z) > 0$.

## Appearance

The trigamma function appears in the next surprising sum formula:[1]

$\sum_{n=1}^\infty\frac{n^2-\frac12}{\left(n^2+\frac12\right)^2}\left[\psi_1\left(n-\frac{i}{\sqrt{2}}\right)+\psi_1\left(n+\frac{i}{\sqrt{2}}\right)\right]= -1+\frac{\sqrt{2}}{4}\pi\coth\left(\frac{\pi}{\sqrt{2}}\right)-\frac{3\pi^2}{4\sinh^2\left(\frac{\pi}{\sqrt{2}}\right)}+\frac{\pi^4}{12\sinh^4\left(\frac{\pi}{\sqrt{2}}\right)}\left(5+\cosh\left(\pi\sqrt{2}\right)\right).$