Skip to content

Cosets and Lagrange's Theorem

In this lesson you’ll learn what a coset is, why cosets partition a group into equal-sized blocks, and how that single observation proves Lagrange’s theorem, the most-used counting result in group theory.

Let HGH \le G and aGa \in G. The left coset of HH by aa is

aH={ah:hH}aH = \{ah : h \in H\}

Think of it as HH translated by aa. There’s a matching notion of right coset Ha={ha:hH}Ha = \{ha : h \in H\}.

Cosets are almost never subgroups. aHaH contains the identity only when aHa \in H, in which case aH=HaH = H exactly. So among all the cosets of HH, precisely one is a subgroup: HH itself.

Here’s the key structural fact, and everything else in the lesson is a consequence.

The left cosets of HH partition GG. They cover everything and never overlap. Two things to prove.

Every element is in some coset. For aGa \in G, we have a=aeaHa = ae \in aH since eHe \in H.

Two cosets are either identical or disjoint. Suppose aHaH and bHbH share an element xx. Then x=ah1=bh2x = ah_1 = bh_2 for some h1,h2Hh_1, h_2 \in H, so a=bh2h11a = bh_2h_1^{-1}. Since h2h11Hh_2h_1^{-1} \in H, every element ahah of aHaH equals b(h2h11h)bHb(h_2h_1^{-1}h) \in bH, giving aHbHaH \subseteq bH. The same argument the other way gives bHaHbH \subseteq aH, so the two cosets are equal.

So overlapping cosets coincide entirely. There’s no partial overlap.

aH=H|aH| = |H| for every aa. The map hahh \mapsto ah from HH to aHaH is onto by definition, and it’s injective by cancellation: ah1=ah2ah_1 = ah_2 forces h1=h2h_1 = h_2.

So a coset is a perfect copy of HH, just relocated. Combined with the partition property, this is a very rigid picture: GG is tiled by non-overlapping blocks all of size H|H|.

Count the elements two ways and you’re done.

Lagrange’s theorem. If GG is finite and HGH \le G, then

G=[G:H]H|G| = [G:H] \cdot |H|

In particular, H|H| divides G|G|.

Proof: the cosets partition GG into [G:H][G:H] blocks, each of size H|H|. ∎

That’s it. A two-line proof that constrains every finite group in existence.

The divisibility statement is the workhorse.

The order of every element divides G|G|. Because a=a|a| = |\langle a \rangle|, and a\langle a \rangle is a subgroup.

aG=ea^{|G|} = e for every aa. Write G=ak|G| = |a| \cdot k; then aG=(aa)k=ek=ea^{|G|} = (a^{|a|})^k = e^k = e.

Every group of prime order is cyclic. Any aea \ne e generates a subgroup of order dividing pp and bigger than 1, hence order pp, hence everything.

Groups of order 4 have no element of order 3. Since 3 doesn’t divide 4. This kind of instant elimination is what makes classification arguments possible.

Lagrange says every subgroup’s order divides G|G|. It does not say that every divisor gives a subgroup.

A4A_4 has order 12, and 4124 \mid 12… but A4A_4 has no subgroup of order 6. So a divisor can fail to be realized. Cyclic groups do have a subgroup for every divisor, which is a special property of theirs, not a general truth.

Partial converses exist and are important. Cauchy’s theorem says if a prime pp divides G|G| then GG has an element of order pp. The Sylow theorems guarantee subgroups of prime-power order. But the naive converse is simply false.

In an abelian group aH=HaaH = Ha always. In a non-abelian group they can differ.

In S3S_3, take H={e,s}H = \{e, s\} where ss is a transposition. Then rH={r,rs}rH = \{r, rs\} while Hr={r,sr}={r,r2s}Hr = \{r, sr\} = \{r, r^2s\}. Different sets.

The number of left cosets always equals the number of right cosets, so the index is unambiguous. But whether aH=HaaH = Ha for every aa is a special condition, and it’s exactly the definition of a normal subgroup - the subject of the next lesson.

Example 1: Find the cosets of H={0,3,6,9}H = \{0, 3, 6, 9\} in Z12\mathbb{Z}_{12}.

Solution. H=3H = \langle 3 \rangle, of order 4.

0+H={0,3,6,9}=H0 + H = \{0,3,6,9\} = H 1+H={1,4,7,10}1 + H = \{1,4,7,10\} 2+H={2,5,8,11}2 + H = \{2,5,8,11\}

Now 3+H={3,6,9,0}=H3 + H = \{3,6,9,0\} = H again, so we’re done. Three cosets.

[G:H]=3,G=34=12 [G:H] = 3, \qquad |G| = 3 \cdot 4 = 12 \ \checkmark

Notice these are exactly the residue classes mod 3, which is not a coincidence: cosets of 3\langle 3 \rangle in Z12\mathbb{Z}_{12} record the remainder on division by 3.

Example 2: Cosets of 3Z3\mathbb{Z} in Z\mathbb{Z}.

Solution. H=3Z={,3,0,3,6,}H = 3\mathbb{Z} = \{\dots,-3,0,3,6,\dots\}.

