September 21st, 2025
Helpful topic to teach yourself lattice-based crypto: cosets
Before we even begin to talk about the fun stuff, it's time to talk about one more topic: cosets. What they are is what will be discussed further in this article.
I've talked about subgroups. The thing about studying subgroups, is that it may feel like we're dismissing all other subsets. The next logical question would be, why not study the rest of the sets?
And this is where cosets comes along. Although cosets don't cover every subsets of a group, but, nevertheless, it still broadens the scope further than what subgroups ever did, and they can be used to build powerful primitives. Primitives that are used in many cryptographic studies.
So what is a coset?
A coset is what you get when you take a subgroup of a group and "shift" it by some element of .
Formally, if is a group and is a subgroup, as well as some operator , then cosets take on any of the following forms
- left coset of by :
- right coset of by :
The key properties of cosets are:
- The set of all left cosets of forms a partition of , and right cosets of forms a partition of . Meaning that every element of belong to exactly one left coset and one right coset of
- Every element of belongs to exactly one left coset and right coset of any subgroup .
- All cosets of have the same number of elements as itself.
- Cosets are either equal or disjoint
Example with Integers
Additions in integers forms a group. We can define a subgroup of as being nothing but multiples of a particular integer, using (where ), e.g. .
Using additions as the "shift" operator, then the possible left cosets of gives:
These cosets partition into 5 distinct sets, each containing all integers that give the same remainder when divided by 5. This is a fundamental concept that leads to modular arithmetic.
This is a powerful idea to be leveraged when discussing quotient groups.