We will start by the definition of a ring.
Definition 1: A ring is a non empty set R together with two binary compositions defined by + and ., and satisfying the following properties hold for any :
- There exists an element denoted by such that . 0 is called the additive identity or the zero element in R.
- For each , there exists an element such that . b is called additive inverse or negative of a and is written as b=-a so that a+(-a)=0.
- (Left distributive law.)
- (Right distributive law.)
We denote a ring by (R,+,.). When the context is clear we just talk about a ring R and assume that the operations + and . are implicit. We will also drop the . in the operation a.b and just say ab.
The first 5 axioms of a ring just mean that (R,+) is an abelian group. The next two mean that (R,.) is a semi group. A ring is called commutative if . A ring is called boolean if . A ring R is called a ring with a unit element or unity or identity if an element such that . Let R be a ring with unit element e. An element is called invertible, if there exists an element such that . If n is a positive integer and a an element of a ring R then we define and .
One of the most important rings is the ring of integers with usual addition and multiplication playing the roles of + and . respectively. It is a commutative ring with identity as 1. The set of even numbers is an example of a ring without identity. Like , the sets of rational numbers , of real numbers and of complex numbers are also rings with identity. However is not a ring.
The ring of Gaussian integers is given by the set where usual addition and multiplication of complex numbers are the operations. Here i stands (0,1) as is usual in the complex plane.
The set of all n by n matrices with real entries is an example of a non commutative ring with identity, under the usual addition and multiplication of matrices.
The ring of integers modulo n
We now digress slightly to discuss a special kind of an equivalence relation which gives rise to an important class of finite rings.
Let n be a positive integer. Two integers a and b are said to be congruent modulo n, if their difference a − b is an integer multiple of n. If this is the case, it is expressed as:
The above mathematical statement is read: "a is congruent to b modulo n".
because 38 − 14 = 24, which is a multiple of 12. For positive n and non-negative a and b, congruence of a and b can also be thought of as asserting that these two numbers have the same remainder after dividing by the modulus n. So,
because both numbers, when divided by 12, have the same remainder (2). Equivalently, the fractional parts of doing a full division of each of the numbers by 12 are the same: .1666... (38/12 = 3.166..., 2/12 = .1666...). From the prior definition we also see that their difference, a - b = 36, is a whole number (integer) multiple of 12 ( n = 12, 36/12 = 3).
The same rule holds for negative values of a:
The properties that make this relation a congruence relation (respecting addition, subtraction, and multiplication) are the following.
If and , then:
Like any congruence relation, congruence modulo n is an equivalence relation, and the equivalence class of the integer a, denoted by , is the set . This set, consisting of the integers congruent to a modulo n, is called the congruence class or residue class of a modulo n. Another notation for this congruence class, which requires that in the context the modulus is known, is .
The set of congruence classes modulo n is denoted as (or, alternatively, or ) and defined by:
When n ≠ 0, has n elements, and can be written as:
We can define addition, subtraction, and multiplication on by the following rules:
The verification that this is a proper definition uses the properties given before.
In this way, becomes a commutative ring. For example, in the ring , we have
as in the arithmetic for the 24-hour clock.