Skip to content

Introduction to Rings

In this lesson you’ll learn the ring axioms, why multiplication is deliberately given less structure than addition, the difference between a ring and a ring with unity, and how the familiar number systems fit into the picture.

A group has one operation. But the number systems you actually use have two, and the interesting behaviour lies in how they interact.

A ring is a set RR with two operations, ++ and ×\times, satisfying:

For addition - (R,+)(R, +) is an abelian group:

  1. Closed under ++
  2. Associative
  3. Has an identity 00
  4. Every aa has an additive inverse a-a
  5. Commutative: a+b=b+aa + b = b + a

For multiplication:

  1. Closed under ×\times
  2. Associative

Connecting them - distributivity:

a(b+c)=ab+ac,(a+b)c=ac+bca(b+c) = ab + ac, \qquad (a+b)c = ac + bc

That’s it. Notice the asymmetry: addition is a full abelian group; multiplication gets only closure and associativity. No commutativity, no identity, no inverses required.

This asymmetry is not laziness, it’s realism. Matrix multiplication doesn’t commute. Not every integer has a reciprocal. Requiring more would exclude the examples we care about most.

Because so much is optional, ring theory has a vocabulary of qualifiers:

  • Commutative ring - ab=baab = ba always.
  • Ring with unity (or with identity) - there is a 11 with 1a=a1=a1a = a1 = a.
  • Integral domain - commutative, with unity, and no zero divisors.
  • Field - a commutative ring with unity where every nonzero element is invertible.

Terminology warning: some books define “ring” to include a unity and use “rng” for the version without. This site does not require unity, so 2Z2\mathbb{Z} counts as a ring.

An element uRu \in R is a unit if it has a multiplicative inverse in RR. The units form a group under multiplication, written RR^* or U(R)U(R).

  • In Z\mathbb{Z}, the units are {1,1}\{1, -1\}. Only two.
  • In Q\mathbb{Q}, every nonzero element is a unit.
  • In Zn\mathbb{Z}_n, the units are exactly the residues coprime to nn - the group U(n)U(n) from earlier lessons, now revealed as the unit group of a ring.

A field is precisely a commutative ring with unity in which every nonzero element is a unit. That’s the shortest correct definition of a field.

Some facts hold in every ring, and each is a short exercise in using distributivity.

0a=a0=00a = a0 = 0. Not an axiom, a theorem:

0a=(0+0)a=0a+0a0a = (0+0)a = 0a + 0a

Subtracting 0a0a from both sides (legal, since addition is a group) gives 0=0a0 = 0a.

(a)b=(ab)(-a)b = -(ab). Because ab+(a)b=(a+(a))b=0b=0ab + (-a)b = (a + (-a))b = 0b = 0, so (a)b(-a)b is the additive inverse of abab.

(a)(b)=ab(-a)(-b) = ab. Apply the previous rule twice. This is the real answer to “why does a negative times a negative give a positive”: it’s forced by distributivity, not a convention someone chose.

A nonzero aa is a zero divisor if there is a nonzero bb with ab=0ab = 0.

In Z\mathbb{Z} this never happens: a product of nonzero integers is nonzero. In Z6\mathbb{Z}_6 it does: 23=602 \cdot 3 = 6 \equiv 0, so 2 and 3 are zero divisors.

Zero divisors break something you rely on constantly: cancellation. In Z6\mathbb{Z}_6, from 2x=2y2x = 2y you cannot conclude x=yx = y, since 21=22 \cdot 1 = 2 and 24=822 \cdot 4 = 8 \equiv 2. Solving equations in a ring with zero divisors requires care, and the next lesson is about the rings where this problem is absent.

  • Z\mathbb{Z} - commutative, unity, no zero divisors. An integral domain, not a field.
  • Zn\mathbb{Z}_n - commutative with unity. A field exactly when nn is prime.
  • Q,R,C\mathbb{Q}, \mathbb{R}, \mathbb{C} - fields.
  • M2(R)M_2(\mathbb{R}), the 2×22\times 2 real matrices - unity (the identity matrix), not commutative, and full of zero divisors.
  • R[x]\mathbb{R}[x], real polynomials - commutative with unity, an integral domain, not a field (there’s no polynomial inverse for xx).
  • 2Z2\mathbb{Z}, the even integers - commutative, no zero divisors, but no unity, since 11 is odd.

Example 1: Is 2Z2\mathbb{Z} a ring?

Solution. Addition: the even integers form an abelian group under ++

Multiplication: even times even is even ✓, and associativity is inherited ✓

Distributivity: inherited from Z\mathbb{Z}

Yes, a ring. But it has no unity: we’d need an even uu with ua=aua = a for all even aa, and u=1u = 1 is the only candidate in Z\mathbb{Z}, which is odd.

So 2Z2\mathbb{Z} is a commutative ring without unity, and it shows that unity is a genuine extra condition.

Example 2: Find the zero divisors in Z12\mathbb{Z}_{12}.

Solution. Look for nonzero aa with ab0(mod12)ab \equiv 0 \pmod{12} for some nonzero bb.

