Subgroups & Lagrange's Theorem

Most groups have smaller groups living inside them: the rotations inside a dihedral group, the even numbers inside $\mathbb{Z}$. This page is about those groups-within-groups. We'll learn how to check that a subset is one, how to build the smallest one containing whatever elements you like, and how to draw all of them at once. Then we'll count them, and the counting gives one of the most useful theorems in the course: the size of a subgroup always divides the size of the group. Everything here is written multiplicatively.

Subgroups

Suppose $G$ is a group. Here's the definition.

A group needs four axioms, and a subgroup only checks two? The subgroup is copying the group's homework, and it's allowed to.

We say that a non-empty subset $H \subseteq G$ is a subgroup of $G$ if:

  1. $\forall g, h \in H$, $gh \in H$ (closed under multiplication), and
  2. $\forall g \in H$, $g^{-1} \in H$ (closed under inverses).

Notation: $H \le G$.

Only two conditions, and yet they're enough. These conditions guarantee that $H$ is a group with respect to the binary operation on $G$. Here's why each group axiom holds:

Notice how "non-empty" quietly did real work in the identity bullet: we needed some element $g$ to start from. Now for examples. The first one is written additively, so "$gh$" becomes $g + h$ and "$g^{-1}$" becomes $-g$.

$G = \mathbb{Z}$, $H = 2\mathbb{Z} = \{2k : k \in \mathbb{Z}\}$. Is $H \le G$?


$H$ is non-empty ($0 \in H$). $\forall g, h \in H$, $\exists k, l \in \mathbb{Z}$ s.t. $g = 2k$, $h = 2l$. So $g + h = 2(k + l) \in H$ and $-g = 2(-k) \in H$. Therefore $2\mathbb{Z} \le \mathbb{Z}$.

Nothing about the number $2$ mattered there.

$G = \mathbb{Z}$, $H = n\mathbb{Z} = \{nk : k \in \mathbb{Z}\}$, where $n \in \mathbb{Z}$.


The same argument with $2$ replaced by $n$: $nk + nl = n(k + l) \in H$ and $-(nk) = n(-k) \in H$. So $n\mathbb{Z} \le \mathbb{Z}$ for every $n$. (Even $n = 0$, which gives $\{0\}$.)

Next, some finite examples, using groups from the Foundations pages.

$V_4$ and $D_{2n}$ were introduced by their presentations on Groups of Order 4–8. Every multiplication below uses only those relations.

$G = C_6 = \langle x \mid x^6 = e \rangle = \{e, x, x^2, x^3, x^4, x^5\}$. Two subgroups: $H_1 = \{e, x^3\}$ and $H_2 = \{e, x^2, x^4\}$.


$H_1$: $x^3 x^3 = x^6 = e$, so $x^3$ is its own inverse, and every product stays inside.

$H_2$: $x^2 x^2 = x^4$, $x^2 x^4 = x^6 = e$, $x^4 x^4 = x^8 = x^2$, and $(x^2)^{-1} = x^4$.

$G = V_4 = \langle a, b \mid a^2 = b^2 = e, ab = ba \rangle = \{e, a, b, ab\}$. Three subgroups: $H_1 = \{e, a\}$, $H_2 = \{e, b\}$, $H_3 = \{e, ab\}$.


Every non-identity element of $V_4$ squares to $e$ (for $ab$: $(ab)^2 = abab = a^2b^2 = e$), so each $\{e, g\}$ is closed and contains its inverses.

$G = D_{2n} = \langle r, s \mid r^n = s^2 = e, rs = sr^{-1} \rangle$ ($n \ge 3$) $= \{e, r, r^2, \dots, r^{n-1}, s, sr, \dots, sr^{n-1}\}$.


$H_1 = \{e, r, r^2, \dots, r^{n-1}\}$ (the rotations) and $H_2 = \{e, s\}$ are subgroups ($\dots$ and there are more).

Those examples were easy to check because the sets were small. Most subsets aren't subgroups, though, and one bad product is all it takes to rule one out.

Is $\{e, r^2, s, sr^2\}$ a subgroup of $D_8$? Is $\{e, s, sr\}$ a subgroup of $D_6$?

Show answer

In $D_8$ the relation gives $r^2 s = s r^{-2} = sr^2$, so $r^2$ commutes with $s$. Then $r^2 \cdot r^2 = e$, $r^2 \cdot s = sr^2$, $r^2 \cdot sr^2 = s r^4 = s$, $s \cdot sr^2 = r^2$, $sr^2 \cdot s = s s r^{-2} = r^2$, and every element squares to $e$ (for example $(sr^2)^2 = s r^2 s r^2 = s s r^{-2} r^2 = e$). Every product lands back in the set, and every element is its own inverse. Yes, it's a subgroup.

