Cosets and Lagrange's Theorem

Study Sheet

Cosets and Lagrange's Theorem

Partitioning a group into cosets, and what the size of a group forces

Cosets

Concept
Left and right cosets

For a subgroup H≤GH \le G and g∈Gg \in G, the left coset gH={gh:h∈H}gH = \{gh : h \in H\} and the right coset Hg={hg:h∈H}Hg = \{hg : h \in H\}. The left cosets of HH partition GG: every element of GG lies in exactly one of them.

Cosets come from the equivalence relation a∼ba \sim b iff a−1b∈Ha^{-1}b \in H: reflexive since e∈He \in H, and symmetric and transitive because HH is closed under inverses and products (Topic 3). The equivalence class of gg is exactly gHgH, so the cosets slice GG into disjoint blocks the way remainder classes slice Z\mathbb Z — HH itself plays the role of '0(modn)0 \pmod n'. The map h↦ghh \mapsto gh is a bijection H→gHH \to gH (its inverse is x↦g−1xx \mapsto g^{-1}x), so every coset has exactly ∣H∣|H| elements — the fact the next section turns into a theorem.

Example
Cosets of a subgroup of Z12\mathbb Z_{12}
+036900369336906690399036
H = 0,3,6,9 is itself a group of order 4 under addition mod 12.

In Z12\mathbb Z_{12}, let H=⟨3⟩={0,3,6,9}H = \langle 3\rangle = \{0, 3, 6, 9\}, a subgroup of order 44 (Topic 3). The left cosets g+Hg + H: 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\}. Trying g=3g=3 gives nothing new: 3+H={3,6,9,0}=H3+H = \{3,6,9,0\} = H again. These three cosets are disjoint and their union is all 1212 elements of Z12\mathbb Z_{12}, exactly as the partition claim predicts.

Example
Left and right cosets can differ

In S3S_3 (Topic 4) let H={e,(12)}H = \{e, (12)\}, order 22. Compute the coset of g=(123)g=(123) both ways. Left: (123)H={(123)e, (123)(12)}={(123),(13)}(123)H = \{(123)e,\ (123)(12)\} = \{(123), (13)\}. Right: H(123)={e(123), (12)(123)}={(123),(23)}H(123) = \{e(123),\ (12)(123)\} = \{(123), (23)\}. The two cosets share (123)(123) but are not the same set: (13)≠(23)(13) \ne (23), so gH≠HggH \ne Hg for this gg.

Example
Finding all the cosets of A3A_3 in S3S_3

Let H=A3={e,(123),(132)}H = A_3 = \{e, (123), (132)\} in S3S_3, order 33. Since ∣S3∣=6|S_3|=6 there can be at most 6/3=26/3=2 cosets. HH itself is one. Pick any g∉Hg \notin H, say g=(12)g=(12): gH={(12)e,(12)(123),(12)(132)}={(12),(23),(13)}gH = \{(12)e, (12)(123), (12)(132)\} = \{(12), (23), (13)\}, the three transpositions — accounting for all 66 elements of S3S_3. So S3S_3 splits into exactly two cosets: the even permutations and the odd ones, and any other choice of g∉Hg \notin H gives this same second coset.

Side note
Where it goes wrong

Only HH itself, among its cosets, is a subgroup. A coset gHgH with g∉Hg \notin H never contains the identity (if e∈gHe \in gH then e=ghe=gh for some hh, forcing g=h−1∈Hg=h^{-1}\in H), so it cannot be a subgroup. In the Z12\mathbb Z_{12} example above, 1+H={1,4,7,10}1+H=\{1,4,7,10\} is missing 00 and is not even closed: 1+1=2∉1+H1+1=2 \notin 1+H. 'Coset' names a set that HH acts on by translation, not a group in its own right — unless g∈Hg \in H, in which case gH=HgH=H.

Try it
Try it: cosets of a subgroup of Z12\mathbb Z_{12}

List the left cosets of H=⟨4⟩={0,4,8}H = \langle 4\rangle = \{0,4,8\} in Z12\mathbb Z_{12}.

Show the answer

Here ∣H∣=3|H|=3, so there are 12/3=412/3=4 cosets: 0+H={0,4,8}0+H=\{0,4,8\}, 1+H={1,5,9}1+H=\{1,5,9\}, 2+H={2,6,10}2+H=\{2,6,10\}, 3+H={3,7,11}3+H=\{3,7,11\}. These 4\mathbf{4} cosets partition Z12\mathbb Z_{12}.

Lagrange's Theorem

Concept
Lagrange's theorem

