# Ergodic sequence

In mathematics, an ergodic sequence is a certain type of integer sequence, having certain equidistribution properties.

## Definition

Let $A = \{a_j\}$ be an infinite, strictly increasing sequence of positive integers. Then, given an integer q, this sequence is said to be ergodic mod q if, for all integers $1\leq k \leq q$, one has

$\lim_{t\to\infty} \frac{N(A,t,k,q)}{N(A,t)} = \frac {1}{q}$

where

$N(A,t) = \mbox{card} \{a_j \in A : a_j \leq t \}$

and card is the count (the number of elements) of a set, so that $N(A,t)$ is the number of elements in the sequence A that are less than or equal to t, and

$N(A,t,k,q) = \mbox{card} \{a_j \in A : a_j\leq t,\, a_j \mod q = k \}$

so $N(A,t,k,q)$ is the number of elements in the sequence A, less than t, that are equivalent to k modulo q. That is, a sequence is an ergodic sequence if it becomes uniformly distributed mod q as the sequence is taken to infinity.

An equivalent definition is that the sum

$\lim_{t\to\infty} \frac{1}{N(A,t)} \sum_{j; a_j\leq t} \exp \frac{2\pi ika_j}{q} = 0$

vanish for every integer k with $k \mod q \ne 0$.

If a sequence is ergodic for all q, then it is sometimes said to be ergodic for periodic systems.

## Examples

The sequence of positive integers is ergodic for all q.

Almost all Bernoulli sequences, that is, sequences associated with a Bernoulli process, are ergodic for all q. That is, let $(\Omega,Pr)$ be a probability space of random variables over two letters $\{0,1\}$. Then, given $\omega \in \Omega$, the random variable $X_j(\omega)$ is 1 with some probability p and is zero with some probability 1-p; this is the definition of a Bernoulli process. Associated with each $\omega$ is the sequence of integers

$\mathbb{Z}^\omega = \{n\in \mathbb{Z} : X_n(\omega) = 1 \}$

Then almost every sequence $\mathbb{Z}^\omega$ is ergodic.