In $D_6$, $s \cdot sr = s^2 r = r \notin \{e, s, sr\}$. No: it isn't closed under multiplication.

Some Facts and Terminology

Let $G$ be a group. Every group has at least two subgroups without trying: $G \le G$ and $\{e\} \le G$.

$\{e\}$ is called the trivial subgroup of $G$.

The other one, $G$ itself, is a bit too big to be interesting, so the subgroups that aren't the whole group get their own name.

If $H \le G$ and $H \neq G$ then $H$ is called a proper subgroup of $G$.

Checking two conditions every time gets old. The first shortcut packs them into one.

If $H \subseteq G$ is non-empty then $H \le G$ if and only if $\forall g, h \in H$, $gh^{-1} \in H$.

Proof.

Never skip the "non-empty" check. The empty set passes "$\forall g, h \in H$, $gh^{-1} \in H$" automatically, since there's nothing in it to fail, but $\emptyset$ is not a subgroup (it has no identity). The quickest way to show non-emptiness is almost always to show $e \in H$.

For finite sets, there's an even lazier test: closure under inverses comes for free.

If $H \subseteq G$ is non-empty and $|H| \lt \infty$ then $H \le G$ if and only if $\forall g, h \in H$, $gh \in H$.

Proof. ($\Rightarrow$) is condition (i). For ($\Leftarrow$), we only need to show that $H$ is closed under taking inverses. Let $g \in H$. By closure, $\{g, g^2, g^3, \dots\} \subseteq H$. Since $|H| \lt \infty$, these powers can't all be different, so $\exists i, j \in \mathbb{N}$ with $i \lt j$ and $g^i = g^j$. Multiplying both sides by $g^{-i}$ (in $G$) gives $g^{j-i} = e$.

The word "finite" is doing all the work. $\mathbb{N} = \{1, 2, 3, \dots\} \subseteq \mathbb{Z}$ is non-empty and closed under $+$, but it isn't a subgroup: $-1 \notin \mathbb{N}$. In an infinite set the powers $g, g^2, g^3, \dots$ can march off forever without ever repeating.

Try the finite criterion yourself. Pick elements to put in $H$, and the widget builds $H$'s own multiplication table. As soon as every product stays inside, $H$ is a subgroup, and you'll see the inverses were there all along.

The Closure Checker

Pick a group, then tap elements to add them to $H$ or take them out. Products that escape $H$ are outlined in red.

One more fact, and it's the one that makes the next section possible: subgroups can be intersected, and the result is still a subgroup. This works for any non-empty collection, even infinitely many subgroups at once.

If $\{H_i\}_{i \in I}$ is a non-empty collection of subgroups of $G$, then $\bigcap_{i \in I} H_i$ is also a subgroup of $G$.

Proof. Write $H = \bigcap_{i \in I} H_i$. Then:

It follows from the subgroup criterion that $H \le G$. $\blacksquare$

Unions, on the other hand, are a different story.

Show that $2\mathbb{Z} \cup 3\mathbb{Z}$ is not a subgroup of $\mathbb{Z}$.

Show answer

$2 \in 2\mathbb{Z}$ and $3 \in 3\mathbb{Z}$, so both are in the union. But $2 + 3 = 5$ is neither even nor a multiple of $3$, so $5 \notin 2\mathbb{Z} \cup 3\mathbb{Z}$. The union isn't closed under addition.

Let $G$ be an Abelian group. Prove that $H = \{g \in G : g^2 = e\}$ is a subgroup of $G$. Then show that the same set is not a subgroup when $G = D_6$.

Show proof

Proof. $e^2 = e$, so $e \in H$ and $H \neq \emptyset$. Let $g, h \in H$. Since $G$ is Abelian, $(gh^{-1})^2 = g^2 (h^{-1})^2 = g^2 (h^2)^{-1} = e \cdot e^{-1} = e$, so $gh^{-1} \in H$. By the subgroup criterion, $H \le G$. $\blacksquare$

In $D_6$, the elements squaring to $e$ are $e, s, sr, sr^2$. But $s \cdot sr = r$, and $r^2 \neq e$, so the set isn't closed. The proof broke at the step $(gh^{-1})^2 = g^2(h^{-1})^2$, which needs $g$ and $h^{-1}$ to commute.

The Subgroup Generated by a Subset

Suppose you have a handful of elements $S \subseteq G$ and you want a subgroup containing them. $G$ itself always works, but that's lazy. What's the smallest subgroup containing $S$? The intersection theorem hands us the answer.

Intersect every subgroup that contains $S$, even the ones I've never met? Without listing a single element? Bold. Also legal.