If GG is a finite group and H≤GH \le G, then ∣H∣|H| divides ∣G∣|G|. The quotient [G:H]=∣G∣/∣H∣[G:H] = |G|/|H|, the index of HH, is the number of left cosets of HH in GG.

The left cosets of HH partition GG (Section 1) into blocks that are all the same size, ∣H∣|H|. A set split into blocks of a fixed size kk has a total size that is a multiple of kk — just count the blocks. That is the whole proof, and it is also why the index, defined as a ratio, is automatically a whole number: it counts the cosets. Lagrange's theorem is why a group's order is such a strong constraint — knowing ∣G∣|G| alone already rules out most possible subgroup sizes.

Example
Index from a dihedral group
1234
A single reflection of the square generates a subgroup of order 2.

In D4D_4, the symmetries of a square, ∣D4∣=8|D_4| = 8 (Topic 2). Let H=⟨s⟩H = \langle s\rangle for one reflection ss; since s2=es^2=e and s≠es \ne e, ∣H∣=2|H|=2. By Lagrange, [D4:H]=8/2=4[D_4:H] = 8/2 = 4: the reflection's cosets split the 88 symmetries into exactly 44 pairs.

Example
Ruling out a subgroup size

Could a group of order 1010 have a subgroup of order 44? Lagrange demands 4∣104 \mid 10, and it does not, since 10/410/4 is not an integer — so the answer is no, with no search of the group required. The same check rules out a subgroup of order 33, while one of order 55 is at least not ruled out.

Example
Listing the possible subgroup sizes

What are the possible orders of a subgroup of a group of order 3030? By Lagrange, only divisors of 3030 are possible: 1,2,3,5,6,10,15,301, 2, 3, 5, 6, 10, 15, 30. Lagrange does not promise that all eight actually occur — only that nothing else can.

Side note
Where it goes wrong

The converse of Lagrange's theorem is false: d∣∣G∣d \mid |G| does not mean GG has a subgroup of order dd. The standard counterexample is A4A_4, the even permutations of 44 letters, with ∣A4∣=12|A_4|=12; checking every 66-element subset shows none of them is a subgroup, so A4A_4 has no subgroup of order 66, even though 6∣126 \mid 12.

Try it
Try it: applying Lagrange

Can a group of order 2020 have a subgroup of order 77?

Show the answer

No: Lagrange requires the subgroup's order to divide ∣G∣=20|G|=20, and 7∤207 \nmid 20, since 20/720/7 is not an integer. The answer is no\mathbf{\text{no}}.

Consequences of Lagrange's Theorem

Concept
Three corollaries

For a finite group GG and g∈Gg \in G: (1) the order of gg divides ∣G∣|G|, since ⟨g⟩\langle g\rangle is a subgroup of order ord⁡(g)\operatorname{ord}(g); (2) g∣G∣=eg^{|G|} = e; (3) if ∣G∣=p|G|=p is prime, GG is cyclic, generated by any g≠eg \ne e.

All three follow from Lagrange applied to the cyclic subgroup ⟨g⟩\langle g\rangle, whose order is exactly ord⁡(g)\operatorname{ord}(g) (Topic 3). For (2), write ∣G∣=ord⁡(g)⋅k|G| = \operatorname{ord}(g)\cdot k and raise gg to that power in blocks of size ord⁡(g)\operatorname{ord}(g), each of which collapses to ee. For (3), a subgroup of a prime-order group can only have order 11 or pp by Lagrange, so ⟨g⟩\langle g\rangle for any g≠eg \ne e — which already has more than one element — must be all of GG. This is the first theorem that pins a group down completely from its size alone.

Example
Order of a permutation divides ∣S5∣|S_5|
1122334455
The permutation (123)(45): a 3-cycle on 1,2,3 and a swap of 4,5.

Take g=(123)(45)∈S5g=(123)(45) \in S_5, where ∣S5∣=120|S_5| = 120 (Topic 4). Its cycle type is 3+23+2, so ord⁡(g)=lcm⁡(3,2)=6\operatorname{ord}(g) = \operatorname{lcm}(3,2) = 6. Indeed 6∣1206 \mid 120, exactly as corollary (1) demands.

Example
All the subgroups of Z12\mathbb Z_{12}

Z12\mathbb Z_{12} is cyclic, so — unlike a general group — it has exactly one subgroup for each divisor of 1212. The divisors are 1,2,3,4,6,121,2,3,4,6,12, giving the subgroups {0}\{0\}, ⟨6⟩={0,6}\langle 6\rangle=\{0,6\}, ⟨4⟩={0,4,8}\langle 4\rangle=\{0,4,8\}, ⟨3⟩={0,3,6,9}\langle 3\rangle=\{0,3,6,9\}, ⟨2⟩={0,2,4,6,8,10}\langle 2\rangle=\{0,2,4,6,8,10\}, and Z12\mathbb Z_{12} itself: 66 subgroups in all.

