Definition 3.2.1. Period of a state of a Markov chain
Let $\left(X_n\right)_{n \geq 0}$ be a Markov chain with the state space $S$ and the transition matrix $P$.
For any state $i \in S$, the period $d_i$ of state $i$ is given by
$
d_i=\operatorname{gcd}\left\{n \in \mathbb{N}: P_{i i}^n>0\right\}
$
where gcd denotes the greatest common divisor.
If $d_i>1$ then the state is called periodic with period $d_i$.
If $d_i=1$ then the state is called aperiodic.
If $P_{i i}^n=0$ for all $n \in \mathbb{N}$ then the period of the state $i$ is not defined.