If $S \subseteq G$ then the subgroup generated by $S$, denoted $\langle S \rangle$, is the intersection of all subgroups of $G$ which contain $S$.

A few things to notice about that definition:

This is consistent with the notation from Groups of Order 1–3: $\langle g \rangle = \{g^n : n \in \mathbb{Z}\}$ for $g \in G$, the cyclic subgroup generated by $g$. The theorem at the end of this section shows the two meanings agree.

Groups that can be built from finitely many elements get a name.

If $G = \langle S \rangle$ for a finite set $S \subseteq G$, then we say that $G$ is finitely generated.

$|G| \lt \infty \Rightarrow G$ finitely generated ($G = \langle G \rangle$). However, in general, $|G| = \infty \not\Rightarrow G$ not finitely generated.

Let's revisit the earlier examples. Each subgroup we found turns out to be generated by just one or two elements.

Examples. Find generators for the subgroups from the first section.


  1. For any group $G$, if we take $S = \emptyset$, then $\langle S \rangle = \{e\}$. (Every subgroup contains $\emptyset$, and $\{e\}$ is the smallest subgroup.)
  2. $G = \mathbb{Z}$, $H = n\mathbb{Z} = \{nk : k \in \mathbb{Z}\} = \langle n \rangle$ ($n \in \mathbb{Z}$). Note: $|\mathbb{Z}| = \infty$, but $\mathbb{Z} = \langle 1 \rangle$ is finitely generated.
  3. $G = C_6 = \{e, x, x^2, x^3, x^4, x^5\} = \langle x \rangle$. $H_1 = \{e, x^3\} = \langle x^3 \rangle$. $H_2 = \{e, x^2, x^4\} = \langle x^2 \rangle = \langle x^4 \rangle$ (since $(x^4)^2 = x^8 = x^2$).
  4. $G = V_4 = \{e, a, b, ab\} = \langle a, b \rangle$. $H_1 = \{e, a\} = \langle a \rangle$, $H_2 = \{e, b\} = \langle b \rangle$, $H_3 = \{e, ab\} = \langle ab \rangle$.
  5. $G = D_{2n} = \{e, r, r^2, \dots, r^{n-1}, s, sr, \dots, sr^{n-1}\} = \langle r, s \rangle$. $H_1 = \{e, r, r^2, \dots, r^{n-1}\} = \langle r \rangle$. $H_2 = \{e, s\} = \langle s \rangle$.

That note about infinite groups deserves a counterexample in the other direction too: an infinite group that is not finitely generated. The rationals are the classic one.

Hand me any finite list of fractions and I'll name one you can't build. $\mathbb{Q}$ is the friend who always has one more.

$\mathbb{Q}$ (under $+$) is not finitely generated.

Show proof

Proof. Suppose $S = \{r_1, r_2, \dots, r_n\} \subseteq \mathbb{Q}$, and write $r_i = \frac{p_i}{q_i}$ with $p_i \in \mathbb{Z}$, $q_i \in \mathbb{N}$. Let

$$H = \left\{a_1 r_1 + a_2 r_2 + \dots + a_n r_n : a_1, \dots, a_n \in \mathbb{Z}\right\}.$$

Then:

Therefore $\langle S \rangle = H$.

Now let $q = \text{lcm}(q_1, \dots, q_n)$. Then $\forall x \in H$, since $x = \sum_{i=1}^n a_i \left(\frac{p_i}{q_i}\right)$ for some $a_1, \dots, a_n \in \mathbb{Z}$, we have that

$$qx = \sum_{i=1}^n a_i p_i \left(\frac{q}{q_i}\right) \in \mathbb{Z}.$$

But then, since $q \left(\frac{1}{2q}\right) = \frac{1}{2} \notin \mathbb{Z}$, we find that $\frac{1}{2q} \notin H \Rightarrow H \neq \mathbb{Q}$. No finite set generates $\mathbb{Q}$. $\blacksquare$

The definition of $\langle S \rangle$ as an intersection is clean, but it doesn't tell you what's actually in it. This theorem does: $\langle S \rangle$ is everything you can spell using elements of $S$ and their inverses.

If $G$ is a group and $S \subseteq G$ is non-empty, then

$$\langle S \rangle = \{g_1^{u_1} g_2^{u_2} \cdots g_n^{u_n} : n \in \mathbb{N},\ g_1, \dots, g_n \in S,\ u_1, \dots, u_n \in \{\pm 1\}\}.$$

(Order matters, in general, and the $g_i$ are not necessarily distinct.)

Proof. Let $H = \{g_1^{u_1} g_2^{u_2} \cdots g_n^{u_n} : n \in \mathbb{N},\ g_1, \dots, g_n \in S,\ u_1, \dots, u_n \in \{\pm 1\}\}$. Then:

