5: Modular Arithmetic and Primes
- Page ID
- 60320
\( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)
\( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)
\( \newcommand{\dsum}{\displaystyle\sum\limits} \)
\( \newcommand{\dint}{\displaystyle\int\limits} \)
\( \newcommand{\dlim}{\displaystyle\lim\limits} \)
\( \newcommand{\id}{\mathrm{id}}\) \( \newcommand{\Span}{\mathrm{span}}\)
( \newcommand{\kernel}{\mathrm{null}\,}\) \( \newcommand{\range}{\mathrm{range}\,}\)
\( \newcommand{\RealPart}{\mathrm{Re}}\) \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\)
\( \newcommand{\Argument}{\mathrm{Arg}}\) \( \newcommand{\norm}[1]{\| #1 \|}\)
\( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\)
\( \newcommand{\Span}{\mathrm{span}}\)
\( \newcommand{\id}{\mathrm{id}}\)
\( \newcommand{\Span}{\mathrm{span}}\)
\( \newcommand{\kernel}{\mathrm{null}\,}\)
\( \newcommand{\range}{\mathrm{range}\,}\)
\( \newcommand{\RealPart}{\mathrm{Re}}\)
\( \newcommand{\ImaginaryPart}{\mathrm{Im}}\)
\( \newcommand{\Argument}{\mathrm{Arg}}\)
\( \newcommand{\norm}[1]{\| #1 \|}\)
\( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\)
\( \newcommand{\Span}{\mathrm{span}}\) \( \newcommand{\AA}{\unicode[.8,0]{x212B}}\)
\( \newcommand{\vectorA}[1]{\vec{#1}} % arrow\)
\( \newcommand{\vectorAt}[1]{\vec{\text{#1}}} % arrow\)
\( \newcommand{\vectorB}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)
\( \newcommand{\vectorC}[1]{\textbf{#1}} \)
\( \newcommand{\vectorD}[1]{\overrightarrow{#1}} \)
\( \newcommand{\vectorDt}[1]{\overrightarrow{\text{#1}}} \)
\( \newcommand{\vectE}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash{\mathbf {#1}}}} \)
\( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)
\(\newcommand{\longvect}{\overrightarrow}\)
\( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)
\(\newcommand{\ket}[1]{\left| #1 \right>}\)
\(\newcommand{\bra}[1]{\left< #1 \right|}\)
\(\newcommand{\braket}[2]{\left< #1 \vphantom{#2} \right| \left. #2 \vphantom{#1} \right>}\)
\(\newcommand{\braopket}[3]{\left< #1 \vphantom{#2}\vphantom{#3} \right| #2 \vphantom{#1}\vphantom{#3} \left| #3 \vphantom{#1}\vphantom{#2} \right>}\)
\(\newcommand{\qmvec}[1]{\mathbf{\vec{#1}}}\)
\(\newcommand{\op}[1]{\hat{\mathbf{#1}}}\)
\(\newcommand{\expect}[1]{\langle #1 \rangle}\)
\(\newcommand{\dfn}[1]{\emph{\textbf{#1}}}\)
- 5.1: Modular Arithmetic
- This page of the textbook covers modular arithmetic within equivalence classes in \(\mathbb{Z}_{b}\), detailing addition and multiplication operations. It introduces group theory concepts, particularly the order of an element in a group as the smallest integer \(k\) yielding the identity through repeated operation.
- 5.2: Euler's Method
- This page covers complete and reduced sets of residues modulo \(b\), focusing on their properties linked to the gcd of integers. It includes Lemma 5.3, which demonstrates that multiplying these sets by coprime integers yields new sets. Euler's theorem (Theorem 5.4) is presented, stating that if \(a\) and \(b\) are coprime, then \(a^{\varphi(b)} \equiv 1 \mod b\).
- 5.3: Fermat’s Little Theorem and Primality Testing
- This page covers Euler's theorem and its implications, including Fermat's little theorem, which applies to prime numbers and their properties in modular arithmetic. It highlights the importance of primes in theory and cryptography, presents methods for primality testing like Eratosthenes' sieve and the Fermat test, and discusses pseudoprimes and Carmichael numbers.
- 5.4: Fermet and Mersenne Primes
- This page explores the historical and mathematical significance of perfect numbers, Mersenne primes, and Fermat primes. It explains that Mersenne primes are of the form \(2^k - 1\) and depend on \(k\) being prime, while Fermat primes, structured as \(2^{2^k} - 1\), are known only up to \(k=4\).
- 5.5: Division in \(\mathbb{Z}_{b}\)
- This page explores unique inverses in reduced sets of residues modulo \(b\), clarifying that division is well-defined when \(b\) is prime. It differentiates between rings and fields, presenting theorems like Wilson's theorem that link factorials to primality. The text emphasizes that \(\mathbb{Z}_{p}\) is a field for prime \(p\), contrasting it with composite numbers, and discusses the relationships between addition and multiplication in \(\mathbb{Z}_{b}\).
- 5.6: Exercises
- This page focuses on exercises in modular arithmetic and equivalence relations, covering key concepts like equivalence classes, divisibility, and properties of operations within modular systems. It includes topics on encryption methods, addressing multiplicative and affine ciphers, along with the Binomial Theorem and Fermat’s Little Theorem in relation to prime numbers.


