### Motivation

In the analogy between prime numbers and knots, the prime number is thought sometimes as the circle of length $l([p]) = \text{log}\,p$. This is so you can express the zeta function as $$ \zeta(s) = \sum_{D\ge0} e^{-l(D)s}$$

where the sum goes over effective divisors on $\text{Spec}\,\mathbb Z$ and length is extended there by additivity. Similarly, you can do it to rewrite Dedekind zeta function for other number fields.

### Question

I wonder, **what is the right analogue of above formula** for a manifold with metric? Perhaps:

- integration over all closed curves of the expression $e^{-l(D)s}$
- summation over positive sums of classes of closed geodesics.

I think I've heard something about definition 2, but I suspect if the two above are defined correctly they will be the same. Is it possible to formalize this definition? Do different formalizations lead to the same zeta-function?

### Updates

Yes, I think this should be related to Laplacians, Selberg trace formula and dynamical system zetas. What I said I've heard about definition 2 was probably the Selberg zeta, but I can't say it clearly, hence questions.