Therefore $\langle S \rangle = H$. $\blacksquare$

The "non-empty" is there because of item 0 in Example 6: with $S = \emptyset$ there are no products to write down, yet $\langle \emptyset \rangle = \{e\}$. When $G$ is Abelian, the order of the factors stops mattering, so we can gather all the copies of each generator together.

If $G$ is Abelian and $S \subseteq G$ is non-empty, then

$$\langle S \rangle = \{g_1^{a_1} \cdots g_n^{a_n} : g_1, \dots, g_n \in S,\ a_1, \dots, a_n \in \mathbb{Z},\ g_i \neq g_j \text{ for } i \neq j\}.$$

In particular, if $S = \{g_1, \dots, g_n\}$ then

$$\langle S \rangle = \{g_1^{a_1} \cdots g_n^{a_n} : a_1, \dots, a_n \in \mathbb{Z}\}.$$

Watch the theorem in action. Round 1 is the elements of $S$ and their inverses. Each round after that multiplies everything so far by one more letter. When a round adds nothing new, you've found all of $\langle S \rangle$.

Generator Growth

Tap elements to put them in $S$, then press "Next round" to spell longer and longer words. Each tile shows the shortest word that reaches it.

Find $\langle 4, 6 \rangle$ in $\mathbb{Z}$, and $\langle r^2, s \rangle$ in $D_8$.

Show answer