0+H={,3,0,3,},1+H={,2,1,4,},2+H={,1,2,5,}0 + H = \{\dots, -3, 0, 3, \dots\}, \quad 1 + H = \{\dots, -2, 1, 4, \dots\}, \quad 2 + H = \{\dots, -1, 2, 5, \dots\}

3+H=H3 + H = H, so there are exactly three: [Z:3Z]=3[\mathbb{Z} : 3\mathbb{Z}] = 3.

Both G|G| and H|H| are infinite here, so Lagrange’s equation doesn’t apply numerically, but the index is still a perfectly good finite number. These three cosets are the congruence classes mod 3, which is where the notation Z/3Z\mathbb{Z}/3\mathbb{Z} comes from.

Example 3: Show left and right cosets can differ.

In S3={e,r,r2,s,rs,r2s}S_3 = \{e, r, r^2, s, rs, r^2s\} with H={e,s}H = \{e, s\}.

Solution. Using sr=r2ssr = r^2s:

rH={re,rs}={r,rs}rH = \{r \cdot e, r \cdot s\} = \{r, rs\} Hr={er,sr}={r,r2s}Hr = \{e \cdot r, s \cdot r\} = \{r, r^2 s\}

rHHrrH \ne Hr since rsr2srs \ne r^2s.

So HH is not normal in S3S_3. By contrast the rotation subgroup {e,r,r2}\{e, r, r^2\} is normal, and having index 2 is the reason, as the next lesson explains.

Example 4: Use Lagrange to rule things out.

A group GG has order 15. What element orders are possible?

Solution. Orders must divide 15, so they lie in {1,3,5,15}\{1, 3, 5, 15\}.

Order 1 belongs to the identity alone. So every non-identity element has order 3, 5, or 15. No element of order 2, and hence no element is its own inverse except ee.

A stronger conclusion is available: every group of order 15 is in fact cyclic, so there’s exactly one. That needs the Sylow theorems, but Lagrange alone already eliminated most possibilities.

Example 5: Fermat’s little theorem from Lagrange.

Prove that if pp is prime and gcd(a,p)=1\gcd(a,p) = 1 then ap11(modp)a^{p-1} \equiv 1 \pmod p.

Solution. Work in U(p)U(p), the nonzero residues mod pp under multiplication. Since pp is prime, U(p)=p1|U(p)| = p - 1.

The condition gcd(a,p)=1\gcd(a,p)=1 says aU(p)a \in U(p). By the corollary of Lagrange that xG=ex^{|G|} = e for all xx:

ap11(modp)a^{p-1} \equiv 1 \pmod p

A cornerstone of number theory, and it’s a two-line consequence of counting cosets. The generalization to composite modulus, Euler’s theorem aφ(n)1(modn)a^{\varphi(n)} \equiv 1 \pmod n, is the same argument in U(n)U(n), and it is what makes RSA decryption work.

Example 6: A group of order 12 with no subgroup of order 6.

Solution. Take A4A_4, the even permutations of four objects, A4=12|A_4| = 12.

Suppose HA4H \le A_4 with H=6|H| = 6. Then [A4:H]=2[A_4 : H] = 2, and any index-2 subgroup is normal, with A4/HZ2A_4/H \cong \mathbb{Z}_2. So x2Hx^2 \in H for every xA4x \in A_4.

But A4A_4 contains eight 3-cycles, and for a 3-cycle xx we have x2=x1x^2 = x^{-1}, also a 3-cycle. As xx ranges over all eight 3-cycles, x2x^2 does too, so HH would have to contain all eight of them plus the identity: at least 9 elements. That contradicts H=6|H| = 6.

No subgroup of order 6 exists, even though 6126 \mid 12. This is the standard counterexample to the converse of Lagrange.

Error-correcting codes. A linear code CC is a subgroup of (Z2n,+)(\mathbb{Z}_2^n, +), and the cosets of CC are the possible “error patterns.” Decoding a received word means identifying which coset it lies in and correcting by that coset’s most likely error, its coset leader. Standard-array decoding is literally a table of cosets, and Lagrange tells you how many rows it has.

RSA. The key equation ed1(modφ(n))ed \equiv 1 \pmod{\varphi(n)} and the decryption step both rest on Euler’s theorem, which is Lagrange applied to U(n)U(n). Security comes from φ(n)\varphi(n) being hard to compute without factoring nn.

Rubik’s cube. God’s number, the 20-move upper bound for solving any scramble, was proved in 2010 by partitioning the cube group into cosets of a large subgroup and searching each coset separately. Roughly two billion cosets were analysed; the coset decomposition is what made the problem finite enough to attack.

Crystallography. A crystal is described by a lattice group, and the distinct atom positions correspond to cosets of the site’s stabilizer. The count of symmetry-inequivalent positions is an index computation.

Balanced tournament design. Scheduling round-robins and balanced incomplete block designs often uses cosets of a subgroup of Zn\mathbb{Z}_n to generate rounds, guaranteeing every pair meets exactly once.

In ℤ₁₈, how many distinct cosets does the subgroup H = ⟨6⟩ = {0, 6, 12} have?
What does Lagrange's theorem guarantee?
A group has order 20. Which is NOT a possible order for one of its elements?
Why do two cosets of H that share a single element have to be identical?
Which theorem follows from the fact that a^|G| = e in any finite group?
In a non-abelian group, what can be said about aH and Ha?