Example
Is U(35)U(35) cyclic?

∣U(35)∣=φ(35)=24|U(35)| = \varphi(35) = 24, so a generator would need order 2424. Lagrange rules this out without computing a single order. Take any aa coprime to 3535. Modulo 55, aa lies in U(5)U(5), a group of order 44, so corollary (2) gives a4≡1a^4 \equiv 1 and hence a12=(a4)3≡1(mod5)a^{12} = (a^4)^3 \equiv 1 \pmod 5. Modulo 77, aa lies in U(7)U(7), of order 66, so a6≡1a^6 \equiv 1 and a12≡1(mod7)a^{12} \equiv 1 \pmod 7. Both 55 and 77 divide a12−1a^{12}-1, so 3535 does: a12≡1(mod35)a^{12} \equiv 1 \pmod{35} for every a∈U(35)a \in U(35). Every element's order therefore divides 1212 and never reaches 2424, so U(35)U(35) is not cyclic. Check with a=2a=2: 212=4096=35⋅117+12^{12} = 4096 = 35\cdot117+1.

Side note
Where it goes wrong

Corollary (1) bounds an element's order; it does not guarantee an element of every such order exists. In U(8)={1,3,5,7}U(8) = \{1,3,5,7\}, ∣U(8)∣=4|U(8)|=4, but 3,5,73,5,7 all have order 22 (e.g. 32=9≡1(mod8)3^2=9\equiv1\pmod8) and only 11 has order 11 — no element of order 44 at all, so U(8)U(8) is not cyclic despite having 44 elements.

Try it
Try it: subgroups of Z18\mathbb Z_{18}

How many subgroups does Z18\mathbb Z_{18} have, and could one of them have order 55?

Show the answer

The divisors of 1818 are 1,2,3,6,9,181,2,3,6,9,18, so, since cyclic groups realize every divisor exactly once, Z18\mathbb Z_{18} has exactly 6\mathbf{6} subgroups. Since 55 is not among the divisors, no subgroup of order 55 exists.

Fermat and Euler from Lagrange

Concept
Euler's theorem and Fermat's little theorem

For n≥1n \ge 1 and gcd⁡(a,n)=1\gcd(a,n)=1: aφ(n)≡1(modn)a^{\varphi(n)} \equiv 1 \pmod n, where φ(n)=∣U(n)∣\varphi(n) = |U(n)| is Euler's totient. When n=pn=p is prime this is Fermat's little theorem: ap−1≡1(modp)a^{p-1}\equiv1\pmod p whenever p∤ap \nmid a.

An integer aa coprime to nn is exactly an element of the group U(n)U(n) (Topic 2), which has order φ(n)\varphi(n). Corollary (2) of Lagrange's theorem (Section 3) says every element of a finite group, raised to the group's own order, gives the identity — applied to U(n)U(n) that is precisely aφ(n)≡1(modn)a^{\varphi(n)}\equiv1\pmod n. Fermat's version is the special case n=pn=p: every nonzero residue mod a prime is a unit, and φ(p)=p−1\varphi(p)=p-1. So both theorems are Lagrange in disguise, not separate facts to memorize.

Example
Euler's theorem at n=15n=15

φ(15)=∣U(15)∣=8\varphi(15)=|U(15)|=8. Take a=7a=7, coprime to 1515: Euler's theorem predicts 78≡1(mod15)7^8 \equiv 1 \pmod{15}. Direct computation confirms 78=5764801=15⋅384320+17^8 = 5764801 = 15\cdot384320+1.

Example
Fermat at p=13p=13

Take p=13p=13, a=5a=5. Fermat predicts 512≡1(mod13)5^{12}\equiv1\pmod{13}. Checking: 512=244140625=13⋅18780048+15^{12}=244140625=13\cdot18780048+1.

Example
Reducing a huge exponent

Find 7100 mod 137^{100} \bmod 13. Since 1313 is prime and 13∤713 \nmid 7, ord⁡(7)\operatorname{ord}(7) divides 1212, so 712≡1(mod13)7^{12}\equiv1\pmod{13} and only the exponent mod 1212 matters: 100=8⋅12+4100 = 8\cdot12+4, so 7100≡74(mod13)7^{100}\equiv7^4\pmod{13}. Now 72=49≡107^2=49\equiv10, so 74≡102=100≡9(mod13)7^4\equiv10^2=100\equiv9\pmod{13}.

Side note
Where it goes wrong