$\mathbb{Z}$ is Abelian, so by the corollary (written additively) $\langle 4, 6 \rangle = \{4a + 6b : a, b \in \mathbb{Z}\}$. Every such number is even, so $\langle 4, 6 \rangle \subseteq 2\mathbb{Z}$. And $2 = 6 - 4 \in \langle 4, 6 \rangle$, so $2\mathbb{Z} = \langle 2 \rangle \subseteq \langle 4, 6 \rangle$. Therefore $\langle 4, 6 \rangle = 2\mathbb{Z}$. (This is Bézout's lemma in disguise: $\gcd(4, 6) = 2$.)

In $D_8$, $\{e, r^2, s, sr^2\}$ is a subgroup (from the first exercise) containing $r^2$ and $s$, so $\langle r^2, s \rangle \subseteq \{e, r^2, s, sr^2\}$. Conversely, $\langle r^2, s \rangle$ contains $r^2$, $s$, $r^2 \cdot r^2 = e$, and $s r^2$. So $\langle r^2, s \rangle = \{e, r^2, s, sr^2\}$.

Cyclic Subgroups and Orders of Elements

The simplest generated subgroups use a single element: $\langle g \rangle$. How big is it? That depends on how long it takes the powers of $g$ to come back around to $e$.

If $g \in G$ then the order of $g$, denoted $|g|$ or $o(g)$, is defined to be the smallest $k \in \mathbb{N}$ satisfying $g^k = e$, or $\infty$ if there is no such $k$.

The bars are overloaded: $|G|$ is the number of elements in a group, while $|g|$ is the order of one element. Lowercase or uppercase is often the only clue, which is why some books prefer $o(g)$. The theorem below explains why the notation is shared.

To find an order, keep multiplying by $g$ until you hit $e$.

$G = C_6 = \{e, x, x^2, x^3, x^4, x^5\} = \langle x \rangle$. Find the order of every element.


$$\begin{align*} |e| &= 1 \\ |x| &= 6 \\ |x^2| &= 3 \quad ((x^2)^1 = x^2,\ (x^2)^2 = x^4,\ (x^2)^3 = x^6 = e) \\ |x^3| &= 2 \quad ((x^3)^1 = x^3,\ (x^3)^2 = x^6 = e) \\ |x^4| &= 3 \quad ((x^4)^1 = x^4,\ (x^4)^2 = x^8 = x^2,\ (x^4)^3 = x^{12} = e) \\ |x^5| &= 6 \quad (x^5 = x^{-1} \Rightarrow (x^5)^i = x^{-i},\ 1 \le i \le 6 \rightarrow x^5, x^4, x^3, x^2, x, e) \end{align*}$$

$G = D_6 = \langle r, s \mid r^3 = s^2 = e, rs = sr^{-1} \rangle = \{e, r, r^2, s, sr, sr^2\}$. Find the order of every element.


$$\begin{align*} |e| &= 1 \\ |r| &= |r^2| = 3 \\ |s| &= 2 \\ |sr| &= 2 \quad ((sr)^2 = (sr)(sr) = s(rs)r = s(sr^{-1})r = s^2(r^{-1}r) = e) \\ |sr^2| &= 2 \quad (r^2 s = r(rs) = r(sr^{-1}) = (rs)r^{-1} = sr^{-2} \Rightarrow \\ &\qquad\quad (sr^2)^2 = (sr^2)(sr^2) = s(r^2 s)r^2 = s^2 r^{-2} r^2 = e) \end{align*}$$

$G = \mathbb{Z}$, $n \in \mathbb{Z}$. Find $|n|$.


Written additively, "$g^k = e$" becomes $kn = 0$. That only happens for $k \in \mathbb{N}$ when $n = 0$, so $$|n| = \begin{cases} 1 & \text{if } n = 0 \\ \infty & \text{if } n \neq 0 \end{cases}$$

In $C_6$, the orders were $1, 6, 3, 2, 3, 6$, and the cyclic subgroups had sizes $|\langle x^3 \rangle| = 2$ and $|\langle x^2 \rangle| = 3$. That's not a coincidence.

$\forall g \in G$, $|g| = |\langle g \rangle|$. More precisely:

  1. If $|g| = \infty$ then $g^i \neq g^j$, $\forall i, j \in \mathbb{Z}$ with $i \neq j$.
  2. If $|g| = k \in \mathbb{N}$ then $\langle g \rangle = \{e, g, g^2, \dots, g^{k-1}\}$, and $g^i = g^j$ for $i, j \in \mathbb{Z}$ iff $i \equiv j \pmod k$.

Part (ii) runs on the Division Algorithm: divide an exponent by $k$ and only the remainder matters.

Proof. To prove (i), consider the contrapositive. Suppose that $g^i = g^j$ for some $i, j \in \mathbb{Z}$ with $i \neq j$. W.L.O.G., suppose $i \lt j$. Then $g^{j-i} = e$ and $j - i \in \mathbb{N} \Rightarrow |g| \lt \infty$. This establishes (i).

To prove (ii), suppose $|g| = k$ and $g^i = g^j$ for some $i, j \in \mathbb{Z}$. Then $g^{j-i} = e$. By the Division Algorithm, $\exists q, r \in \mathbb{Z}$ with $0 \le r \lt k$ s.t. $j - i = qk + r$. Since

$$e = g^{j-i} = g^{qk+r} = (g^k)^q g^r = e^q g^r = g^r,$$

and since $k$ is the smallest element of $\mathbb{N}$ satisfying $g^k = e$, it follows that $r = 0$. Then $j - i = qk \Rightarrow i \equiv j \pmod k$. Conversely, $i \equiv j \pmod k \Rightarrow j - i = qk \Rightarrow g^{j-i} = (g^k)^q = e \Rightarrow g^j = g^i$.

Finally, every element of $\langle g \rangle$ is a power $g^n$. Dividing, $n = qk + r$ with $0 \le r \lt k$, and $g^n = (g^k)^q g^r = g^r$, so $\langle g \rangle \subseteq \{e, g, \dots, g^{k-1}\}$ (and the other inclusion is clear). These $k$ powers are all different, because no two of $0, 1, \dots, k-1$ are congruent mod $k$. Therefore $\langle g \rangle = \{e, g, g^2, \dots, g^{k-1}\}$ and $|\langle g \rangle| = k$. $\blacksquare$

Part (ii) says the exponents of $g$ wrap around with period $|g|$, in both directions. Lay the integers out in a line and you can see it: pick any exponent, and every exponent that gives the same element lights up, spaced exactly $|g|$ apart.

The Exponent Ribbon

Pick a group and an element $g$. Each cell shows $g^i$ for one exponent $i$. Tap a cell to light up every exponent with the same value.

Find the order of every element of $(\mathbb{Z}/9\mathbb{Z})^\times = \{1, 2, 4, 5, 7, 8\}$.

Show answer

Multiply until you reach $1$ (all mod $9$):

  • $|1| = 1$
  • $|2| = 6$: $2, 4, 8, 7, 5, 1$
  • $|4| = 3$: $4, 7, 1$
  • $|5| = 6$: $5, 7, 8, 4, 2, 1$
  • $|7| = 3$: $7, 4, 1$
  • $|8| = 2$: $8, 1$

So $2$ and $5$ generate the whole group, matching the primitive roots mod $9$ from Modular Arithmetic.

Lattice of Subgroups of a Group

Once you've found the subgroups of a group, it helps to see how they fit inside each other.

The lattice of subgroups of a group is a diagram illustrating the subgroups of the group. Line segments indicate set containments.

The whole group goes at the top, $\{e\}$ at the bottom, and a line joins a subgroup to the bigger subgroups directly above it.

$G = V_4 = \{e, a, b, ab\} = \langle a, b \rangle$.


$H_1 = \{e, a\} = \langle a \rangle$, $H_2 = \{e, b\} = \langle b \rangle$, $H_3 = \{e, ab\} = \langle ab \rangle$. The diagram has $G$ at the top, connected to $H_1, H_2, H_3$ in the middle, all connected to $\{e\}$ at the bottom.

$G = C_6 = \{e, x, x^2, x^3, x^4, x^5\} = \langle x \rangle$.


$H_1 = \{e, x^3\} = \langle x^3 \rangle$ ($|H_1| = 2$) and $H_2 = \{e, x^2, x^4\} = \langle x^2 \rangle = \langle x^4 \rangle$ ($|H_2| = 3$). Both connect up to $G$ and down to $\{e\}$, with $H_2$ drawn a little higher than $H_1$.

For finite groups, relative vertical position indicates differences in order.

The third example is the first non-Abelian one, and it comes with an argument that nothing has been missed.

$G = D_6 = \langle r, s \mid r^3 = s^2 = e, rs = sr^{-1} \rangle = \{e, r, r^2, s, sr, sr^2\}$.


$H_1 = \langle r \rangle = \{e, r, r^2\} = \langle r^2 \rangle$, $H_2 = \langle s \rangle = \{e, s\}$, $H_3 = \langle sr \rangle = \{e, sr\}$, $H_4 = \langle sr^2 \rangle = \{e, sr^2\}$.

$G$ connects down to $\langle r \rangle$ (order $3$) and to $\langle s \rangle$, $\langle sr \rangle$, $\langle sr^2 \rangle$ (order $2$), and each of those connects down to $\{e\}$.

This is the complete list of subgroups of $G$ because:

So a proper subgroup holds either rotations only or a single reflection only, never both, which leaves exactly the four above plus $\{e\}$.

The explorer below draws all three lattices, plus two bigger ones. Look at the scale on the left: every subgroup sits at a height that divides $|G|$. Keep that in mind for the next section.

The Lattice Explorer

Pick a group. Tap a subgroup to see its elements and light up everything it contains and everything that contains it.

In $C_{12}$, every subgroup is $\langle x^d \rangle$ for a divisor $d$ of $12$. The Cyclic Groups page proves that every subgroup of a cyclic group is cyclic, which is why that list is complete.

Let $C_{12} = \langle x \rangle$. Find the orders of the subgroups $\langle x \rangle$, $\langle x^2 \rangle$, $\langle x^3 \rangle$, $\langle x^4 \rangle$, $\langle x^6 \rangle$, $\langle x^{12} \rangle$, and draw the lattice they form.

Show answer

Using $|\langle g \rangle| = |g|$: $|x| = 12$, $|x^2| = 6$, $|x^3| = 4$, $|x^4| = 3$, $|x^6| = 2$, $|x^{12}| = |e| = 1$.

Containments: $\langle x^a \rangle \subseteq \langle x^b \rangle$ exactly when $b \mid a$ (a power of $x^a$ is a power of $x^b$). So:

  • Top: $\langle x \rangle = C_{12}$, connected to $\langle x^2 \rangle$ (order $6$) and $\langle x^3 \rangle$ (order $4$).
  • $\langle x^2 \rangle$ connects down to $\langle x^4 \rangle$ (order $3$) and $\langle x^6 \rangle$ (order $2$).
  • $\langle x^3 \rangle$ connects down to $\langle x^6 \rangle$.
  • $\langle x^4 \rangle$ and $\langle x^6 \rangle$ connect down to $\{e\}$.

Check your drawing against $C_{12}$ in the Lattice Explorer.

Lagrange's Theorem

Every lattice so far had subgroups only at heights that divide $|G|$: orders $1, 2, 4$ in $V_4$, and $1, 2, 3, 6$ in $C_6$ and $D_6$. Here's why. The proof chops $G$ into pieces that all have the same size as $H$, and those pieces have a name.

If $H \le G$ and $g \in G$, the left coset of $H$ by $g$ is $gH = \{gh : h \in H\}$.

Multiply on the other side and you get the mirror image.

If $H \le G$ and $g \in G$, the right coset of $H$ by $g$ is $Hg = \{hg : h \in H\}$.

In an Abelian group, $gH = Hg$ always. In general they can differ, and the subgroups where they always agree are the normal subgroups.

Notice that $g = ge \in gH$, so every element lives in at least one left coset (its own). Now the theorem.

Lagrange died in 1813. Nobody had defined a group yet. Naming rights are a strange business.

If $G$ is a finite group and $H \le G$, then $|H| \mid |G|$.

Proof.

Step 1 builds an equivalence relation, and the equivalence classes of any equivalence relation partition the set. That's the whole strategy.

Step 1: Define a relation $\sim$ on $G$ by the rule that, $\forall g, g' \in G$, $g \sim g'$ if and only if $\exists h \in H$ s.t. $g = g'h$. This relation is:

Therefore, the relation $\sim$ is an equivalence relation on $G$. (Its equivalence class containing $g'$ is $\{g'h : h \in H\} = g'H$: the equivalence classes are exactly the left cosets of $H$.)

Step 2 counts with a bijection: if a function between two finite sets is injective and surjective, the sets have the same number of elements.

Step 2: Let $A_1, \dots, A_k$ be the equivalence classes of $\sim$. Note that there are only finitely many, and that $|A_i| \lt \infty$, $1 \le i \le k$, because $|G| \lt \infty$. Since $\{A_i\}_{i=1}^k$ is a partition of $G$, we have that $|G| = \sum_{i=1}^k |A_i|$.

Now suppose $1 \le i \le k$, choose $g \in A_i$, and define a map $\tau : H \rightarrow A_i$ by $\tau(h) = gh$, $\forall h \in H$. The map $\tau$ is:

Therefore $\tau$ is a bijection, so $|H| = |A_i|$ ($\forall 1 \le i \le k$). Finally,

$$|G| = \sum_{i=1}^k |A_i| = k|H| \Rightarrow |H| \mid |G|. \qquad \blacksquare$$

So the left cosets tile $G$ with $k$ tiles, each exactly the size of $H$. Build the tiling yourself: tap any element that isn't covered yet, and its whole coset slides into place as a new row.

The Coset Tiler

Pick a group and a subgroup $H$. Tap an uncovered element $g$ to add the row $gH$. Tap a covered element to see which row it belongs to.

A warning before the consequences: Lagrange's theorem only goes one way.

Lagrange says the order of a subgroup must divide $|G|$. It does not say that every divisor of $|G|$ is the order of some subgroup. A divisor is permission, not a promise. The smallest counterexample has $12$ elements and no subgroup of order $6$; you'll meet it on the Symmetric Groups page.

Consequences of Lagrange's Theorem

Combine Lagrange's theorem with $|g| = |\langle g \rangle|$ and you get facts about single elements.

If $G$ is a finite group and $g \in G$ then $|g| \mid |G|$.

Proof. $|g| = |\langle g \rangle|$ (the theorem in the section on orders), and $|\langle g \rangle| \mid |G|$ by Lagrange's theorem, since $\langle g \rangle \le G$. $\blacksquare$

If $G$ is a finite group and $g \in G$ then $g^{|G|} = e$.

Proof. $|g| \mid |G| \Rightarrow \exists k \in \mathbb{N}$ s.t. $|G| = k \cdot |g|$. Then $g^{|G|} = (g^{|g|})^k = e^k = e$. $\blacksquare$

That corollary pays off two debts from Foundations. The first: groups of prime order.

Groups of Order 4–8 stated this as a "General Fact (will prove later)." Later is now.

If $G$ is a group with $|G| = p$, where $p$ is prime, then $G = \langle g \rangle$ for every $g \neq e$. In particular, $G \cong C_p$.

Proof. Let $g \in G$ with $g \neq e$. Then $|g| \mid p$ and $|g| \neq 1$ (only $e$ has order $1$), so $|g| = p$. So $\langle g \rangle$ is a subgroup with $|\langle g \rangle| = p = |G|$ elements, which forces $\langle g \rangle = G$. By part (ii) of the order theorem, $G = \{e, g, \dots, g^{p-1}\}$ with $g^i g^j = g^{i+j}$ and exponents read mod $p$, which is exactly the multiplication table of $C_p = \langle x \rangle$ with $g$ renamed $x$. $\blacksquare$

The second debt is Euler's theorem.

Modular Arithmetic used Euler's theorem (and Fermat's, the case $n = p$) without proof, promising that Lagrange would supply one. Here it is, in one line.

