Inside a group there may be smaller groups. Some groups are built entirely from the powers of a single element.
Subgroups
A non-empty subset H of a group G is a subgroup of G, written H ≤ G, if H is itself a group under the same operation. Every group G has the two trivial subgroups {e} and G itself. The even integers 2Z form a subgroup of (Z, +). To test a subset, we need not check every axiom. The two-step test: H is a subgroup if (1) a b ∈ H for all a, b ∈ H, and (2) a⁻¹ ∈ H for all a ∈ H. The one-step test: H is a subgroup if a b⁻¹ ∈ H for all a, b ∈ H. For a finite subset, closure alone is enough. Lagrange's theorem states that the order of a subgroup of a finite group divides the order of the group. A group of order 6 can have subgroups only of orders 1, 2, 3 and 6.
Definition: Subgroup. A non-empty subset of a group that is itself a group under the same operation.
Order of an Element
The order of an element a, written o(a), is the smallest positive integer n such that aⁿ = e, where aⁿ means a a … * a, n times (or na in additive notation). If no such n exists, a has infinite order. In (Z6, +6), the element 2 has order 3, since 2 + 2 + 2 = 6 ≡ 0. The identity always has order 1. By Lagrange's theorem, in a finite group the order of each element divides the order of the group.
Cyclic Groups
A group G is cyclic if there is an element g ∈ G such that every element of G is a power of g, that is, G = {gⁿ : n ∈ Z}. We write G = ⟨g⟩, and g is called a generator. (Z, +) is cyclic with generator 1 (and −1). (Zn, +n) is cyclic with generator 1. In Zn, an element k is a generator exactly when gcd(k, n) = 1, so the number of generators is φ(n), Euler's function. Every cyclic group is abelian, and every subgroup of a cyclic group is cyclic. A group of prime order is always cyclic. The multiplicative group of integers modulo a prime is cyclic, a fact used in Diffie-Hellman key exchange and other cryptographic methods.
Table 2.4: Order and generators in Z6
| Element | Multiples mod 6 | Order | Generator? |
|---|---|---|---|
| 1 | 1, 2, 3, 4, 5, 0 | 6 | Yes |
| 2 | 2, 4, 0 | 3 | No |
| 3 | 3, 0 | 2 | No |
| 5 | 5, 4, 3, 2, 1, 0 | 6 | Yes |
Example 2.4: Finding generators
Problem: Find all generators of (Z8, +8) and the order of each element.
Solution:
- k generates Z8 when gcd(k, 8) = 1, so the generators are 1, 3, 5 and 7.
- The order of k is 8 / gcd(k, 8): o(0) = 1, o(1) = 8, o(2) = 4, o(3) = 8, o(4) = 2, o(5) = 8, o(6) = 4, o(7) = 8.
- Each order divides 8, as Lagrange's theorem says.
Result: Z8 is cyclic with generators 1, 3, 5, 7.
from math import gcd
n = 8
orders = {k: n // gcd(k, n) for k in range(n)}
print(orders)
print("generators:", [k for k in range(n) if gcd(k, n) == 1])
Output
{0: 1, 1: 8, 2: 4, 3: 8, 4: 2, 5: 8, 6: 4, 7: 8}
generators: [1, 3, 5, 7]
Common mistakes
- Forgetting to check that the inverse of each element lies in the subset.
- Thinking that every element of a cyclic group is a generator.
- Using Lagrange's theorem backwards: a divisor of |G| need not be the order of a subgroup in every group.
Key takeaways
- A subgroup is a subset that is a group under the same operation.
- Two-step test: closure and inverses. One-step test: a * b⁻¹ ∈ H.
- Lagrange: the order of a subgroup divides the order of the group.
- A cyclic group is generated by one element, and k generates Zn when gcd(k, n) = 1.
Practice questions
- State Lagrange's theorem.
- What is a cyclic group?
- What is the order of 4 in (Z6, +6)?
Answers to the practice questions
- In a finite group, the order of every subgroup divides the order of the group.
- A group in which every element is a power of a single element, the generator.
- 3, since 4 + 4 + 4 = 12 ≡ 0 (mod 6).
Sources
- Official BCA syllabus Mathematics Foundations to Computer Science II, course code 25BCA402DS01, Unit II
