# Perron's formula

In mathematics, and more particularly in analytic number theory, Perron's formula is a formula due to Oskar Perron to calculate the sum of an arithmetical function, by means of an inverse Mellin transform.

## Statement

Let $\{a(n)\}$ be an arithmetic function, and let

$g(s)=\sum_{n=1}^{\infty} \frac{a(n)}{n^{s}}$

be the corresponding Dirichlet series. Presume the Dirichlet series to be absolutely convergent for $\Re(s)>\sigma_a$. Then Perron's formula is

$A(x) = {\sum_{n\le x}}' a(n) =\frac{1}{2\pi i}\int_{c-i\infty}^{c+i\infty} g(z)\frac{x^{z}}{z} dz.\;$

Here, the prime on the summation indicates that the last term of the sum must be multiplied by 1/2 when x is an integer. The formula requires $c>\sigma_a$ and $x>0$ real, but otherwise arbitrary.

## Proof

An easy sketch of the proof comes from taking Abel's sum formula

$g(s)=\sum_{n=1}^{\infty} \frac{a(n)}{n^{s} }=s\int_{0}^{\infty} A(x)x^{-(s+1) } dx.$

This is nothing but a Laplace transform under the variable change $x=e^t.$ Inverting it one gets Perron's formula.

## Examples

Because of its general relationship to Dirichlet series, the formula is commonly applied to many number-theoretic sums. Thus, for example, one has the famous integral representation for the Riemann zeta function:

$\zeta(s)=s\int_1^\infty \frac{\lfloor x\rfloor}{x^{s+1}}\,dx$

and a similar formula for Dirichlet L-functions:

$L(s,\chi)=s\int_1^\infty \frac{A(x)}{x^{s+1}}\,dx$

where

$A(x)=\sum_{n\le x} \chi(n)$

and $\chi(n)$ is a Dirichlet character. Other examples appear in the articles on the Mertens function and the von Mangoldt function.