If $n \in \mathbb{N}$, $a \in \mathbb{Z}$, and $(a, n) = 1$, then $a^{\varphi(n)} \equiv 1 \pmod n$.

Proof. Let $G = (\mathbb{Z}/n\mathbb{Z})^\times$. Then $|G| = \varphi(n)$, and $(a, n) = 1 \Rightarrow a \in G$. By the above corollary, $a^{\varphi(n)} \equiv 1 \pmod n$. $\blacksquare$

Lagrange also makes primitive roots much cheaper to find. The order of $a$ in $(\mathbb{Z}/p\mathbb{Z})^\times$ has to divide $p - 1$, so instead of checking every exponent up to $p - 1$, we only check the divisors.

Eight exponents instead of $102$. I'd like to thank Lagrange personally for the $94$ multiplications I didn't do.

Example. Show that $5$ is a primitive root mod $103$.


$G = (\mathbb{Z}/103\mathbb{Z})^\times$, $|G| = \varphi(103) = 102 = 2 \cdot 3 \cdot 17$. The divisors of $102$ are the numbers $2^a 3^b 17^c$ with $a, b, c \in \{0, 1\}$: $1, 2, 3, 6, 17, 34, 51, 102$.

Scratch work (squaring repeatedly): $5^1, 5^2, 5^4, 5^8, 5^{16} \equiv 5, 25, 7, 49, 32 \pmod{103}$.

