Training Discrete Mathematics & Number Theory Modular Arithmetic and Graphs
4 / 5

Modular Arithmetic and Graphs

23 min Discrete Mathematics & Number Theory

Modular Arithmetic and Graphs

Modular arithmetic studies remainders. Graph theory studies networks of vertices and edges.

Congruence Modulo $n$

We write $$a \equiv b \pmod{n}$$ if $a$ and $b$ have the same remainder when divided by $n$.

Example 1

Compute $17 \bmod 5$.

The remainder is $2$.

Example 2

Is $23 \equiv 5 \pmod 9$?

Yes, both leave remainder $5$.

Graph Vocabulary

A graph has vertices (points) and edges (connections). The degree of a vertex is the number of edges touching it.

Practice Problems

1. Compute $14 \bmod 4$.
2. Compute $31 \bmod 6$.
3. What does $a \equiv b \pmod n$ mean?
4. What is a vertex?
5. What is the degree of a vertex?
Show Answer Key

1. $2$

2. $1$

3. They have the same remainder when divided by $n$

4. A node or point in a graph

5. The number of incident edges