26=120,34=120,83=240,94=360,106=6002 \cdot 6 = 12 \equiv 0, \quad 3 \cdot 4 = 12 \equiv 0, \quad 8 \cdot 3 = 24 \equiv 0, \quad 9 \cdot 4 = 36 \equiv 0, \quad 10 \cdot 6 = 60 \equiv 0

Zero divisors: {2,3,4,6,8,9,10}\{2, 3, 4, 6, 8, 9, 10\}.

Non-zero-divisors: {1,5,7,11}\{1, 5, 7, 11\} - exactly U(12)U(12).

The pattern: in Zn\mathbb{Z}_n, an element is a unit when gcd(a,n)=1\gcd(a,n) = 1 and a zero divisor otherwise. Every nonzero element is one or the other, never both.

Example 3: Zero divisors among matrices.

Solution. Take

A=(1000),B=(0001)A = \begin{pmatrix} 1 & 0 \\ 0 & 0 \end{pmatrix}, \qquad B = \begin{pmatrix} 0 & 0 \\ 0 & 1 \end{pmatrix}

Both nonzero, but

AB=(0000)AB = \begin{pmatrix} 0 & 0 \\ 0 & 0 \end{pmatrix}

Both are zero divisors. In fact a matrix is a zero divisor exactly when its determinant is 0, which is the same as failing to be invertible. In Mn(R)M_n(\mathbb{R}) every element is either a unit or a zero divisor, just as in Zn\mathbb{Z}_n.

Example 4: Prove (a)(b)=ab(-a)(-b) = ab in any ring.

Solution. First, (a)b=(ab)(-a)b = -(ab):

ab+(a)b=(a+(a))b=0b=0ab + (-a)b = (a + (-a))b = 0 \cdot b = 0

so (a)b(-a)b is the additive inverse of abab. The same argument on the right gives a(b)=(ab)a(-b) = -(ab).

Now apply it twice:

(a)(b)=(a(b))=((ab))=ab(-a)(-b) = -\big(a(-b)\big) = -\big(-(ab)\big) = ab

using that additive inverses undo themselves in the group (R,+)(R,+). ∎

Note what the proof used: distributivity, the additive group, and the theorem 0b=00b = 0. Nothing about numbers.

Example 5: A ring where x2=xx^2 = x for everything.

Solution. Take R=Z2={0,1}R = \mathbb{Z}_2 = \{0, 1\}. Then 02=00^2 = 0 and 12=11^2 = 1.

More interestingly, the set of subsets of a fixed set, with symmetric difference as ++ and intersection as ×\times, is a Boolean ring, and there AA=AA \cap A = A for every AA.

Boolean rings are the algebra of logic circuits, which is why simplifying a circuit and simplifying a ring expression are the same activity.

Example 6: Is Z5\mathbb{Z}_5 a field?

Solution. Commutative with unity ✓. Check each nonzero element for an inverse:

11=1,23=61,32=1,44=1611 \cdot 1 = 1, \quad 2 \cdot 3 = 6 \equiv 1, \quad 3 \cdot 2 = 1, \quad 4 \cdot 4 = 16 \equiv 1

All four have inverses. Yes, a field.

Compare Z6\mathbb{Z}_6: the element 2 has no inverse, because 2b2b is always even and therefore never 1(mod6)\equiv 1 \pmod 6. So Z6\mathbb{Z}_6 is not a field.

Zn\mathbb{Z}_n is a field exactly when nn is prime, which is the subject of the next lesson.

Computer arithmetic. Fixed-width integer types are the ring Z232\mathbb{Z}_{2^{32}} or Z264\mathbb{Z}_{2^{64}}. This is why unsigned overflow wraps rather than erring, and why Z232\mathbb{Z}_{2^{32}} has zero divisors: 216×216=02^{16} \times 2^{16} = 0 in 32-bit arithmetic. Real overflow bugs come from expecting integer-like behaviour from a ring that has zero divisors.

Cryptography. RSA operates in the ring Zn\mathbb{Z}_n for n=pqn = pq. Its zero divisors are the multiples of pp and qq, so stumbling onto one would reveal the factorization. The scheme lives entirely inside the unit group U(n)U(n).

Error-correcting codes. Reed–Solomon codes, used in QR codes, CDs and deep-space communication, work in polynomial rings over finite fields. The ring structure is what makes encoding and decoding into polynomial arithmetic instead of table lookup.

Boolean algebra and digital logic. Circuit design is computation in a Boolean ring, and logic minimization is algebraic simplification. Every chip layout tool rests on this.

Computer algebra systems. Mathematica, SageMath and SymPy are organized around ring types. Whether a system can factor, divide, or solve depends on which ring axioms your coefficients satisfy, so the type hierarchy in the software mirrors the ladder in this lesson.

Image and signal processing. Convolution makes the set of signals into a ring, and filter design is ring arithmetic. The reason the Fourier transform simplifies filtering is that it is a ring homomorphism turning convolution into multiplication.

In a ring, which operation is required to form an abelian group?
Which of these is NOT required by the ring axioms?
Which elements of ℤ₁₂ are zero divisors?
Why is 2ℤ, the even integers, a ring without unity?
What is a unit in a ring?
Why does 0a = 0 hold in every ring?