Compute: $$\begin{align*} 5^1 &\equiv 5 \pmod{103} \\ 5^2 &\equiv 25 \pmod{103} \\ 5^3 &\equiv 22 \pmod{103} \\ 5^6 &\equiv (5^3)^2 = 22^2 = 484 \equiv 72 \pmod{103} \\ 5^{17} &\equiv 5^{16} \cdot 5^1 = 32 \cdot 5 = 160 \equiv 57 \pmod{103} \\ 5^{34} &\equiv (5^{17})^2 = 57^2 = 3249 \equiv 56 \pmod{103} \\ 5^{51} &\equiv 5^{34} \cdot 5^{17} = 56 \cdot 57 = 3192 \equiv -1 \pmod{103} \\ 5^{102} &\equiv (5^{51})^2 = (-1)^2 \equiv 1 \pmod{103} \end{align*}$$

By the theorem, $|5|$ divides $102$, and the first divisor $d$ with $5^d \equiv 1$ is $d = 102$. So $|5| = 102$, and $5$ is a primitive root mod $103$.

We can trim that list even further.

You don't need every divisor. If $|a|$ were a proper divisor of $p - 1$, it would divide $(p - 1)/q$ for some prime $q \mid p - 1$, and then $a^{(p-1)/q} \equiv 1$. So it's enough to check $a^{(p-1)/q} \not\equiv 1$ for each prime $q$ dividing $p - 1$. For $103$, that's just $5^{51}$, $5^{34}$, and $5^{6}$: three checks.

