Definition
Let \(a, b \in \mathbb{Z}\). \(a\) divides \(b\) or \(a \ | \ b\) if there exists an \(m \in \mathbb{Z}\) such that \(am = b\).
Note: \(a \ | \ b\) doesn’t mean that \(\frac{b}{a}\) is defined. Also note that \(a \ | \ 0\) is only true if \(a = 0\).
Example
Suppose \(n = 7\) and \(a = 3\), then
$$
\begin{align*}
3^1 &= 3 \equiv 3 \mod n \\
3^2 &= 6 \equiv 6 \mod n \\
3^3 &= 9 \equiv 2 \mod n \\
3^4 &= 81 \equiv 4 \mod n \\
3^5 &= 243 \equiv 5 \mod n \\
3^6 &= 729 \equiv 1 \mod n \\
\end{align*}
$$
So the multiplicative order of 3 modulo 7 is 6. Similarly for a = 4 and n = 7
$$
\begin{align*}
4^1 &= 4 \equiv 4 \mod n \\
4^2 &= 16 \equiv 2 \mod n \\
4^3 &= 64 \equiv 1 \mod n \\
\end{align*}
$$
So the multiplicative order of 4 modulo 7 is 3.