Both theorems need the coprimality hypothesis. Without it they fail outright: taking a=pa=p itself, pp−1≡0(modp)p^{p-1}\equiv0\pmod p, not 11 — e.g. 54=625≡0(mod5)5^4=625\equiv0\pmod5, since 5∣55\mid5 makes 55 not a unit mod 55 at all. 'an−1≡1(modn)a^{n-1}\equiv1\pmod n for all aa' is only safe once gcd⁡(a,n)=1\gcd(a,n)=1 has been checked.

Try it
Try it: Fermat to reduce an exponent

Find 31000 mod 73^{1000} \bmod 7.

Show the answer

Here ord⁡(3)\operatorname{ord}(3) divides p−1=6p-1=6, so only the exponent mod 66 matters: 1000=166⋅6+41000=166\cdot6+4, so 31000≡34(mod7)3^{1000}\equiv3^4\pmod7. Then 32=9≡23^2=9\equiv2, so 34≡22=4(mod7)3^4\equiv2^2=\mathbf{4}\pmod7.

Why It Works

Define a∼ba\sim b iff a−1b∈Ha^{-1}b\in H. Reflexive: a−1a=e∈Ha^{-1}a=e\in H. Symmetric: if a−1b∈Ha^{-1}b\in H then its inverse (a−1b)−1=b−1a∈H(a^{-1}b)^{-1}=b^{-1}a\in H. Transitive: if a−1b∈Ha^{-1}b\in H and b−1c∈Hb^{-1}c\in H then their product a−1c∈Ha^{-1}c\in H. So ∼\sim is an equivalence relation, and the class containing gg is {x:g−1x∈H}={x:x=gh for some h∈H}=gH\{x : g^{-1}x\in H\} = \{x : x = gh \text{ for some } h\in H\} = gH. Equivalence classes always partition a set, so the left cosets of HH partition GG. Each coset has size ∣H∣|H|: the map h↦ghh\mapsto gh from HH to gHgH is injective (if gh1=gh2gh_1=gh_2 then cancelling gg gives h1=h2h_1=h_2) and onto gHgH by definition, so it is a bijection.

By the previous proof, GG is a disjoint union of left cosets of HH, each of size ∣H∣|H|. If there are mm such cosets, then ∣G∣=m⋅∣H∣|G| = m\cdot|H|, so ∣H∣|H| divides ∣G∣|G|, and m=[G:H]=∣G∣/∣H∣m=[G:H]=|G|/|H|.

The cyclic subgroup ⟨g⟩={e,g,g2,…}\langle g\rangle = \{e,g,g^2,\ldots\} has exactly ord⁡(g)\operatorname{ord}(g) distinct elements (Topic 3), so it is a subgroup of order ord⁡(g)\operatorname{ord}(g). By Lagrange, ord⁡(g)\operatorname{ord}(g) divides ∣G∣|G|; write ∣G∣=ord⁡(g)⋅k|G|=\operatorname{ord}(g)\cdot k. Then g∣G∣=(gord⁡(g))k=ek=eg^{|G|} = (g^{\operatorname{ord}(g)})^k = e^k = e.

Let G=⟨g⟩G=\langle g\rangle have order nn, and let d∣nd \mid n. The element gn/dg^{n/d} has order exactly dd, since (gn/d)k=e(g^{n/d})^k=e iff n∣(n/d)kn \mid (n/d)k iff d∣kd \mid k — so ⟨gn/d⟩\langle g^{n/d}\rangle is a subgroup of order dd. For uniqueness: every element of order dividing dd satisfies xd=ex^d=e, and writing x=gkx=g^k this means n∣dkn \mid dk, i.e. kk is a multiple of n/dn/d — exactly the powers of gn/dg^{n/d}. So the full set of solutions to xd=ex^d=e in GG is ⟨gn/d⟩\langle g^{n/d}\rangle, which has exactly dd elements. Any subgroup HH of order dd consists entirely of such solutions, since every element of HH has order dividing dd by Lagrange applied inside HH; with only dd solutions available, HH must be all of them, so H=⟨gn/d⟩H=\langle g^{n/d}\rangle.

If gcd⁡(a,n)=1\gcd(a,n)=1, then a mod na \bmod n is an element of U(n)U(n), the group of units mod nn under multiplication, which has order φ(n)\varphi(n). Applying g∣G∣=eg^{|G|}=e (the previous corollary) to G=U(n)G=U(n) and g=ag=a gives aφ(n)≡1(modn)a^{\varphi(n)}\equiv1\pmod n, which is Euler's theorem. Setting n=pn=p prime, every aa with p∤ap\nmid a is a unit and φ(p)=p−1\varphi(p)=p-1, giving Fermat's little theorem as the special case.