Compare the three strategies below: brute force, every divisor, and just the $(p-1)/q$ shortcut.

The Divisor Shortcut

Pick a prime $p$ and a base $a$. Tap the divisors of $p - 1$ to compute $a^d \bmod p$. The strip shows how few of the $p - 1$ exponents you actually need.

Can a group of order $15$ have an element of order $4$? What are the possible orders of elements in a group of order $15$?

Show answer

No. The order of every element divides $|G| = 15$, and $4 \nmid 15$. The only possible orders are the divisors of $15$: $1, 3, 5, 15$. (Order $15$ happens exactly when the group is cyclic.)

Show that $3$ is a primitive root mod $17$.

Show answer

$|(\mathbb{Z}/17\mathbb{Z})^\times| = \varphi(17) = 16 = 2^4$, so $|3| \in \{1, 2, 4, 8, 16\}$. The only prime dividing $16$ is $2$, so by the Pro Tip it's enough to check $3^{8}$:

$$3^2 = 9, \quad 3^4 = 81 \equiv 13, \quad 3^8 \equiv 13^2 = 169 \equiv 16 \equiv -1 \pmod{17}.$$

$3^8 \not\equiv 1$, so $|3|$ doesn't divide $8$, which leaves $|3| = 16$. So $3$ is a primitive root mod $17$.

Spicy Bonus

Lagrange tells you which orders are allowed, but it never promises that any of them actually occur. Here's one case where a pairing argument does promise it.

🌶️ SPICY BONUS 🌶️

Prove that every finite group of even order has an element of order $2$.

Show proof

Proof. Let $G$ be a group with $|G|$ even, and let $T = \{g \in G : g = g^{-1}\}$. An element satisfies $g = g^{-1}$ exactly when $g^2 = e$, that is, when $g = e$ or $|g| = 2$.

The elements of $G \setminus T$ come in pairs $\{g, g^{-1}\}$: each such $g$ is different from its inverse, $(g^{-1})^{-1} = g$, and $g^{-1} \notin T$ too. Distinct pairs don't overlap, since inverses are unique. So $|G \setminus T|$ is even.

Then $|T| = |G| - |G \setminus T|$ is even minus even, so $|T|$ is even. But $e \in T$, so $|T| \ge 1$, and being even, $|T| \ge 2$. Any element of $T$ other than $e$ has order $2$. $\blacksquare$

The same idea works for any prime $p$ in place of $2$ (that's Cauchy's theorem), but the pairing has to be replaced by grouping into $p$-tuples, which takes more cleverness.