Zn is a ring

Dependencies:

  1. Ring
  2. Modular Equivalence
  3. Modular addition
  4. Modular multiplication
  5. Integer Division Theorem

$\mathbb{Z}_n = \{0, 1, \ldots, n-1\}$. Let $a, b \in \mathbb{Z}_n$. The sum of $a$ and $b$ is defined as $\operatorname{add}(a, b) = (a+b)\%n$. The product of $a$ and $b$ is defined as $\operatorname{mult}(a, b) = (ab)\%n$.

Under these operations, $\mathbb{Z}_n$ forms a commutative ring with unity.

Lemmas

\begin{align} & a \equiv b \pmod{n} \\ &\iff n \mid (a - b) \\ &\iff n \mid (a\%n + n\left\lfloor\frac{a}{n}\right\rfloor - b\%n - n\left\lfloor\frac{b}{n}\right\rfloor) \\ &\iff n \mid (a\%n - b\%n) \\ &\iff a\%n - b\%n = 0 \\ &\iff a\%n = b\%n \end{align}

This is because $a\%n - b\%n \in \{-(n-1), -(n-2), \ldots, n-2, n-1\}$ and the only divisor of $n$ in this set is 0.

\[ n \mid (a - a\%n) \iff a \equiv a\%n \pmod{n} \]

Proof that $\mathbb{Z}_n$ is a ring

Therefore, $\mathbb{Z}_n$ is an abelian group under addition.

Therefore, $\mathbb{Z}_n$ is a commutative ring with unity.

Dependency for:

  1. Zp is an integral domain
  2. Zp is a field

Info:

Transitive dependencies:

  1. Group
  2. Ring
  3. Modular Equivalence
  4. Modular multiplication
  5. Modular addition
  6. Integer Division Theorem