<<

INTRODUCTION TO ABSTRACT

G. JANELIDZE Department of and Applied Mathematics University of Cape Town Rondebosch 7701, Cape Town, South Africa

Last updated on 20 September 2013

This is an elementary course aiming to introduce very first concepts of for third year students interested in pure mathematics. It is divided into the following (two chapters and) sections:

I. First algebraic and related structures

1. Algebraic operations...... 2 2. Magmas and unitary magmas...... 3 3. ...... 4 4. ...... 5 5. operators...... 5 6. Equivalence relations...... 7 7. Order relations...... 8 8. Categories...... 9 9. ...... 11 10. Initial and terminal objects...... 12 11. , , ...... 13 12. Subalgebras...... 15 13. Products...... 16 14. Quotient algebras...... 16 15. Canonical factorization of homomorphisms...... 17 16. Classical algebraic structures...... 18 17. Quotient groups, rings, and modules...... 20

II. Lattices, , number systems, and foundation of

1. Commutativity...... 25 2. ...... 26 3. Lattices...... 29 4. Distributivity and complements...... 31 5. Complete lattices...... 33 6. Boolean algebras...... 34 7. Semirings and semimodules...... 37 8. The ℕ of natural numbers...... 38 9. Number systems, ℤ, ℚ, ℝ, and ℂ as rings, and their modules...40 10. Pointed categories...... 46 11. Products and ...... 47 12. Direct sums...... 51 13. Free algebras and free semimodules...... 52 14. Vector spaces...... 55

We shall refer to these sections as follows: say, “Section 10” means “Section 10 in this chapter”, while “Section I.10” means “Section 10 in Chapter I”, when we refer to it in Chapter II.

I am grateful to Dr. Amartya Goswami for a number of misprint corrections.

1 I. FIRST ALGEBRAIC AND RELATED STRUCTURES

1. Algebraic operations

For a n and a A, the set of all maps from {1,…,n} to A will be denoted by An; this includes the case n = 0, where {1,…,n} becomes the and therefore An becomes a one-element set. For n = 1, the set An will be identified with A, and for n = 2, 3,…, the elements of An will be written as n-member (a1,…,an) of elements in A.

Definition 1.1. For n = 0, 1, 2,…, an n-ary operation on a set A is a map from An to A. We will also use special terms for small n’s:

0-ary nullary 1-ary unary 2-ary binary 3-ary ternary

Remarks and Conventions 1.2. (a) Since to give a nullary operation on A is the same as to pick up an element in A, we will simply identify them; accordingly the nullary operations are sometimes called constants.

(b) If  is an n-ary operation with n = 2, 3,…, we will write (a1,…,an) instead of ((a1,…,an)). Furthermore, for n = 2, instead of (a1,a2) we usually write a1a2, or simply a1a2 – especially when we think of  as a kind of multiplication. 

Binary operations play an especially important role. When the ground set A has a small number of elements, it is convenient to define binary operations on it with tables, such as:

a b a a a b a b where A = {a,b} and aa = ab = ba = a, bb = b, or

a b a b b b b b where A = {a,b} again, but now aa = ab = ba = bb = b. That is, when A has n elements, the table contains n  1 rows and n  1 columns with the following entries in their cells:

 the first cell is blank, and the rest of the first row lists the elements of A in any order;  the rest of the first column lists the elements of A (preferably) in the same order;

2  for i and j both greater than 1, the cell on the intersection of i-row and j-column has the element ab in it – where a stays in the i-th cell of the first column and b stays in the j-th cell of the first row.

Definition 1.3. Let  be a on a set A, and let us write (a,b) = ab, as above. The operation  is said to be

(a) associative, if a(bc) = (ab)c for all a, b, c in A;

(b) commutative, if ab = ba for all a, b in A;

(c) idempotent, if aa = a for all a in A. 

2. Magmas and unitary magmas

Definition 2.1. A magma1 is a pair (M,m), where M is a set and m a binary operation on M. 

Convention 2.2. Whenever only one (M,m) is considered, we will always write m(a,b) = ab and often write just M instead of (M,m). 

Definition 2.3. An element e in a magma M is said to be:

(a) an idempotent, if ee = e;

(b) a left (or a left unit), if ea = a for every a in M;

(c) a right identity (or a right unit), if ae = a for every a in M;

(d) an identity2 (or a unit), if it is a left and a right identity at the same time, i.e. if ea = a = ae for every a in M. 

Theorem 2.3. In an arbitrary magma:

(a) every left identity and every right identity is an idempotent;

(b) if e is a left identity and e' is a right identity, then e = e'.

Proof. (a) is trivial. (b): e = ee' = e'. 

Remark 2.4. For an arbitrary set M one can define a binary operation on it by ab = b for all a and b in M. In the resulting magma, every element is a left identity. And of course one can do the same with the right identities by putting put ab = a. On the other hand Theorem 2.3(b) tells us that the existence of at least one left identity and at least one right identity in the same magma immediately implies that all of them are equal, yielding a unique identity. 

Definition 2.5. A unitary magma is a triple (M,e,m), where (M,m) be a magma and e its identity. 

1 In old literature magmas were sometimes called ; this has been changed in order to avoid confusions with groupoids in theory. 2 As follows from 2.3(b) below (see also Remark 2.4), we could also say “the identity”.

3 Convention 2.6. Whenever only one unitary magma (M,e,m) is considered, we will (still use Convention 2.2 and) write 1 instead of e.

Remark 2.7. As we see from Remark 2.4, it is a triviality that every unitary magma has exactly one left identity, exactly one right identity, and exactly one identity (all the same). 

3. Semigroups

Definition 3.1. A magma (M,m) is called a if m is associative. 

Theorem 3.2. If (M,m) is a semigroup, then there exists a unique of operations m1, m2, … on M such that:

(a) mn is an n-ary operation (n = 1, 2,…);

(b) m1(a) = a for every a in M;

(c) mp(a1,…,ap)mq(b1,…,bq) = mp+q(a1,…,ap,b1,…,bq) for all p = 1, 2,…; q = 1, 2,…; and a1,…, ap, b1,…, bq in M.

Proof. Existence. Let us define m1, m2, … inductively by (b) for m1 and by

mn+1(a1,…,an1) = mn(a1,…,an)an1 for m2, m3, …, i.e. for n = 1, 2,…. After this we will prove (c) by induction in q as follows:  for q = 1 we have mp(a1,…,ap)mq(b1) = mp(a1,…,ap)b1 = mp1(a1,…,ap,b) for each p;  for q > 1, using the inductive assumption and associativity, we then obtain

mp(a1,…,ap)mq(b1,…,bq) = mp(a1,…,ap)(mq1(b1,…,bq1)bq) = (mp(a1,…,ap)mq1(b1,…,bq1))bq = mpq1(a1,…,ap,b1,…,bq1)bq = mp+q(a1,…,ap,b1,…,bq), as desired.

Uniqueness. From our assumptions on the sequence m1, m2, … we obtain

mp+1(a1,…,ap1) = mp(a1,…,ap)m1(ap1) = mp(a1,…,ap)ap1 and so our inductive definition was a consequence of those assumptions. 

According to Convention 2.2, it is also convenient to avoid writing the letter m for the operations introduced in Theorem 3.2. That is, one writes

n n mn(a1,…,an) = a1…an = ai = i=1ai (3.1) i=1 and, in this notation, the formula given in 3.2(c) becomes

4 (a1…ap)(ap1…apq) = a1…apq, (3.2) or, equivalently

p pq pq (i=1ai)(i =p1ai) = i =1ai, (3.3)

n Furthermore, for a1 = … = an = a, one writes a instead of a1…an, and (3.2) becomes

apaq = apq. (3.4)

4. Monoids

Definition 4.1. A is a unitary magma (M,e,m), in which m is associative. 

In other words, a monoid is a unitary magma (M,e,m), in which (M,m), is a semigroup. Theorem 3.2 reformulates for monoids as follows:

Theorem 4.2. If (M,e,m) is a monoid, then there exists a unique sequence of operations m0, m1, … on M such that:

(a) mn is an n-ary operation (n = 0, 1,…);

(b) m1(a) = a for every a in M;

(c) mp(a1,…,ap)mq(b1,…,bq) = mp+q(a1,…,ap,b1,…,bq) for all p = 0, 1,…; q = 0, 1,…; and a1,…, ap, b1,…, bq in M. 

Proof. As follows from Theorem 3.2, all we need is to take care of m0. That is, given a sequence m1, m2, … as in Theorem 3.2, we need to prove that there exists a unique element m0 in M satisfying

m0m0 = m0, mp(a1,…,ap)m0 = mp(a1,…,ap), and m0mq(b1,…,bq) = mq(b1,…,bq) for all p = 1, 2,…; q = 1, 2,…; and a1,…, ap, b1,…, bq in M. This is the same as to prove that there exists a unique element m0 in M satisfying am0 = a = m0a for all a in M, i.e. the same as to prove that the magma (M,m) has a unique – which follows from the fact that (M,e,m) is a monoid (see Remark 2.7 for the uniqueness). 

According to Theorem 4.2, we will use the notation introduced in Section 3 also when one or more of the indices involved is 0. Hence

0 m0 = 1 = a for all a in M; (4.1)

Note also that (4.1) makes (3.4) valid for p = 0 and/or q = 0.

5. Closure operators

Definition 5.1. A closure operator on a set X is a unary operation c on the P(X) with:

(a) A  B  c(A)  c(B),

5

(b) A  c(A),

(c) c(c(A)) = c(A), for all A and B in P(X). For A  P(X), the set c(A) is called the closure of A; if c(A) = A, we say that A is closed. 

Theorem 5.2. For a given closure operator c on a set X and A  P(X), the following sets are (well defined and) equal:

(a) c(A);

(b) the smallest closed in X containing A;

(c) the intersection of all closed in X containing A.

Proof. Since c(A) is closed (by 5.1(c)) and since it contains A (by 5.1(b)), all we need to prove is the following implication

(C is closed and A  C)  (c(A)  C). (5.1)

But this is obvious, since: A  C implies we have c(A)  c(C) by 5.1(a), and c(C) = C when C is closed. 

Consider the map

CO(X)  PP(X) (5.2) from the set CO(X) of all closure operators on X to the set PP(X) of all subsets in P(X) sending the closure operators to the corresponding sets of closed subsets, i.e. sending a c to {A  P(X)  c(A) = A}. As follows from Theorem 5.2, the set of closed subsets “remember” the closure operator used to define them; that is, Theorem 5.2 gives:

Corollary 5.3. The map (5.2) is injective. 

After this, we are interested to know, what is the image of the map (5.2)? In other words, we are interested to know which subsets in P(X) can be described as sets of all closed subsets in X with respect to some closure operator on X ? The answer is:

Theorem 5.4. A subset C in P(X) admits a closure operator c with C = {A  P(X)  c(A) = A} if and only if it is closed under intersections, i.e. satisfies the property A  C  A  C.

Proof. “If”: For A  P(X), put c(A) = {C  C  A  C}. The map c defined in this way will obviously satisfy 5.1(a) and 5.1(b). Moreover, the required property A  C  A  C will then tell us that c(A) is always in C and so

c(A) = {C  C  c(A)  C}.

Since the right-hand side of this equality is c(c(A)), this proves 5.1(c). That is, the map c we defined is a closure operator. We will also have

6 A  C  A = {C  C  A  C}  c(A) = A, and so C = {A  P(X)  c(A) = A}.

“Only if”: We have to prove that if c is a closure operator on X, then the set C = {A  P(X)  c(A) = A} has the property A  C  A  C. That is, we have to prove that if a subset A in P(X) has c(A) = A for all A in A, then c(A) = A. And since c is a closure operator, proving c(A) = A of course means just proving c(A)  A. For every A in A, since A  A, we have c(A)  c(A) = A, and so c(A)  A, as desired. 

Putting Corollary 5.3 and Theorem 5.4 together, we obtain:

Conclusion 5.5. The map (5.2) induces a between the set of all closure operators on X, and the set of all subsets C in P(X) that are closed under intersections. 

6. Equivalence relations

For a E on a set X and elements x and y in X, we might write xEy instead of (x,y)  E.

Definition 6.1. A binary relation E on a set X is said to be an if for all x, y, z in X we have:

(a) xEx (reflexivity);

(b) xEy  yEx (symmetry);

(c) xEy & yEz  xEz (transitivity).

In this situation, for any x in X, the set {y  X xEy} = {y  X  yEx} is called the equivalence of x, and we will denote it by [x]E, or simply by [x]. The set {[x]  x  X} is called the quotient set (sometimes factor set) of X by E, and it is denoted by X/E. 

The map X  X/E sending x to [x] is usually called canonical. We will use this term whenever there is no confusion with other types of canonical maps. The following theorem is obvious:

Theorem 6.2. Let E be an equivalence relation on a set X, and x and y elements in X. The following conditions are equivalent:

(a) xEy;

(b) [x] = [y];

(c) x and y have the same image under the canonical map X  X/E;

(d) [x]  [y]  . 

Remark 6.3. In the situation above, the sets of the form [x] form a partition of X, which means that they are disjoint (by 6.2(b)(d)) and their union coincides with X

7 (since x  [x] by reflexivity). Moreover, this passage from an equivalence relation to a partition obviously determines a bijection between the set of all equivalence relations on X and all partitions of X. Theorem 6.4 below is closely related to this fact. 

Theorem 6.4. The following conditions on a binary relation E on a set X are equivalent:

(a) E is an equivalent relation;

(b) there exists a map f : X  Y with xEx'  f(x) = f(x').

Proof. (a)(b): Take f to be the canonical map X  X/E and apply 6.2(a)(c).

(b)(a): Under the condition xEx'  f(x) = f(x'), the desired properties of E (see Definition 6.1) immediately follow from the similar properties of the equality relation. 

7. Order relations

Definition 7.1. A binary relation R on a set X is said to be an order relation if for all x, y, z in X we have:

(a) xRx (reflexivity);

(b) xRy & yRx  x = y (antisymmetry);

(c) xRy & yRz  xRz (transitivity).

A pair (X,R), where R is an order relation on X is called an ordered set, or simply an order. We shall also write X = (X,R) for simplicity. 

Remark 7.2. (a) In old literature the order relations are often required to be linear, that is, in the notation above, having the property

either xRy or yRx holds for all x and y.

When this property is included in the definition of an order relation, what we called “order” would be called “partial order”. Accordingly, ordered sets are sometimes called posets, where “po” is an abbreviation of “partial order”.

(b) When only one fixed order relation R is considered, it is usual to write  instead of R and x  y (or y  x) instead of xRy. If so, then x < y (or y > x) means (x  y)&(x  y). This so-called strict order relation < is irreflexive (i.e. there is no x with x < x), transitive, and has the property that x < y and y < x exclude each other. Conversely, every binary relation S on a set X satisfying these three properties is the strict order determined by a unique order, namely by S{(x,x)  x  X}.

(c) Removing antisymmetry from Definition 7.1, we obtain the definition of a ; that is, both equivalence and order relations are special cases of a preorder relation. One also considers (X,), and repeat various constructions and arguments used for orders, sometimes with suitable modifications of course. 

Definition 7.3. Let (X,) be an ordered set. An element x in X is said to be:

8 (a) smallest, if x  y for all y in X;

(b) largest, if y  x for all y in X;

(c) minimal, if y  x  y = x in X;

(d) maximal, if x  y  y = x in X. 

Theorem 7.4. Let (X,) be an ordered set and x an element in X. Then:

(a) if x is (the) smallest element in X, then it is a unique minimal element in X;

(b) if x is (the) largest element in X, then it is a unique maximal element in X. 

8. Categories

All maps from a fixed set S to itself (also called endomaps of S) form a monoid (S):

 for f and g in End(S), we take fg to be the composite of f and g; that is, fg is defined by fg(s) = f(g(s)), and therefore:  the 1 in End(S) is then to be defined as the identity map of S.

Now, a category is structure that has the collection of all sets3 and all maps between them as an example of it in the same way as End(S) is an example of a monoid. The formal definition is:

Definition 8.1. A category is a system C = (C0,C1,d,c,e,m), in which:

(a) C0 is a set, whose elements are called objects in C;

(b) C1 is a set, whose elements are called in C;

(c) d and c are maps from C1 to C0, called and codomain respectively; when d(f) = A and c(f) = B, we write f : A  B, or f  homC(A,B), and say that f is a from A to B;

(d) e is a map from C0 to C1, called the identity and written as e(A) = 1A; it has d(1A) = A = c(1A);

(e) m is a map from the set {(f,g)  C1C1 d(f) = c(g)} to C1, called composition, written as m(f,g) = fg, and satisfying the equalities

d(fg) = d(g), c(fg) = c(f), f1d(f) = f = 1c(f)f, f(gh) = (fg)h, whenever d(f) = c(g) and d(g) = c(h). 

3 The collection of all sets does not form a set; this problem is what one usually refers to as the problem of size. We will simply ignore it here – assuming that in our entire considerations one can always replace “the collection of all” with “a collection of sufficiently many”. A proper treatment of the problem of size would involve a considerable amount of material from mathematical logic, e.g. as much as needed to speak about models of set theory.

9 Displaying the elements of C1 as arrows (as in 8.1(c)) sometimes makes convenient to think of objects in C as points. For instance it is useful to display the first two equalities in 8.1(e) as

fg  

g f  , which actually explains where do they come from. Accordingly, when d(f) = c(g), we will say that (f,g) is a composable pair of morphisms and that fg is their composite.

Example 8.2. The category C = Sets of sets has:

(a) C0 = the class of all sets;

(b) C1 = the class of all maps between sets;

(c) f : A  B if and only if f is a map from A to B in the usual sense;

(d) fg the composite of f and g in the usual sense; therefore

(e) for a set S, the identity morphism 1S : S  S is defined as the identity map of S in the usual sense. 

Example 8.3. A monoid M determines a one-object category C as follows:

(a) C0 is any one-element set, say {M};

(b) C1 = M;

(c) since C0 has only one element, the maps d and c are uniquely determined;

(d) fg in C is defined as fg in M; therefore

4 (e) 1M : M  M is the identity element of M . 

Example 8.4. An ordered (or, more generally, a preordered) set X determines a category C as follows:

(a) C0 = X;

(b) C1 =  is the order relation itself;

(c) the maps d and c are defined by d(x,y) = x and c(x,y) = y respectively;

(d) the composition in C is therefore defined by (y,z)(x,y) =(x,z);

(e) and therefore 1x = (x,x). 

Example 8.5. Starting from a category C and a subset S in C0, we can form a new category D as follows:

(a) D0 = S;

4 Not to be confused with the identity map of the set M!

10 (b) D1 = the class of all f : A  B in C with A and B in S, and then f : A  B in D is the same as f : A  B in C;

(c) identity morphisms and composition in D are defined as in C.

A category D of this form is called a full in C. More generally, instead of taking the class of all morphisms f : A  B in C with A and B in S we could take any subclass of it closed under composition and containing all identities of objects from D; then we will drop “full” and talk about (just) a subcategory. 

Convention 8.6. (a) Since we have f(gh) = (fg)h in 8.1(e), we will write simply fgh, etc. – when appropriate (compare this with Theorem 3.2!).

(b) We will often omit the indices of identity morphisms, i.e. write 1 instead of, say, 1A.

(c) We might describe morphisms f : A  B in some particular categories in such a way that the same f could also be a morphism A'  B' for A'  A and/or B'  B – which formally contradicts to our notation since f : A  B means d(f) = A and c(f) = B. But in all such cases the original f can be replaced with, say, the triple (A,f,B). This is the same convention as used in set theory, where a map f from a set A to a set B is sometimes defined as a triple (A,Gf,B), where Gf is a subset in the AB satisfying suitable conditions and called the graph of f. 

9. Isomorphism

Definition 9.1. Let f : A  B be a morphism in a category C. A morphism g : B  A is said to be

(a) a left inverse of f if gf = 1A;

(b) a right inverse of f if fg = 1B;

(c) an5 inverse of f if it is a left inverse of f and a right inverse of f at the same time, i.e. if gf = 1A and fg = 1B.

If f is invertible, that is, a g as in (c) does exist, we say that f is an isomorphism, call the objects A and B isomorphic, and write A  B. 

Theorem 9.2. (a) Every identity morphism is the unique inverse of itself;

(b) if g and g' are left inverses of f and f ' respectively and (f,f ') is a composable pair of morphisms, the composite g'g is a left inverse of the composite ff ';

(c) if g and g' are right inverses of f and f ' respectively and (f,f ') is a composable pair of morphisms, the composite g'g is a right inverse of the composite ff ';

(d) if g is a left inverse of f and h is a right inverse of f, then g = h. 

Proof. (a) is obvious; (b): g'gff ' = g'1f ' = g'f ' = 1; (c) is similar to (b); (d): g = g1 = g(fh) = (gf)h = 1h = h. 

5 Just as for 2.3(d), “an” can be replaced with “the”.

11 As follows from 9.2(d), every isomorphism (=a morphism that admits an inverse), has a unique inverse. The inverse of an isomorphism f will be denoted by f1; from Theorem 9.2 we obtain:

1 Corollary 9.3. (a) Every identity morphism is an isomorphism, and 1A = 1A;

(b) if (f,g) is a composable pair of isomorphisms, then fg is an isomorphism, and (fg) 1 = g1f 1;

(c) if f is an isomorphism, then so is its inverse, and (f 1) 1 = f. 

Corollary 9.4. The isomorphism relation  is an equivalence relation, i.e. for every three objects A, B, C in a given category, we have:

(a) A  A,

(b) A  B implies B  A,

(c) A  B and B  C imply A  C. 

Remark 9.5. Using Definition 9.1 in Example 8.3 we obtain usual notions of left inverse, right inverse, inverse, and invertibility of elements in a monoid. 

10. Initial and terminal objects

Definition 10.1. An object Z in a category C is said to be

(a) initial, if for every object A in C there exists a unique morphism from Z to A, which we will denote by !A : Z  A (when Z is fixed);

(b) terminal, if for every object A in C there exists a unique morphism from A to Z, which we will denote by !A : A  Z. 

The following table provides the list of expressions used by various authors instead of “initial” and “terminal”:

initial terminal initial final universal couniversal left universal right universal left zero right zero zero one 0 1

However some authors say “zero” and write “0” only for an object that is initial and terminal at the same time.

It is useful to see “initial” and “terminal” as generalizations of “smallest” and “largest” using Example 8.4. In particular Theorems 10.2 and 10.3 below imply that an ordered set can have at most one smallest and at most one largest element, as we already know from Theorem 7.4. However, the story of initial/terminal is not at all a simple copy of the story of smallest/largest. For instance 0 = 1 (=the existence of an

12 object that is initial and terminal at the same time) holds in many important categories of classical algebra.

Theorem 10.2. Let Z be an initial object and A an arbitrary object in the same category. The following conditions are equivalent:

(a) A is initial;

(b) Z  A;

(c) the morphism !A : Z  A is an isomorphism.

Proof. (a)(b): When both Z and A are initial, there is a unique morphism from Z to A, and a unique morphism from A to Z. We then need to show that the composites Z  A  Z and A  Z  A of these morphisms are identity morphisms of Z and of A respectively. This follows from the fact that since Z and A are initial, there is only one morphism Z  Z and only one morphism A  A.

(b)(c) is trivial since there is exactly one morphism Z  A.

(c)(a): Assuming that !A is an isomorphism, we have to prove that for every object B in the given category, there exists a unique morphism A  B.

1 Existence: Take the composite !B(!A) of !B with the inverse of !A.

Uniqueness: Let f and g be two morphisms A  B. Since every two morphisms 1 1 Z  B are equal, so are f!A and g!A, and we have f = f1A = f!A(!A) = g!A(!A) = g1A = g. 

Let us repeat, omitting the proof, the similar theorem for terminal objects:

Theorem 10.3. Let Z be a terminal object and A an arbitrary object in the same category. The following conditions are equivalent:

(a) A is terminal;

(b) A  Z;

(c) the morphism !A : A  Z is an isomorphism. 

11. Algebras, homomorphisms, isomorphisms

Definition 11.1. Let  be a set equipped with a map l :   {0,1,2,…}, and let 1 1 1 0 = l (0), 1 = l (1), 2 = l (2),…; such a pair (,l) is called a signature. An (,l)-algebra is a pair (A,v), in which A is a set, and v =

l() (v : A  A) is a family of operations on A (with arities as displayed, i.e. for each  in n, v must be an n-ary operation). We will also say that A is the underlying set of (A,v), and that v is the algebra structure of (A,v), or that v is an algebra structure on A. (,l)-algebras are also called universal algebras or algebraic structures. 

Convention and Remark 11.2. (a) We will use the following simplified notation:

13

(,l)-algebra -algebra (A,v) A v(a1,…,an) (a1,…,an) and moreover, we will sometimes write  = (,l) and A = (A,v) in order to express the fact that we write just  and A, but we also remember l and v. Thus, whenever no confusion is expected, we will not distinguish between an algebra (A,v) and its underlying set A.

(b) The abbreviations (a1,…,an) = v(a1,…,an) and A = (A,v) actually suggest removing  and v from the notation completely. For example: a monoid M is an -algebra with

{e} for n = 0, n = {m} for n = 2,  for 0  n  2

(satisfying the conditions we required in Definition 4.1), but we simply write M = (M,e,m) instead of (M,v) and in fact consider e and m not as elements of , but as their images under v. We will use such simplified notation for all particular classes of algebras that we will consider. 

Definition 11.3. Let A and B be -algebras. A f : A  B is a map f from the set A to the set B with

f((a1,…,an)) = (f(a1),…,f(an)) for every n = 0, 1, 2, …, for every  in n, and for every a1, …, an in A. 

Theorem 11.4. Let A, B, C be -algebras. Then:

(a) the identity map 1A : A  A is a homomorphism;

(b) if f : A  B and g : B  C are homomorphisms, then so is their composite gf : A  C.

That is, all -algebras and their homomorphisms form a category in the same way as all sets and all maps between sets do. 

The category of all -algebras and their homomorphisms will be denoted by -Alg.

Theorem 11.5. A morphism f : A  B of -algebras is an isomorphism (in -Alg) if and only if the map f is bijective.

Proof. Being bijective, the map f has a unique inverse, say g. And all we need to prove is that g is a homomorphism. For every n = 0, 1, 2, …, for every  in n, and for every b1, …, bn in B we have

g((b1,…,bn)) = g((fg(b1),…,fg(bn))) = g(f((g(b1),…,g(bn)))) =

14 (g(b1),…,g(bn)) as desired. 

In to this characterization of isomorphisms, it is useful to know that we can always transport an algebra structure along a bijection that will then become an isomorphism:

Theorem 11.6. Let A = (A,v) be an -algebra, B a set, and f : A  B a bijection. Then there exists a unique -algebra structure w on B, such that f : (A,v)  (B,w) is an isomorphism.

Proof. Just observe that when f is a bijection, the equalities f((a1,…,an)) = (f(a1),…,f(an)) (for all a1, …, an in A) are equivalent to the equalities (b1,…,bn) = f((g(b1),…,g(bn))) (for all b1, …, bn in B), where g is the inverse of f. 

12. Subalgebras

Theorem and Definition 12.1. Let A = (A,v) be an -algebra and X a subset in A. The following conditions are equivalent:

(a) X is closed in A under all operations of the -algebra structure, i.e.

a1, …, an  X  (a1,…,an)  X for every n = 0, 1, 2, …, for every  in n, and for every a1, …, an in A;

(b) there exists an -algebra structure w on X such that the inclusion map X  A is a homomorphism from (X,w) to (A,v);

(c) there exists a unique -algebra structure w on X such that the inclusion map X  A is a homomorphism from (X,w) to (A,v).

If these equivalent conditions hold, we will say that X, equipped with the w above, is a subalgebra in A (or a subalgebra of A), and that w is the induced structure on X. In other words, (X,w) is a subalgebra of (A,v) if and only if X is a subset in A and the inclusion map X  A is a homomorphism from (X,w) to (A,v). Considering X as just a set, i.e. without w, we will express the equivalent conditions (a)–(c) by saying that X forms a subalgebra. We will say “-subalgebra” instead of “subalgebra” when the signature  = (,l) is not fixed. 

Remark and Definition 12.2. Let A be an -algebra. The set of subsets in P(A) that form subalgebras is obviously closed under intersections. Therefore this set determines a closure operator c on the set A, which will be written as c(X) = X. The same symbol X will be used for the subalgebra in A with the underlying set X; that is

X = the smallest subalgebra in A containing X = the intersection of all subalgebras in A containing X.

15 We will say that X is the subalgebra in A generated by X. 

Theorem 12.3. Let A be an -algebra and X a subset in A. Then

X = X0  X1  X2  …, where X0, X1, X2, … is the increasing sequence of subsets in A defined inductively as follows:

(a) X0 = X;

(b) Xn1 = Xn  {(a1,…,am) m = 0, 1, 2, …;   m; a1, …, am  Xn}.

Proof. On the one hand the union X0  X1  X2  … obviously forms a subalgebra in A containing X. On the other hand every subalgebra in A must contain Xn1 as soon as it contains Xn, and so every subalgebra in A containing X = X0 also contains the union X0  X1  X2  … . 

One sometimes expresses this result by saying that the elements of X are (iterated) combinations of elements of X (with operators from ).

13. Products

Definition 13.1. Let (Ai)iI be a family of -algebras. The (cartesian) product

Ai iI of the family (Ai)iI is defined as the product of the underlying sets, with the -algebra structure defined component-wise, i.e. defined by ((a1i)iI,…,(ani)iI) = ((a1i,…,ani))iI. We will also write

n Ai = A1…An i=1 when the family is presented as a sequence A1, …, An, etc. 

In particular, for the product AB of two algebras A and B we have

((a1,b1),…,(an,bn)) = ((a1,…,an),(b1,…,bn)). (13.1)

14. Quotient algebras

Theorem and Definition 14.1. Let A = (A,v) be an -algebra and E an equivalence relation on A. The following conditions are equivalent:

(a) E forms a subalgebra in AA, i.e.

a1Eb1, …, anEbn  (a1,…,an)E(b1,…,bn) for every n = 0, 1, 2, …, for every  in n, and for every a1, …, an, b1, …, bn in A;

16

(b) there exists an -algebra structure w on A/E such that the canonical map A  A/E is a homomorphism from (A,v) to (A/E,w);

(c) there exists a unique -algebra structure w on A/E such that the canonical map A  A/E is a homomorphism from (A,v) to (A/E,w).

If these equivalent conditions hold, we will say that:

 E is a congruence on A;  A/E equipped with the w above, is a quotient algebra of A, and that  w is the induced structure on A/E.

In other words, A/E = (A/E,w) is a quotient algebra of A = (A,v) if and only if the canonical map A  A/E is a homomorphism from (A,v) to (A/E,w). 

Remark and Definition 14.2. Let A be an -algebra. The set of subsets in P(AA) that are congruences is obviously closed under intersections. Therefore this set determines a closure operator c on the set AA. A binary relation R on A being a subset in AA has its closure

c(R) = the smallest congruence on A containing R = the intersection of all congruences on A containing R.

We will say that c(R) is the congruence closure of R, or the congruence generated by R. 

15. Canonical factorization of homomorphisms

Theorem 15.1. Every homomorphism f : A  B of -algebras factors as the composite

A

 canonical homomorphism

A/{(a,b) f(a) = f(b)}

 isomorphism sending [a] to f(a)

f(A)

 inclusion homomorphism

B of -algebra homomorphisms; in particular {(a,b) f(a) = f(b)} is a congruence on A and f(A) is a subalgebra in B. In this composite:

(a) A  A/{(a,b) f(a) = f(b)} is an isomorphism if and only if f is injective, and this the case if and only if {(a,b) f(a) = f(b)} is the equality relation;

(b) f(A)  B is an isomorphism if and only if f is surjective, and this the case if and only if f(A) = B;

17 (c) in particular f is an isomorphism if and only if {(a,b) f(a) = f(b)} is the equality relation and f(A) = B. 

16. Classical algebraic structures

In this section we simply list some of especially important algebraic structures, not asking the readers to remember the list – since only a few of these structures are mentioned above in these notes:

(a) Sets can be considered as -algebras with  = .

(b) Pointed sets are pairs (A,a), where A is a set, and a an element in A.

(c) Magmas were defined in Section 2.

(d) Semigroups were defined in Section 3.

(e) Unitary magmas were defined in Section 2.

(f) Monoids were defined in Section 4.

(g) Groups: a is a system (A,e,m,i) in which (A,e,m) is a monoid and i is a unary operation on A with m(i(a),a) = e (= m(a,i(a)). One usually writes either (A,e,m,i) = (A,1,,1) and

m(a,b) = ab = ab, e = 1, and i(a) = a1, or (A,e,m,i) = (A,0,,) and

m(a,b) = a  b, e = 0, and i(a) = a, i.e. uses either multiplicative or additive notation; the additive notation is preferable when m is commutative, in which case the group is called commutative, or abelian. The same applies also to monoids, yielding two other important types of algebraic structures:

(h) Abelian monoids = commutative monoids.

(i) Abelian groups = commutative groups.

(j) Semirings = rigs: a semiring is a system (A,0,,1,) in which (A,0,) is a commutative monoid and (A,1,) is a monoid with 0a = 0 = a0, a(b  c) = ab  ac, and (a  b)c = ab  ac (“distributivity”, or “distributive laws” for multiplication with respect to addition and 0) for all a, b, and c in A.

(k) Rings: a is a system (A,0,,,1,) in which (A,0,,1,) is a semiring and (A,0,,) is a group. Sometimes, however, the associativity requirement for the multiplication  is dropped and/or there is no 1 (i.e. the structure becomes (A,0,,,) in the notation above). We would then say “non-associative ring” and/or “ring without 1”. The requirements 0a = 0 = a0 are dropped in any case, since they can deduced from others (e.g. 0a = 0a  0a  (0a) = (0  0)a  (0a) = 0a  (0a) = 0).

(l) Commutative Rings: as above, but the multiplication  is required to be commutative.

18 (m) Fields: a is a system (A,0,,,1,,1) in which (A,0,,,1,) is a and (A\{0},1,,1) is a group. Since A\{0} is involved here, this definition as stated does not present a field as an . However, since the operation 1 on the set A\{0} is uniquely determined (when it exists), a field can be considered as a commutative ring satisfying an additional condition.

(n) M-sets: let M = (M,1,) be a monoid (or, more generally, a unitary magma) – then an M-set (or an (M,1,)-set) is a pair (A,), where A is a set and  : MA  A a map written (usually) as (m,a) = ma and satisfying 1a = a and m(m'a) = (mm')a for all a in A and m, m' in M. This definition as stated does not present an M-set as an algebraic structure since it involves a map, namely , that is not an operation in the sense of Definition 1.1. However, this map can equivalently be described an M-indexed family (m)mM of unary operations on A, where m(a) = (m,a). Therefore an M-set can be considered as an (,l)-algebra with  = M and l(m) = 1 for each m in M.

(o) R-semimodules: for a semiring R = (R,0,,1,), an R-semimodule, or a semimodule over R, is a system (A,0,,) in which (A,0,) is a commutative monoid and (A,) an (R,1,)-set with r0 = 0 = 0a, r(a  b) = ra  rb, and (r  s)a = ra  sa for all r and s in R and a and b in A.

(p) R-modules: for a ring R = (R,0,,,1,), an R-, or a module over R, is the same as a semimodule over (R,0,,1,). Here again, the requirements r0 = 0 = 0a are dropped since they follow from others (cf. (k)).

(q) K-vector spaces: for a field K = (K,0,,,1,,1), a K-, or a vector space over K, is the same as a module over (K,0,,,1,).

(r) R-algebras: for a commutative ring R = (R,0,,,1,), an R-algebra, or an algebra over R, is a system A = (A,0,,,), where (A,0,,) is a ring without 1 and (A,0,,) an R-module with r(ab) = (ra)b = a(rb) for all r in R and a and b in A. Similarly to rings one can introduce “non-associative” and “non-commutative” algebras.

(s) Unitary R-algebras: for a commutative ring R = (R,0,,,1,), an unitary R-algebra is a system A = (A,0,,,1,), where (A,0,,,) is an R-algebra and (A,1,) is a unitary magma. And again, similarly to rings one can introduce “non-associative” and “non-commutative” unitary algebras.

(t) Lie R-algebras: for a commutative ring R, a non-associative non-commutative R-algebra A is said to be a Lie R-algebra, or a over R if ab = ba and a(bc)  b(ca)  c(ab) = 0 for all a, b, and c in A. Lie R-algebras are usually considered for R being a field.

(u) Semilattices: a commutative monoid (A,1,) is said to be a if it is idempotent, i.e. a2 = aa = a for all a in A. For a semilattice A, we also write A = (A,1,) and then call it a -semilattice, or write A = (A,0,) and then call it a -semilattice.

(v) Lattices: a is a system A = (A,0,,1,), in which (A,0,) and (A,1,) are semilattices with a  (a  b) = a = a  (a  b) for all a and b in A.

(w) Modular lattices: a lattice A = (A,0,,1,) is said to be modular if a  (b  (c  a)) = (a  b)  (c  a) for all a, b, and c in A.

(x) Distributive lattices: a lattice A = (A,0,,1,) is said to be distributive if a  (b  c) = (a  b)  (a  c) for all a, b, and c in A.

19

(y) Heyting algebras: a is a system A = (A,0,,1,,) in which (A,0,,1,) is a distributive lattice and  a binary operation on A with a  (b  (a  b)) = a = a  (b  (b  a)) for all a, b, and c in A.

(z) Boolean algebras: a Boolean algebra is a system A = (A,0,,1,,) in which (A,0,,1,) is a distributive lattice and  is a unary operation on A with a  a = 0 and a  a = 1 for all a in A.

17. Quotient groups, rings, and modules

Quotient algebras of the form A/E, where E is a congruence on A, were already described in Section 14. However, for many classical algebraic structures one can make a next step, namely to prove that all congruences are determined by their single classes that are special subsets of the ground algebra. We shall give details for the three types of algebras mentioned in the title of this section. Their subalgebras will be called subgroups, , and submodules, respectively.

Theorem 17.1. Let A = (A,1,,1) be a group. For every subgroup S of A, the sets

{(a,b)  AA  ab1  S} = {(a,b)  AA  ba1  S} (17.1) and

{(a,b)  AA  a1b  S} = {(a,b)  AA  b1a  S} (17.2) are equivalence relations on A.

Proof. First note that the equalities of (17.1) and (17.2) indeed hold, since (ab1)1 = ba1 and (a1b)1 = b1a. To prove that the set (17.1) is an equivalence relation we observe:

 Since, for every a in A, we have aa1 = 1  S, it is reflexive.  Since, for ab1  S, we have ba1 = (ab1)1  S (cf. 9.3(b)), it is symmetric (and the equality of (17.1) holds).  Since, for ab1, bc1  S, we have ac1 = (ab1)(bc1)  S, it is transitive.

The fact the set (17.2) is an equivalence relation can be proved similarly. 

For any monoid A, the set P(A) of all subsets of A has a natural monoid structure defined by

UV = {uv  u  U, v  V}; (17.3) the identity element in this monoid is the one-element set {1}, and, moreover, sending u to {u} determines a monoid homomorphism A  P(A). Whenever there is no danger of confusion, we shall identify A with its image in P(A), and write e.g. aV instead of {a}V.

20 When A is a group, and S a subgroup of A, the sets of the form aS and Sa (for a  A) are called right and left6 cosets (of S), respectively; when left and right cosets coincide they are simply called cosets.

Proposition 17.2. For A and S as in Theorem 17.1, the left and right cosets of S are the equivalence classes with respect to the equivalence relations (17.1) and (17.2).

Proof. Just note that ab1  S  a  Sb and b1a  S  a  bS. 

Moreover, we have:

Theorem 17.3. For A and S as in Theorem 17.1, the following conditions are equivalent:

(a) the sets (17.1) and (17.2) coincide;

(b) aS  Sa for every a  A;

(c) Sa  aS for every a  A;

(d) aS = Sa for every a  A;

(e) aSa1  S for every a  A;

(f) S  aSa1 for every a  A;

(g) aSa1 = S for every a  A.

Proof. (a)(d) follows from Proposition 17.2.

(b)(e): aS  Sa  aSa1  Saa1 = S.

(e)(b): aSa1  S  aSa1a  Sa, but aSa1a = aS.

(c)(f): Sa  aS  Saa1  aSa1, but Saa1 = S.

(f)(c): S  aSa1  Sa  aSa1a = aS.

(b)(f): if aS  Sa for every a  A, then a1S  Sa1 for every a  A, and so aa1S  aSa1 for every a  A; but aa1S = S.

(f)(b): if S  aSa1 for every a  A, then S  a1Sa for every a  A, and so aS  aa1Sa = Sa for every a  A.

The last six implications show that conditions (b), (c), (e), and (f) are equivalent to each other. Since the conjunction of (b) and (c) is equivalent to (d), and the conjunction of (e) and (f) is equivalent to (g), we can conclude that all conditions (b)-(g) are equivalent to each other. Together with the equivalence (a)(d) this completes the proof. 

Definition 17.4. A subgroup S of a group A is said to be normal if it satisfies the equivalent conditions of Theorem 17.3. 

Lemma 17.5. If S is a normal subgroup of a group A, then sending each a  A to aS determines a semigroup homomorphism A  P(A).

6 Some authors would say “left” for aS and “right” for Sa.

21

Proof. Just note that we can write (aS)(bS) = aSbS = abSS = abS = (ab)S. 

Theorem 17.6. For a subset S of a group A, the following conditions are equivalent:

(a) S is a normal subgroup of A;

(b) at least one of the sets (17.1) and (17.2) is a congruence on A;

(c) the sets (17.1) and (17.2) coincide with each other and it is a congruence on A;

(d) there exists a congruence E on A with [1]E = S;

(e) there exists a unique congruence E on A with [1]E = S;

(f) there exists a f : A  B with Ker(f) = S, where the Ker(f) of f is defined as Ker(f) = f 1(1).

Proof. Suppose S is normal and consider the set A/S of cosets of S. As easily follows from Lemma 17.5, it has a group structure whose multiplication is defined by

(aS)(bS) = (ab)S.

By Proposition 17.2 this means that the quotient set A/E, where E is the equivalence relation (17.1) (or (17.2), which is the same since S is normal), has a group structure whose multiplication is defined by

[a]E[b]E = [ab]E.

Therefore (a) implies (c). The implications (c)(b) and (e)(d) are trivial, and we also have:

 (b) implies (d), since, for E being either the set (17.1) or the set (17.2), we have (a,1)  E  a  S;  (d) implies (e) since (a,b)  E  (a,b)(b1,b1)  E  (ab1,1)  E;  (d) implies (f) since we can use the canonical homomorphism A  A/E as f, and 1 then f (1) = [1]E = S;  (f) implies (a) since, for f : A  B as in (f) and every a  A and s  S we have f(asa1) = f(a)f(s)f(a)1 = f(a)1f(a)1 = f(a)f(a)1 = 1, which gives aSa1  S. 

Since every ring has its additive group structure, the results above will help us to establish similar results for rings. However:

 Considering rings instead of groups we have to use the additive notation, in which 1 we will have e.g. Ker(f) = f (0) = [0]E, (a,b)  E  a  b  S (where a  b is defined as a  (b)), and a  S instead of aS (in the situations above).  When a group A is abelian, which is always the case for the additive group of ring, every subgroup of A is normal. On the other hand, an arbitrary subgroup S of the additive group of a ring A will make A/S a group, but not a ring in general. For example, if S contains the identity element 1 of A, then it determines a congruence on the ring A only in the trivial case S = A.  There is no counterpart of Theorem 17.3 for rings.

22 Accordingly the story of quotient rings is short: it consists of one definition and a counterpart of Theorem 17.6, whose substantial part actually follows from Theorem 17.6.

Definition 17.7. A subgroup S of the additive group of a ring A is said to be an if as and sa are in S for every a in A and every s in S. 

Remark 17.8. A ring A can always be considered as a module over itself, that is, as an A-module; submodules of this module are called left ideals of A. On the other hand, every ring A has its Aop defined as the same with the opposite multiplicative structure, making ab in Aop the same as ba in A. The left ideals of Aop are called the right ideals of A. That is:

(a) a subgroup S of the additive group a ring A is a left ideal of A if and only if as is in S for every a in A and every s in S;

(b) a subgroup S of the additive group a ring A is a right ideal of A if and only if sa is in S for every a in A and every s in S;

(c) a subset S of a ring A is an ideal of A if and only if it is a left and a right ideal of A at the same time.

Ideals are therefore also sometimes called two-sided ideals, and, as next theorem shows, the play the same role in as normal subgroups do in . 

Theorem 17.9. For a subset S of a ring A, the following conditions are equivalent:

(a) S is an ideal of A;

(b) the set {(a,b)  AA  a  b  S} is a congruence on A;

(c) there exists a congruence E on A with [0]E = S;

(d) there exists a unique congruence E on A with [0]E = S;

(e) there exists a f : A  B with Ker(f) = S, where the kernel Ker(f) of f is defined as Ker(f) = f 1(0).

Proof. Having in mind Theorem 17.6, we only need to prove that (a) implies that {(a,b)  AA  a  b  S} is closed in AA under the multiplication, and that (e) implies (a). The first of these assertions follows from the simple formula

ac  bd = (a  b)c  b(c  d), since a  b  S makes (a  b)c  S and c  c  S makes b(c  d)  S. The second one follows from two other simple formulas, namely a0 = 0 and 0a = 0 (for all a  A). 

Similarly, but even easier, for a module over a ring we have:

Theorem 17.10. For a subset S of an R-module A, the following conditions are equivalent:

(a) S is a submodule of A;

23 (b) the set {(a,b)  AA  a  b  S} is a congruence on A;

(c) there exists a congruence E on A with [0]E = S;

(d) there exists a unique congruence E on A with [0]E = S;

(e) there exists an R-module homomorphism f : A  B with Ker(f) = S, where the kernel Ker(f) of f is defined as Ker(f) = f 1(0). 

These results allow talking about quotients with respect to:

 normal subgroups in the case of groups,  ideals in the case of rings,  submodules in the case of modules, instead of quotients with respect to congruences. Accordingly we shall write A/S instead of A/{(a,b)  AA  ab1  S} in the situation of Theorem 17.6, and instead of A/{(a,b)  AA  a  b  S} in the situations of Theorems 17.9 and 17.10. We say that S is trivial if it has only one element, making A/S canonically isomorphic to A.

Theorem 15.1 gives:

Theorem 17.11. Let f : A  B be a homomorphism of either groups, or rings, or R-modules; f factors as the composite

A

 canonical homomorphism

A/Ker(f)

 isomorphism sending [a] to f(a)

f(A)

 inclusion homomorphism

B of groups, or rings, or R-modules respectively. In this composite:

(a) A  A/Ker(f) is an isomorphism if and only if f is injective, and this the case if and only if Ker(f) is trivial;

(b) f(A)  B is an isomorphism if and only if f is surjective, and this the case if and only if f(A) = B. 

(c) in particular f is an isomorphism if and only if Ker(f) is trivial and f(A) = B. 

24 II. LATTICES, SEMIRINGS, FOUNDATION OF LINEAR ALGEBRA, NUMBERS AND DIVISIBILITY

1. Commutativity

In this section we will use additive notation for semigroups and monoids; accordingly, in the situation of Section I.3, instead of

n n mn(a1,…,an) = a1…an = ai = i=1ai i=1 we will write

n n mn(a1,…,an) = a1 … an = ai = i=1ai (1.1) i=1

Theorem 1.1. Let (a1, …, an) be an n- of elements a commutative semigroup S and f : {1, …, n}  {1, …, n} a bijection. Then

n n i=1ai = i=1af(i) in S.

Proof. Using mathematical induction and fact that the statement of the theorem is (trivially) true for n = 1, we can assume that, for every bijection g : {1, …, n1}  {1, …, n1}, we have

n1 n1 i =1ai = i =1ag(i), which we will call here our inductive assumption. We will use this equality for g defined by

f(i) if i < f1(n), g(i) = f(i1) if i  f1(n); it is easy to see that the image of {1, …, n1} under g coincides with {1, …, n}\{n} = {1, …, n}, and so g is a bijection indeed. We have

n n1 i=1ai = (i =1ai)  an (using (the additively written version of) (3.3)) n1 = (i =1ag(i))  an (by our inductive assumption) n1 1 = (i =1ag(i))  af(m) (where m = f (n)) m1 n1 = ((i =1ag(i))  (i =mag(i)))  af(m) (by (3.3) again) m1 n1 = ((i =1af(i))  (i =maf(i1)))  af(m) (by the definition of g) m1 n1 = (i =1af(i))  ((i =maf(i1))  af(m)) (by associativity) m1 n1 = (i =1af(i))  (af(m)  (i =maf(i1))) (by commutativity) m1 n = (i =1af(i))  (af(m)  (i =m1af(i))) (using obvious re-indexing)

25 m1 n = (i =1af(i))  (i =maf(i)) (by (3.3)) n = i=1af(i) (by (3.3)). 

This theorem tells us that performing callucations in a commutative semigroup, not only omitting parentheses but even arbitrary permutations of summands are allowed. In particular we can write

(a  b)  (c  d) = (a  c)  (b  d), (1.2) which in fact expresses the fact that the addition map SS  S is a homomorphism whenever S is a commutative semigroup. Furthermore, it characterizes commutative monoids as follows:

Theorem 1.2. The following conditions on a unitary magma (M,0,) are equivalent:

(a) (M,0,) is a commutative monoid;

(b) the equality (1.2) holds for all a, b, c, and d in M.

Proof. (a)(b) follows from Theorem 1.1 (but can also easily be proved directly of course). In order to prove (b)(a), we need to show that (b) implies associativity and commutativity of . We have:

a  (b  c) = (a  0)  (b  c) = (a  b)  (0  c) = (a  b)  c, and

a  b = (0  a)  (b  0) = (0  b)  (a  0) = b  a, as desired. 

2. Semilattices

Definition 2.1. Let (X,) be an ordered set, S a subset of X and a an element in X. We say that a is the infimum, or meet of S, and write

a = inf S = S, (2.1) if the following conditions hold:

(a) a  s for every s  S;

(b) if an element x in X is such that x  s for every s  S, then x  a. 

Briefly, (2.1) means that a is the largest element in X with the property 2.1(a). When S is a finite set, say S = {s1,…,sn}, we shall also write

n a = i=1si = s1  …  sn, (2.2) and, in particular, this defines the binary meet operation

26  : XX  X, (2.3) whenever every two-element subset of X has a meet. This operation, whenever it exists, is associative and commutative, and so Theorem 1.1 applies to it. Moreover, it is obviously idempotent, and in fact this establishes a bijection between the set of order relations with binary meets on any given set X and the set of idempotent commutative semigroup structures on X. Let us explain:

For a fixed set X consider the diagram

The set of binary f The set of binary operations on X relations on X

  (2.4)

The set of idempotent g The set of order commutative semigroup relations on X with structures on X h binary meets

in which:

 the map f is defined by f(m) = {(x,y)  XX  x = m(x,y)};  the map g is defined by the restriction of f, which requires to show that when m : XX  X is associative, commutative, and idempotent, the corresponding relation f(m) is an order relation – see Lemma 2.2 below;  the map h sends order relations to the corresponding meet operations as described above.

Lemma 2.2. Let m be a binary operation on a set X, and R = f(m) = {(x,y)  XX  x = m(x,y)} the corresponding binary relation on X, as described above. Then:

(a) if m is idempotent, then R is reflexive;

(b) if m is commutative, then R is antisymmetric;

(c) if m is associative, then R is transitive.

Therefore, if m is idempotent, commutative, and associative, then R is an order relation.

Proof. Let us write xy instead of m(x,y).

(a): Just note that (x,x)  R  x = xx.

(b): ((x,y)  R & (y,x)  R)  (x = xy & y = yx)  (x = xy = yx = y).

(c): ((x,y)  R & (y,z)  R)  (x = xy & y = yz)  (x = xy = x(yz) = (xy)z = xz)  (x,z)  R. 

The following theorem completes the desired explanation:

27 Theorem 2.3. The maps g and h in diagram (2.4) are inverse to each other, and therefore they establish a bijection between the set of order relations with binary meets on any given set X and the set of idempotent commutative semigroup structures on X.

Proof. To prove that hg is the identity map is to prove that, given an idempotent, commutative, and associative binary operation m on X we have

xy = x  y, (2.5) for every x, y  X, where xy = m(x,y), while x  y is the meet of {x,y} with respect to the order defined by

x  y  x = xy. (2.6)

And to prove (2.5) is to prove that xy is the largest element z in X with z  x and z  y with respect to the same order. Indeed, we have:

 (xy)x = (yx)x = y(xx) = yx = xy = x and (xy)y = x(yy) = xy = x, which shows that xy  x and xy  y;  if z  x and z  y, then z = zx and z = zy; this gives z(xy) = (zx)y = zy = z and so z  xy.

To prove that gh is the identity map is to prove that, for a given order relation  on X, we have

x  y  x = x  y, (2.7) for every x, y  X, where x  y is the meet of {x,y} with respect to the order . But this easily follows from the definition of meet. 

Example 2.4. An order  on X is said to linear if, for every x, y  X we have either x  y or y  x. It is easy to see that the following conditions on an order  and the corresponding binary meet operation are equivalent:

(a)  is a linear order;

(b) x  y  {x,y} for every x, y  X;

(c) every subset of X is a subsemigroup of (X,). 

Example 2.5. Let X be a set, and  the inclusion order on the power set P(X). Then  = , that is, the corresponding meet operation is nothing but the intersection operation. Formally this applies to binary meets, but we also have S = S for an arbitrary set S of subsets in X of course. 

Example 2.6. Let X be a set, and (X) the set of equivalence classes of assertions on elements of X; not going into details of the corresponding logic, let us assume that two such assertions  and  are identified if and only if

{x  X  (x)} = {x  X  (x)}. (2.8)

28 Then the sets (X) and P(X) are bijective (again, under suitable assumptions on the logic involved, which we are not discussing here); under this bijection an assertion  corresponds to the subset {x  X  (x)} of X, while a subset S corresponds to the assertion x  S. We have:

(a) S  T if and only if x  S implies x  T;

(b) x  S  T if and only if (x  S)&(x  T).

That is, under the bijection above, the inclusion order on P(X) corresponds to the implication order on (X), while the corresponding meet operation, which the intersection operation, corresponds to the conjunction operation on (X).

Remark 2.7. In fact 2.6(a) and 2.6(b) are used in mathematics to define inclusion and intersection respectively. Moreover, conjunction is in fact used to define meets. Indeed, the definition of, say, the binary meet can be formulated as

x  a  b  (x  a)&(x  b) (2.9)

(here we use the fact that an element c in an ordered set X is completely determined by the set {x  X  x  c}). Furthermore, in fact the binary meet operation is associative, commutative, and idempotent because so is the . Indeed,

x  a  (b  c)  (x  a)&(x  b  c)  (x  a)&((x  b)&(x  c))  ((x  a)&(x  b))&(x  c)  (x  a  b)&(x  c)  x  ((a  b)  c),

x  a  b  (x  a)&(x  b)  (x  b)&(x  a)  x  b  a,

x  a  a  (x  a)&(x  a)  x  a  x  a.

Nevertheless it is true of course that the conjunction operation is a very special case of the meet operation (we should say “up to logic”; see Example 2.6). 

Having finite meets is of course equivalent to have binary meets and empty meet (=the meet of the empty subset). And the empty meet is nothing but the largest element 1 in the given ordered set; note also that x  1  x = x1. Therefore we obtain:

Theorem 2.8. The bijection described in Theorem 2.3 induces a bijection between the set of order relations with finite meets on X and the set of idempotent commutative monoid structures on X. 

Recall from paragraph (u) of Section I.16 that idempotent commutative monoids are called semilattices.

3. Lattices

Definition 3.1. Let (X,) be an ordered set, S a subset of X and a an element in X. We say that a is the supremum, or join of S, and write

29 a = sup S = S, (3.1) if the following conditions hold:

(a) s  a for every s  S;

(b) if an element x in X is such that s  x for every s  S, then a  x. 

Briefly, (3.1) means that a is the smallest element in X with the property 3.1(a). When S is a finite set, say S = {s1,…,sn}, we shall also write

n a = i=1si = s1  …  sn, (3.2) and, in particular, this defines the binary join operation

 : XX  X, (3.3) whenever every two-element subset of X has a join.

Every order relation  on a set X determines the reverse (or opposite) order  on X defined by

x  y  y  x, (3.4) and we have

 = , (3.5) which tells us that the passage from orders to their reverse orders is a bijection inverse to itself. Under this bijection joins correspond to meets and meets correspond to joins, that is

(a = S under )  (a = S under ), (3.6) (a = S under )  (a = S under ). (3.7)

Therefore all constructions and results of previous sections have their obvious counterparts, in which meets are replaced with joins. Having this in mind, the following theorem immediately follows from the results of previous section:

Theorem 3.2. Let X be a set. There exist a bijection between all systems (X,0,,1,), in which (X,0,) and (X,1,) are semilattices, and systems (X,0,1), in which 0 and 1 are order relations with finite joins and finite meets respectively, under which

x 0 y  y = x  y and z 1 t  z = z  t, (3.8) for all x, y, z, t  X. 

This theorem suggests to find out conditions on (X,0,,1,) under which the two orders 0 and 1 coincide, and we have:

30 Theorem 3.3. Let (X,0,,1,) be as in Theorem 3.2, and let 0 and 1 be the corresponding orders on X defined via (3.8). Then the following conditions are equivalent:

(a) 0 = 1;

(b) (X,0,,1,) is a lattice (see (v) in Section I.16), that is ((X,0,) and (X,1,) are semilattices and) the absorption law x  (x  y) = x = x  (x  y) holds for all x and y in X.

Proof. (a)(b): Assuming (a) and writing  instead of 0 and 1, we have

x  y  x  x  y, (3.9) and so x  (x  y) = x = x  (x  y) as desired.

(b)(a): Assuming (b) and x 0 y, we have

x  y = x  (x  y) = x, and so x 1 y. Similarly (or applying the same argument to the reverse order) we can show that, assuming (b), x 1 y implies x 0 y. 

Corollary 3.4. The bijection described in Theorem 3.2 induces a bijection the set of lattice structures on X and the set of order relations on X with finite joins and finite meets. 

4. Distributivity and complements

Theorem 4.1. The following conditions on a lattice L = (L,0,,1,) are equivalent:

(a) x  (y  z) = (x  y)  (x  z) for all x, y, z  L;

(b) x  (y  z) = (x  y)  (x  z) for all x, y, z  L.

Proof. It suffices to show that (a)(b) – since (a)(b) applied to the opposite order gives (b)(a). Assuming (a), we have:

(x  y)  (x  z) = ((x  y)  x)  ((x  y)  z) (by (a)) = ((x  (x  y))  (z  (x  y)) (by commutativity of ) = x  ((z  x)  (z  y)) (by absorption law and (a)) = (x  (z  x))  (z  y) (by associativity of ) = x  (z  y) (by absorption law) = x  (y  z) (by absorption law), as desired. 

That is, the distributive laws 4.1(a) and 4.1(b) are equivalent to each other, and each of them can be used to define a distributive lattice (see (x) in Section I.16).

31 Definition 4.2. Let a be an element in a lattice L = (L,0,,1,). An element b in L is said to be a complement of a, if a  b = 0 and a  b = 1 in L. In particular 0 and 1 are unique complements to each other. 

Theorem 4.3. If L is a distributive lattice, a an element in L, and b a complement of a in L, then:

(a) b is the largest element among the elements c in L with a  c = 0;

(b) b is the smallest element among the elements c in L with a  c = 1.

Proof. Since (a) applied to the opposite order becomes (b), it suffices to prove (say) (a). If a  c = 0, we have

b = b  0 = b  (a  c) = (b  a)  (b  c) = 1  (b  c) = b  c, and so c  b, as desired. 

Corollary 4.4. If L is a distributive lattice and b and c are complements of a in L, then b = c. 

Example 4.5. Examples 2.5 and 2.6 in fact describe distributive lattices

P(X) = (P(X),,,X,) and (X) = ((X), false, disjunction, true, conjunction), in which every element has a (unique) complement, namely:

(a) for A  X, the complement of A in P(X) is the usual set-theoretic complement {x  X  x  A};

(b) for  in (X), the complement of  is its negation . 

Example 4.6. A linear order is a lattice if and only if it has the smallest element 0 and the largest element 1. Every such lattice is distributive, but its only complemented elements (that is, elements that have complements) are 0 and 1. 

Example 4.7. When a lattice is finite and, moreover, has a small number of elements it is convenient to display it as a set of points on a plane connected by lines – in such a way that x  y if and only if x and y are connected by a line and x is “below” y. In particular, consider the following four lattices Li (i = 1, 2, 3, 4):

1 1 1 1     L1 L2 L3 L4  b a  a   b a  b c  a   c     0 0 0 0, and observe that the element a has no complement in L1, has a unique complement in L2 (namely b), and has two complements in L3 and two complements in L4 (which are

32 b and c in each case). Therefore among these lattices only L1 and L2 can be distributive, and, indeed, they are – since for L1 is a (or has the) linear order, while L2 is isomorphic to (P(X),,,X,), when X is a two-element set. 

5. Complete lattices

Theorem 5.1. The following conditions on an ordered set X = (X,) are equivalent:

(a) every subset of X has a meet;

(b) every subset of X has a join.

Proof. Just observe that

S = {x  X  sS s  x} and S = {x  X  sS x  s}, (5.1) for every subset S of X; here equality signs mean “the left-hand side exists if and only if the right-hand does, and they are equal”. 

That is replacing finite meets and joins with infinite ones, makes meets and joins “better related to each other”. On the other hand, in contrast to Theorem 4.1, the infinite versions of the distributive laws 4.1(a) and 4.1(b), namely

x  (S) = {x  s  s  S} and x  (S) = {x  s  s  S}, (5.2) are not equivalent to each other. For example the lattice of open subsets of the real line satisfies the first of them, but not the second one (we omit the details).

Definition 5.2. A lattice is said to be complete if it admits all meets and joins, that is, has meets and joints of each of its subsets. 

Remark 5.3. From Theorem 5.1 it immediately follows that:

(a) In Definition 5.2, it suffices either to require (just) the existence of meets or to require the existence of joins.

(b) Every finite semilattice (X,1,) has a unique (complete) lattice structure (X,0,,1,), under which (X,1,) = (X,1,), and unique lattice structure (X,0,,1,), under which (X,1,) = (X,0,). In order to avoid confusion between these two structures, one usually begins with a lattice (X,0,,1,) and calls (X,1,) and (X,0,) the corresponding meet-semilattice (or -semilattice) and join-semilattice (or -semilattice) respectively. 

Let L be a complete lattice, a an element in L and

S = {x  L  a  x = 0}.

Then, assuming the first equality in (5.2), we would conclude that S is the largest element among the elements c in L with a  c = 0. Such element is called the pseudo-complement of a. It is obviously uniquely determined and, according to Theorem 4.3(a) coincides with the complement of a whenever a has a complement.

33 However, it might happen that a has no complement but still has a pseudo- complement. For example, if L is a linear order, then 0 is the pseudo-complement of every element in L except 0, while (as already mentioned) only 0 and 1 have complements.

Remark 5.4. Some authors, especially old ones, prefer to avoid using empty meets and joins. In their terminology:

(a) semilattices are idempotent commutative semigroups;

(b) hence, defined via order relations, their semigroups have just binary meets (or joins), and, equivalently, finite non-empty ones;

(c) accordingly, their lattices have binary, or, equivalently, finite non-empty, meets and joins – while those with 0 and 1 are called bounded lattices;

(d) there are -complete semilattices that are not lattices, and -complete semilattices that are not lattices; the formulas (5.1) cannot be used there since empty meets/joins are not defined. In that terminology, Theorem 5.1 would be reformulated as: every -complete semilattice having the largest element has arbitrary joins, and every -complete semilattice having the smallest element has arbitrary meets. 

6. Boolean algebras

As defined at the end of Section I.16, a Boolean algebra is a system (A,0,,1,,), in which (A,0,,1,) is a distributive lattice and  is a unary operation on A with a  (a) = 0 and a  (a) = 1 for all a in A. As we see now, a Boolean algebra is nothing but a distributive lattice in which every element has a (unique) complement. In particular, P(X) and (X) of Example 4.5 are in fact Boolean algebras, and the symbol  agrees with the same symbol used for the negation operation on (X).

Theorem 6.1. If (A,0,,1,,) is a Boolean algebra, then so is (A,1,,0,,), and the map  : A  A is inverse to itself and determines isomorphisms

(A,0,,1,,)  (A,1,,0,,) and (A,1,,0,,)  (A,0,,1,,).

Proof. We already know that complements are uniquely determined in any distributive lattice (whenever they exist), and since the binary relation

{(x,y)  A  x is a complement of y} is obviously symmetric, it follows that the map  : A  A is inverse to itself. After that it suffices to prove that

x  y  y  x. (6.1)

By Theorem 4.3(a), x is the largest element among the elements a in A with x  a = 0. Therefore, all we need to prove is the implication x  y  x  y = 0. For x  y we have

34 t  x  y  (t  x & t  y)  (t  y & t  y)  t  y  y  t = 0, and so x  y = 0, as desired. 

Corollary 6.2. In every Boolean algebra A, we have

(x  y) = (x)  (y), (6.2) de Morgan laws (x  y) = (x)  (y), (6.3)

x = x, (6.4) for every x, y  A. 

These results of course simplify calculations of algebraic expressions in a Boolean algebra, but there are further simplifications. We shall present here one of them, which transforms Boolean algebras into commutative rings (see Section I.16) with idempotent multiplication:

Theorem 6.3. (a) Let A = (A,0,,1,,) be a Boolean algebra. Putting

x  y = (x  y)  (y  x), x = x, and xy = x  y (6.5) determines a commutative ring structure on A with the same 0 and 1.

(b) Let (A,0,,,1,) be a commutative ring with idempotent multiplication. Then x = x for every x  A, and putting

x  y = x  y  xy, x  y = xy, and x = 1  x (6.6) determines a Boolean algebra structure on A with the same 0 and 1.

(c) the constructions above determine inverse to each other between the Boolean algebra structures on a given set A and the commutative ring structures on A with idempotent multiplication.

Proof. (a): Allowing ourselves to omit some simple details, we have

x  (y  z) = (x  ((y  z)  (z  y)))  (((y  z)  (z  y))  x) = (x  (y  z)  (z  y))  (y  z  x)  (z  y  x) = (x  (y  z)  (z  y))  (y  z  x)  (z  y  x) = (x  y  z)  (x  z  y)  (y  z  x)  (z  y  x) = (x  y  z)  (x  y  z)  (x  y  z)  (x  y  z), and similarly (x  y)  z can be expressed in the same way; that is,  is associative. We also have

x  0 = (x  0)  (0  x) = (x  1)  0 = x  0 = x,

35 x  x = (x  x)  (x  x) = 0  0 = 0, and  is obviously commutative. That is, (A,0,,) is an abelian group with x = x for every x  A. The fact that (A,1,) is an idempotent commutative monoid immediately follows from definition of a Boolean algebra. It remains to show that x(y  z) = xy  xz for every for every x, y, z  A (recall from I.16(k) that 0x = 0 holds in every ring). We have

x(y  z) = x  ((y  z)  (z  y)) = (x  y  z)  (x  z  y),

xy  xz = ((x  y)  (x  z))  ((x  z)  (x  y)) = ((x  y)  (x  z))  ((x  z)  (x  y)) = (x  y  z)  (x  z  y), and so x(y  z) = xy  xz.

(b): The equality x = x follows from

x  x  x  x = xx  xx  xx  xx = (x  x)(x  x) = x  x.

Next, we have

x  (y  z) = x  (y  z  yz)  x(y  z  yz) = x  y  z  xy  xz  yz  xyz = (x  y  xy)  z  (x  y  xy)z = (x  y)  z,

x  0 = x  0  x0 = x,

x  y = x  y  xy = x  y (since  and  are commutative),

x  x = x  x  xx = 0  x = x, and so (A,0,) is a semilattice. The same is true for (A,1,) = (A,1,) by our assumptions. We also have

x  (x  y) = x  xy  xxy = x  xy  xy = x,

x  (x  y) = x(x  y  xy) = xx  xy  xxy = x  xy  xy = x,

x  (y  z) = x(y  z  yz) = xy  xz  xyz = xy  xz  xyxz = (x  y)  (x  z),

x  x = x(1  x) = x  xx = x  x = 0,

x  x = x  1  x  x(1  x) = 1 + x  x  x  x = 1  0 = 1, and so (A,0,,1,,) is a Boolean algebra.

(c): Let (A,0,,1,,) be a Boolean algebra, (A,0,,,1,) the corresponding ring defined as in (a), and then (A,0',',1',',') the Boolean algebra obtained from it as in (b). We have

36

x ' y = xy = x  y, for all x, y  A, and so the orders on A determined by the two Boolean algebra structures coincide. This immediately tells us that (A,0,,1,,) = (A,0',',1',','). Conversely, let (A,0,,,1,) be a commutative ring with idempotent multiplication, (A,0,,1,,) the corresponding Boolean algebra defined as in (b), and then (A,0',',',1',') the ring obtained from it as in (a). We have

x ' y = (x  y)  (y  x) = x(1  y)  y(1  x)  xy(1  y)(1  x) = x  xy  y  xy  0 = x  y,

x'y = x  y = xy (=xy), which completes the proof. 

7. Semirings and semimodules

Semirings and semimodules are defined in paragraphs (j) and (o) of Section I.16 respectively. If R = (R,0,,1,) is a semiring and A = (A,0,,) an R-semimodule, we shall say that (A,0,) is the underlying (commutative) monoid of (A,0,,), and the map

 : RA  A, written as (r,a) = ra, (7.1) is the scalar multiplication of (A,0,,).

Example 7.1. Let (A,0,) be a commutative monoid. The set End(A) of monoid of A (that is, monoid homomorphisms A  A) has a semiring structure End(A) = (End(A),0,,1,) determined by

(f  g)(a) = f(a)  g(a) and (fg)(a) = f(g(a)) for all f, g  End(A) and a  A, (7.2) which implies that 0  End(A) is the zero map sending all elements of A to 0 of A, and 1  End(A) is the identity map of A. We omit the proof, which is a straightforward calculation. 

The next theorem will show the importance of this simple example. In order to formulate it, for given semiring R = (R,0,,1,) and commutative monoid (A,0,), consider the diagram

37 The set of all  The set of all maps from R maps RA  A to the set of all maps A  A

inclusion inclusion (7.3)

The set of all maps ' The set of all semiring  : RA  A making homomorphisms (A,0,,) an R  End(A)

R-semimodule

in which  is the canonical bijection defined by

()(r)(a) = (r,a), (7.4) for each map  : RA  A, each r  R and each a  A; and we are going to show that  induces ' displayed as the dotted arrow, which itself is a bijection. That is, we are going to prove:

Theorem 7.2. Let R = (R,0,,1,) is a semiring and A = (A,0,) a commutative monoid. The canonical map  of (7.3) induces a bijection between the set of maps  : RA  A making (A,0,,) an R-semimodule, and the set of semiring homomorphisms R  End(A).

Proof. We have to prove that a map  : RA  A makes (A,0,,) an R-semimodule if and only if the map  : R  End(A) defined by (r)(a) = (r,a) is a semiring homomorphism. In other words, writing (r,a) as ra, we have to show that

1a = a, r(sa) = (rs)a, r0 = 0 = 0a, r(a  b) = ra  rb, and (r  s)a = ra  sa, (7.5) for all r, s  R and a, b  A if and only if

(r)(0) = 0, (r)(a  b) = (r)(a)  (r)(b), (0) = 0, (r  s) = (r)  (s), (1) = 0, and (rs) = (r)(s), (7.6) also for all r, s  R and a, b  A. However, by the definition of , the equalities (7.6) express the same properties as those of (7.5), up to the order of equalities. 

8. The semiring ℕ of natural numbers

The structure ℕ = (ℕ,0,s) of natural numbers can be introduced as an initial object in the category C of triples (X,e,f), in which X is a set, and e and f are, respectively, a nullary and a unary operation on X; the morphisms of triples are defined as usually for -algebras (see Section I.11). That is, ℕ is a set, 0 an element in ℕ, and s : ℕ  ℕ a map, such that, for every triple (X,e,f) as above, there exists a unique map u : ℕ  X with u(0) = e and us = fu. Using this definition we can prove so-called :

38 Theorem 8.1. (a) s : ℕ  ℕ induces a bijection ℕ  ℕ\{0}.

(b) (Induction Principle) If M is a subset in ℕ with

0  M and nℕ (n  ℕ  s(n)  ℕ), (8.1) then M = ℕ.

Proof. (a): Consider a triple (ℕ  {e},e,f), in which e  ℕ and f is defined by

f(e) = 0 and f(n) = s(n) for each n  ℕ. (8.2)

The map v : ℕ  {e}  ℕ, defined by v(x) = f(x) for all x in ℕ  {e}, is obviously a morphism (ℕ  {e},e,f)  (ℕ,0,s) in the category C above, of triples. On the other hand, since (ℕ,0,s) is an initial object in C, there is a morphism

u : (ℕ,0,s)  (ℕ  {e},e,f) in C, with vu = 1ℕ.

Since v(e) = 0, it only remains to show that uv(n) = n for each n  ℕ. For, consider the map ℕ  ℕ  {e} defined by n  uv(n), and the inclusion map between the same sets: since both of them are obviously morphisms from (ℕ,0,s) to (ℕ  {e},e,f), they must coincide.

(b): By the assumption on M, we can form the object (M,0,f) in C, in which f(m) = s(m) for every m in M. The inclusion map i : M  ℕ is then obviously a morphism (M,0,f)  (ℕ,0,s) in C. Again, since (ℕ,0,s) is an initial object in C, there exists a morphism u : (ℕ,0,s)  (M,0,f) in C, and iu = 1ℕ. This makes i surjective, and so M = ℕ, as desired. 

After that, introducing addition and multiplication on ℕ as usually, we make a semiring ℕ = (ℕ,0,,1,), in which s(n) = n  1 for each n  ℕ; we omit the details since the semiring axioms are nothing but familiar laws of arithmetic here. Moreover, we have:

Theorem 8.2. The semiring ℕ = (ℕ,0,,1,) of natural numbers is the initial object in the category of semirings.

Proof. Let R = (R,0,,1,) be an arbitrary semiring. We can form the triple (R,0,f), in which f : R  R is defined by f(r) = r  1, and this uniquely determines a morphism u : (ℕ,0,s)  (R,0,f) in the category C considered above. According to the definition to such a morphism, we have:

u(0) = 0 and u(n  1) = u(n)  1, (8.3) for all n  ℕ, and since this implies u(1) = u(0  1) = u(0)  1 = 0  1 = 1, we can equivalently write

u(0) = 0, u(1) = 1, and u(n  1) = u(n)  u(1). (8.4)

Since every semiring homomorphism satisfies (8.4), it only remains to prove that

39 u(x  y) = u(x)  u(y) and u(xy) = u(x)u(y), (8.5) for all x, y  ℕ.

We shall use the Induction Principle in the form presented in Theorem 8.1(b). For any x  ℕ, put Mx = {y  ℕ  u(x  y) = u(x)  u(y)}. Then 0 is in Mx, and for y  Mx, we have

u(x  (y  1)) = u((x  y)  1)) (by the associativity of addition in ℕ) = u(x  y)  1 (by the second equality in (8.3)) = (u(x)  u(y))  1 (since y is in Mx) = u(x)  (u(y)  1) (by the associativity of addition in R) = u(x)  u(y  1) (by the second equality in (8.3)), which proves that y  1 is in Mx. By the Induction Principle, Mx = ℕ, and so the first equality in (8.5) holds for all x, y  ℕ. Next, put Mx' = {y  ℕ  u(xy) = u(x)u(y)}. Then again, 0 is in Mx', and for y  Mx', we have

u(x(y  1)) = u(xy  x) (since ℕ is a semiring) = u(xy)  u(x) (by the first equality in (8.5), which is already proved) = u(x)u(y)  u(x) (since y  Mx') = u(x)(u(y)  1) (since R is a semiring) = u(x)(u(y  1)) (by the second equality in (8.3)), which proves that y  1 is in Mx'. By the Induction Principle, Mx' = ℕ, and so the second equality in (8.5) holds for all x, y  ℕ. 

Let us compare this result with Theorem 7.2. By Theorem 8.2, for any commutative monoid A, there exist a unique semiring homomorphism ℕ  End(A), and on the other hand, by Theorem 7.2, to give such a homomorphism is the same as to make A an ℕ-semimodule. Therefore we have:

Corollary 8.3. For every a commutative monoid A = (A,0,), there exist a unique map  : RA  A making (A,0,,) an ℕ-semimodule. 

9. Number systems, ℤ, ℚ, ℝ, and ℂ as rings, and their modules

There are five most important classical number systems:

 ℕ, the system of natural numbers. It is the set of natural numbers (where we agreed to include 0) equipped with the familiar operations that make it a commutative semiring, as mentioned in the previous section.  ℤ, the system of . The familiar operations make it a commutative ring. Note that a commutative ring can be defined as a system (A,0,,,1,) in which (A,0,,1,) is a commutative semiring and (A,0,,) is a group (cf. I.16(k)-(l)).  The systems ℚ, ℝ, and ℂ of rational, real, and complex numbers respectively. The familiar operations make them fields; for the definition of a field see Section I.16(m).

40 Assuming all this to be well known, we will present ℤ, ℚ, ℝ, and ℂ as initial objects in certain categories. For the system of natural numbers this was done in two very ways, very different from each other in the previous section: as initial triple (ℕ,0,s) and as initial semiring (ℕ,0,,1,). In fact there many more ways to do this, for ℕ and for other number systems – but we shall make only one presentation for each of them.

9.1. Integers. Let C be the category of pairs (A,f), where A is an abelian group, and f is a monoid homomorphism from the additive monoid of natural numbers to A; a morphism  : (A',f ')  (A,f) in C is a group homomorphism  from A' to A with f ' = f. We are going to prove that the pair (ℤ,), where  : ℕ  ℤ is the inclusion map, is an initial object in C. For, we have to show that for every object (A,f) in C, there exists a unique group homomorphism  : ℤ  A with

(n) = f(n) for every natural number n.

Existence: We define  : ℤ  A by

(n) = f(n) and (n) = f(n) (9.1) for any natural number n, and we only need to show that

(z  t) = (z)  (t) (9.2) for every two integers z and t. Since f is a monoid homomorphism, and (n) = f(n) for every natural n, (9.2) certainly holds for natural z and t. After that, and using this fact, we calculate:

 For z and t both negative:

(z  t) = (((z)  (t))) = f((z)  (t)) (since (z)  (t) is natural and by (9.1)) = (f(z)  f(t)) (since f is a monoid homomorphism) = (f(z))  (f(z)) = ((z))  ((t)) (since (z) and (t) are natural and by (9.1)) = (z)  (t).

 For z natural, t negative, and z  t:

(z  t)  (z) = (((z  t)))  (z) = f((z  t))  f(z) (since (z  t) and z are natural and by (9.1)) = (f((z  t))  f(z)) = (f((z  t)  z)) (since f is a monoid homomorphism) = (f(t)) = ((((t))) (since (t) is natural and by (9.1)) = (t), and so (z  t) = (z)  (t).

Similarly the equality (9.2) can be shown also for all other cases, and so it holds for every two integers z and t, as desired.

Uniqueness: We need to prove that whenever a group homomorphism  : ℤ  A satisfies the first equality in (9.1), it should also satisfy the second one. Indeed, we have:

41

(n)  f(n) = (n)  (n) = (n  n) = (0) = 0, and so (n) = f(n), as desired.

9.2. Rational numbers. An element a of a ring A is said to be invertible if ab = 1 = ba for some b in A. We take C to be the category of pairs (A,f), where A is a commutative ring, and f is a ring homomorphism from the ring of integers to A, sending all non-zero integers to invertible elements in A; a morphism  : (A',f ')  (A,f) in C is a ring homomorphism  from A' to A with f ' = f. We are going to prove that the pair (ℚ,), where  : ℤ  ℚ is the inclusion map, is an initial object in C. For, we have to show that for every object (A,f) in C, there exists a unique ring homomorphism  : ℤ  A with

(z) = f(z) for every z.

Existence: We define  : ℚ  A by

(z/t) = f(z)(f(t))1, (9.3) for any integers z and t with non-zero t, and we need to show that

z/t = u/v  f(z)(f(t))1 = f(u)(f(v))1

(to show that (9.3) indeed defines a map  from ℚ to A), that

(z/t  u/v) = (z/t)  (u/v), ((z/t)(u/v)) = (z/t)(u/v), (1) = 1,

(to show that  is a ring homomorphism), and that  = f. We have: z/t = u/v  zv = ut  f(zv) = f(ut)  f(z)f(v) = f(u)f(t)  f(z)(f(t))1 = f(u)(f(v))1,

(z/t  u/v) = ((zv  ut)/(tv)) = f(zv  ut)(f(tv))1 = (f(zv)  f(ut))(f(tv))1 = f(zv)(f(tv))1  f(ut)(f(tv))1 = f(z)f(v)(f(v))1(f(t))1  f(u)f(t)(f(v))1(f(t))1 = f(z)(f(t))1  f(u)(f(v))1 = (z/t)  (u/v),

((z/t)(u/v)) = ((zu/tv)) = f(zu)(f(tv))1 = f(z)f(u)(f(t)(f(v))1 = f(z)(f(t)) 1f(u)(f(v))1 = (z/t)(u/v),

(1) = f(1)(f(1))1 = 1,

(z) = (z) = (z/1) = f(z)(f(1))1 = f(z).

Uniqueness: We need to show that whenever a ring homomorphism  : ℚ  A has (z) = f(z) for every integer z, it should satisfy (9.3). We have

42 (z/t)f(t) = (z/t)(t) = ((z/t)t) = (z), and so (z/t) = f(z)(f(t))1, as desired.

9.3. Real numbers. We shall need a notion of completeness different from the one introduced in Section 5: A linear order (X,) (see Definition I.7.1 and Remark I.7.2) is said to be complete, if for every non-empty subset S of X, we have

(xX sS x  s)  (S exists), (9.4) that is, if there exist an element x  X with x  s for all s  S, then there exist the largest x  X with this property. One also says: if S admits a lower bound, then it also admits the largest lower bound. Note that, similarly to Theorem 5.1, our requirement on (X,) is equivalent to the dual one, that is, instead of (9.4) we could equivalently require

(xX sS s  x)  (S exists), (9.5) for every non-empty subset S of X.

Here, assuming familiarity with the usual linear order on ℚ, we take C to be the category of pairs (C,f), where C is a complete linear order and f : ℚ  C a map that preserves all (existing) meets, that is, f(S) = f(S) for every subset S in ℚ that admits a meet in ℚ (with respect to the standard order in ℚ); a morphism  : (C ',f ')  (C,f) in C is a meet-preserving map  from C ' to C with f ' = f. We are going to prove that the pair (ℝ,), where  : ℚ  ℝ is the inclusion map, is an initial object in C. For, we have to prove that for every object (C,f) in C, there exists a unique meet-preserving map  : ℝ  C with

(x) = f(x) for every x.

Existence: We define  : ℝ  C by

(x) = {f(y)  x  y  ℚ}, for every x in ℝ, and we need to prove that  preserves meets (that exist), and that  = f. Let us begin with the second assertion. For each rational number x, f(x) belongs to the set {f(y)  x  y  ℚ}; moreover, since f preserving existing meets certainly preserves order, f(x) is the smallest element in {f(y)  x  y  ℚ}. Therefore, when x is rational, we have:

(x) = (x) = {f(y)  x  y  ℚ} = f(x), as desired. Now let us prove the first assertion. Preservation of (existing) meets by  means that, for every subset S of ℝ that has a lower bound in ℝ, we have

(S) = (S).

43 In order to prove this equality, we observe:

 If x  x', then the set {f(y)  x  y  ℚ} contains the set {f(y)  x'  y  ℚ}, and so (x) = {f(y)  x  y  ℚ}  {f(y)  x'  y  ℚ} = (x'). That is, the map  preserves order.  Since  preserves order, we have (S)  (s), for every is in S, and so (S)  (S). It remains to prove (S)  (S).  Since (S) = {f(y)  S  y  ℚ}, to prove (S)  (S) is to prove that (S) is a lower bound of the set {f(y)  S  y  ℚ}.

That is, we have to prove that (S)  f(y) whenever S  y  ℚ. If S is strictly less than y, then s  y for some s  S, and then (s)  (y) = f(y), which immediately gives (S)  f(y). Therefore we can assume that S = y, and, in particular, that S is rational. Next, we observe:

 Let us say that subsets A and B of an ordered set P are equivalent if

aAbB b  p and bBaA a  b.

Then obviously, if A and B are equivalent, then A has meet if and only if B has, and if this is the case, then A = B. Note also that if u : P  Q is an order-preserving map, and A and B are equivalent to each other, then so are u(A) and u(B).  When S is rational, the sets S and T = {t  ℚ  sS s  t} are equivalent.

And, using these observations and assuming S = y, we conclude: (S) = (T) = f(T) = f(T) = f(S) = f(y), which completes the proof.

Uniqueness follows from the following three facts:

  preserves (existing) meets;   restricted to ℚ coincides with f;  every can be presented as meet of a set consisting of rational numbers.

9.4. Complex numbers. Now we take C to be the category of triples (A,,f), where A is a commutative ring (with 1),  is an element in A with 2 = 1, and f is a ring homomorphism from the ring of real numbers to A; a morphism  : (A',',f ')  (A,,f) in C is a ring homomorphism  from A' to A with (') =  and f ' = f. We are going to prove that the pair (ℂ,i,), where  : ℝ  ℂ is the inclusion map, is an initial object in C. For, we have to show that for every object (A,,f) in C, there exists a unique ring homomorphism  : ℂ  A with

(i) =  and (x) = f(x) for every real number x. (9.6)

Existence: We define  : ℂ  A by

(a  bi) = f(a)  f(b); (9.7)

44 then checking that  is a ring homomorphism is a straightforward calculation, and (9.6) obviously holds.

Uniqueness: If  is a ring homomorphism satisfying (9.6), then

(a  bi) = (a)  (bi) = (a)  (b)(i) = f(a)  f(b), that is,  must satisfy (9.7), which determines it uniquely.

9.5. Modules. As I.16(p) says, for a ring R = (R,0,,,1,), an R-module, or a module over R, is the same as a semimodule over (R,0,,1,). Note, however, that:

(a) If A = (A,0,,) is an R-module, then the monoid (A,0,) is a group (that is it admits a group structure (A,0,,) with the same (A,0,) and) with a = (1)a for each a  A. Indeed, we have

a  (1)a = 1a  (1)a = (1  (1))a = 0a = 0.

On the other hand, when a monoid (commutative or not) admits a group structure, such a structure is unique, since, using the additive notation again, we have

(a  b = 0 = c  a)  (b = b  a  c = c).

That is, the formula a = (1)a above gives the unique way to make (A,0,) a group.

(b) Defining an R-module, we could actually omit three requirements from the definition of a semimodule, since they can be deduced from others. They are the identities a  b = b  a, 0a = 0, and r0 = 0 (for a, b  A and r  R). Indeed, we have:

a  b = (a)  a  a  b  b  (b) = (a)  (1  1)a  (1  1)b  (b) = (a)  (1  1)(a  b)  (b) = (a)  a  b  a  b  (b) = b  a,

0a = 0a  0a  ((0a)) = (0  0)a  ((0a)) = 0a  ((0a)) = 0,

r0 = r0  r0  ((r0)) = r(0  0)  ((r0)) = r0  ((r0)) = 0.

(c) For every r  R and a  A we obviously have

r(a) = (ra) = (r)a, (9.8) and so we shall write simply ra for each of these expressions. We shall also write x  y instead of x  (y) when x and y are either both in R or both in A, and we have

(r  s)a = ra  sa and r(a  b) = ra  rb, (9.9) for all r, s  R and a, b  A.

(d) Using Theorem 8.2, and the initiality of (ℤ,) established in 9.1, it is easy to show that the ring ℤ of integers is the initial object in the . Then, by

45 observing that when a commutative monoid (A,0,) is a group structure, the semiring End(A) becomes a ring, we conclude that every abelian group admits a unique ℤ-module structure. We should only note that this conclusion uses that obvious fact that every semiring homomorphism between rings is a ring homomorphism.

(e) Using (d) and the initiality of (ℚ,) established in 9.2, it is easy to show any abelian group A admits at most one ℚ-module (=ℚ-vector space) structure, and that it admits it if and only if, for every nonzero n  ℕ, the map A  A defined by a  na is bijective (which will make it an invertible element in End(A)).

Finally, we shall not describe abelian groups that admit ℝ- or ℂ-vector space structure. Let us only mention that the homomorphisms ℚ  ℝ  ℂ allow considering any ℂ-vector space as an ℝ-vector space, and considering any ℝ-vector space as a ℚ-vector space.

10. Pointed categories

Definition 10.1. A pointed category is a category C equipped with a family

(0A,B)(A,B)C0C0 of morphisms in C indexed by pairs of objects in C, with 0A,B  homC(A,B) and g0A,Bf = 0X,Y for every f : X  A and g : B  Y. 

Example 10.2. Let C be a full subcategory (see Example I.8.5) of a category of the form -Alg, as defined in Section I.11. Then C is pointed whenever every -algebra that is in C has a unique one-element subalgebra. Out of the examples of classes of algebras given in Section I.16 this is the case for the items (b), (e)-(i), (o)-(r), (t), (u), and for “rings without 1” mentioned in (k). 

Theorem 10.3. Any category admits at most one structure of a pointed category. 

Proof. Let (0A,B)(A,B)C0C0 and (0'A,B)(A,B)C0C0 be two such structures on a category C. then 0'A,B = 0'A,B0A,A = 0A,B, where the first equality follows from the fact that

(0'A,B)(A,B)C0C0 determines a pointed category structure on C, and the second one follows from the fact that (0A,B)(A,B)C0C0 does. 

Theorem 10.4. Let C be a category that admits either initial or terminal object. Then the following conditions are equivalent:

(a) C is pointed (i.e. it admits a pointed category structure, which is unique by Theorem 10.3);

(b) 0 = 1 in C (that is, C has an object that is initial and terminal at the same time);

(c) C has 0 and 1 with homC(1,0)  .

Proof. (a)(c) is trivial. (c)(b): Having a morphism 1  0 makes 0  1 since the composites 0  1  0 and 1  0  1 must be identity morphisms. (b)(a): For arbitrary objects A and B in C, just define 0A,B as the composite A  1 = 0  B. To

46 show the equality g0A,Bf = 0X,Y of Definition 10.1 follows from the commutativity of the diagram

f 0A,B g X A B Y

1  0 where the unlabeled arrows are the suitable uniquely determined morphisms into 1 or from 0. 

11. Products and coproducts

Definition 11.1. Let C be a category and (Ai)iI be a family of objects in C. Then:

(a) A cone over (Ai)iI is a family of the form (fi : C  Ai)iI of morphisms in C. A morphism from a cone (fi : C  Ai)iI to a cone (gi : D  Ai)iI is a morphism h : C  D with gih = fi for each i  I.

(b) The (cartesian) product

Ai = (Ai,(i : Ai  Ai)iI) = (i : Ai  Ai)iI (11.1) iI iI iI iI of the family (Ai)iI is defined as a (the) terminal object in the category of cones over the family (Ai)iI; the morphisms i involved are called product projections. We will also write

n Ai = A1…An i=1 when the family is presented as a sequence A1, …, An, etc. 

That is, in contrast to the usual definition of cartesian product, the categorical definition presents it not just as an object that is product, but as a cone, that is, as an object equipped with morphisms to all members of the given family. Furthermore, being defined as a terminal object, it is unique only up to isomorphism of cones. This easily gives:

Theorem 11.2. Let (gi : D  Ai)iI be a product of the family (Ai)iI and (fi : C  Ai)iI be another cone over the same family. Then following conditions are equivalent:

(a) (fi : C  Ai)iI is a product of the same family (Ai)iI;

(b) the unique morphism h : C  D, with gih = fi for each i  I, is an isomorphism;

(c) there exists an isomorphism h : C  D, with gih = fi for each i  I. 

47 Thinking of isomorphic objects informally as “essentially equal”, this suggests the following convention in fact already used in the formulation of Definition 11.1(b):

Convention 11.3. Whenever a cone (gi : D  Ai)iI is terminal, that is, has the property:

for every cone (fi : C  Ai)iI, over the same family, there exists a unique morphism h : C  D with (11.2) gih = fi for each i  I, we shall say that (gi : D  Ai)iI is the product of the family (Ai)iI, and write D = Ai.  iI

Example 11.4. Let C = -Alg be the category of all -algebras and their homomorphisms, as defined in Section I.11. Then the cartesian product

Ai, defined as in Section I.13, and equipped with the family (i : Ai  Ai)iI iI iI of (ordinary) projections defined by i((ai)iI) = ai, is the product of the family (Ai)iI in the sense of Definition 11.1(b). Indeed, given a cone (fi : C  Ai)iI, to give a morphism

h : C  Ai with ih = fi for each i  I, iI is to give

h : C  Ai with h(c)i = fi(c) for each c  C and i  I, iI or, equivalently, is to give

h : C  Ai with h(c) = (fi(c))iI for each c  C. iI

And, since requiring h(c) = (fi(c))iI for each c  C actually defines h as a map, all we need to check is that h is a homomorphism of -algebras. For every n = 0, 1, 2, …, for every  in n, and for every c1, …, cn in C, we have

h((c1,…,cn)) = (fi((c1,…,cn)))iI (by the definition of h) = ((fi(c1),…,fi(cn)))iI (since each fi is a homomorphism of -algebras) = ((fi(c1))iI,…,(fi(cn))iI) (by Definition I.13.1) = (h(c1),…,h(cn)), as desired. 

Remark 11.5. In particular, the construction above can be used in the case  = , that is, for the . In fact it would be more natural to begin with the category of sets, and then simply say that the products of algebras are constructed as for sets, but with suitable algebraic structure. 

48 Coproducts are defined dually to products, that is, by reversing all arrows in Definition 11.1:

Definition 11.6. Let C be a category and (Ai)iI be a family of objects in C. Then:

(a) A cocone over (Ai)iI is a family of the form (fi : Ai  C)iI of morphisms in C. A morphism from a cocone (fi : Ai  C)iI to a cocone (gi : Ai  D)iI is a morphism h : C  D with gi = hfi for each i  I.

(b) The

Ai = (Ai,(i : Ai  Ai)iI) = (i : Ai  Ai)iI (11.3) iI iI iI iI of the family (Ai)iI is defined as a (the) initial object in the category of cocones over the family (Ai)iI; the morphisms i involved are called coproduct injections. We will also write

n Ai = A1  …  An i=1 when the family is presented as a sequence A1, …, An, etc. 

We shall use convention similar to Convention 11.3.

Example 11.7. In the category of sets coproducts are disjoint unions. More precisely, we can put

Ai = {i}Ai with i : Ai  Ai defined by i(a) = (i,a). (11.4) iI iI iI

Indeed, given a cocone (fi : Ai  C)iI, to give a map

h : Ai  C with hi = fi for each i  I, iI is to give

h : Ai  C with h(i,a) = fi(a) for each i  I and a  Ai, iI which simply defines h. 

Example 11.8. Let R be a semiring, and C the category of R-semimodules. Then we can put

Ai = {(ai)iI  Ai  {i  I  ai  0} is finite} with the R-semimodule (11.5) iI iI structure making Ai a R-subsemimodule of Ai, and with i : Ai  Ai iI iI defined by

49 a, if i = j, (i(a))j = (11.6) 0, if i  j.

To prove this we need to prove that, given a cocone (fi : Ai  C)iI, there exists a unique R-semimodule homomorphism

h : Ai  C with hi = fi for each i  I. (11.7) iI

For, first we observe that, for each (ai)iI  Ai, we have iI

(ai)iI = i(ai), (11.8) iI where the possibly infinite sum as the sum of the non-zero summands involved; this formula easily follows from (11.6). Next, if h is an R-semimodule homomorphism satisfying (11.7), then using (11.8) we obtain

h((ai)iI) = h(i(ai)) = hi(ai) = fi(ai), iI iI iI and so whenever h exists, it is uniquely determined and must be defined by

h((ai)iI) = fi(ai). (11.9) iI

It remains to show that h, defined by (11.9), is an R-semimodule homomorphism with hi = fi for each i  I. We have:

h((ai)iI  (bi)iI) = h((ai  bi)iI) (by the definition of addition in Ai) iI = fi(ai  bi) (by (11.9)) iI = (fi(ai)  fi(bi)) (since each fi is an R-semimodule homomorphism) iI = fi(ai)  fi(bi) (since the addition in C is associative and commutative) iI iI = h((ai)iI)  h((bi)iI) (by (11.9)),

h(r(ai)iI) = h((rai)iI) (by the definition of scalar multiplication in Ai) iI = fi(rai) (by (11.9)) iI = rfi(ai) (since each fi is an R-semimodule homomorphism) iI = rfi(ai) (by the suitable distributivity) iI = r(h((ai)iI)) (by (11.9)),

hi(a) = fj((i(a))j) (by (11.9)) jI = fi(ai) (by (11.6) and since fj(0) = 0 for each j),

50 as desired. 

12. Direct sums

As the Examples 11.4 and 11.8 show, if a family (Ai)iI of R-semimodules has the index set I finite, we have

Ai = Ai, (12.1) iI iI as semimodules, that is, if we ignore the product projections and the coproduct injections. On the other hand, the product projections and the coproduct injections chosen exactly as in Examples 11.4 and 11.8 respectively, satisfy the equalities

1, if i = j, ii = 0, if i  j, (12.2) ii = 1, iI where 1 and 0 denote suitable identity and zero morphisms respectively. This is a general phenomenon, which we will describe below, for simplicity, in the case of a two-element index set.

Definition 12.1. A linear category is a category C equipped with (additive) commutative monoid structures on all homC(A,B) (A, B  C0), such that for every f : X  A and g : B  Y in C, the map

homC(A,B)  homC(X,Y), defined by u  guf is a monoid homomorphism. 

Remark 12.2. Every linear category is obviously pointed with 0A,B  homC(A,B) defined as the zero element of the additive monoid homC(A,B). 

Definition 12.3. Let C be a linear category. A diagram

1 2 A AB B (12.3) 1 2 in C is said to be a direct sum diagram, if the equalities (12.2) hold, that is, if

11 = 1A, 22 = 1B, 12 = 0B,A, 21 = 0A,B, 11  22 = 1C.  (12.4)

Theorem 12.4. Suppose a diagram of the form (12.3) in a linear category satisfies only the first four equalities of (12.4). For such a diagram the following conditions are equivalent:

(a) it is a direct sum diagram, that is, the fifth equality of (12.4) also holds;

51

(b) the pair (1,2) makes AB the product of A and B (that is, of the family, whose members are A and B);

(c) the pair (1,2) makes AB the coproduct of A and B.

Proof. The implications (a)(b) and (a)(c) are dual to each other as well as the implications (b)(a) and (c)(a); that is, having proved, say, (a)(b) and (b)(a), one can transform the arguments into proofs of (a)(c) and (c)(a) simply reversing the arrows. We shall therefore prove only (a)(b) and (b)(a).

(a)(b): Assuming that (12.3) is a direct sum diagram, we have to prove that given arbitrary two morphisms f : C  A and g : C  B with the same domain, there exists a unique morphism h : C  AB with 1h = f and 2h = g.

Existence: We take h = 1f  2g, and then

1h = 1(1f  2g) = 11f  12g = 1Af  0B,Ag = f and similarly 2h = g.

Uniqueness: If 1h = f and 2h = g, then

1f  2g = 11h  22h = (11  22)h = 1Ch = h.

(b)(a): Assuming that the pair (1,2) forms a product diagram, we have to prove the fifth equality of (12.4). This simply means to prove

1(11  22) = 1 and 2(11  22) = 2, which is a straightforward calculation: 1(11  22) = 111  122 = 1A1  0B,A2 = 1 and similarly for 2. 

Example 12.5. For any semiring R, the category C of R-semimodules is, of course linear. The additive monoid structure on each homC(A,B) is given by

(f  g)(a) = f(a)  g(a), as it was done in a special case in Example 7.1. For this category the direct sum diagram (12.3) can be described as

AB = AB, 1(a,b) = a, 2(a,b) = b, 1(a) = (a,0), 2(b) = (0,b).  (12.5)

13. Free algebras and free semimodules

Let C be as in Example 10.2, that is, a full subcategory (see Example I.8.5) of a category of the form -Alg, as defined in Section I.11. The objects in C will be called C-algebras.

Definition 13.1. Let X be a set, and C[X] the category of pairs (A,f), in which A is a C-algebra and f a map from X to (the underlying set of) A; a morphism

52 h : (A,f)  (B,g) in C[X] is a homomorphism h : A  B with hf = g. A (the) free C-algebra on X is an (the) initial object in C[X]. 

Remark 13.2. As follows from this definition, the free C-algebra on the empty set is nothing but the initial object in C – or, to be absolutely precise, it is the pair

(initial object in C, empty map into it).

On the other hand, the category C[X] can itself be considered as a full subcategory of the category of [X]-algebras, where [X] is defined by

[X]0 is the disjoint union of 0 and X, and [X]n = n for n = 1, 2, …

Therefore changing  allows considering any as the free algebra on the empty set. 

Example 13.3. Let R be a semiring and C the category of R-semimodules. Then the free C-algebra (A,f) on a set X, called the free R-semimodule on X, can be constructed as follows:

 A is the set R(X) of all maps u : X  R such that the set {x  X  u(x)  0} is finite. We could equivalently say of course, that it is the set of all families (ux)xX of elements in R such that the set {x  X  u(x)  0} is finite, which would be more convenient in order to describe the relationship with coproducts of semimodules described in Example 11.8. But using the language of maps is more convenient here.  The R-semimodule structure on A is defined accordingly; that is

(u  v)(x) = u(x)  v(x) and (ru)(x) = r(u(x)) (13.1)

for u and v in A, x in X, and r in R.  The map f : X  A is defined by

1, if x = y, f(x)(y) = (13.2) 0, if x  y.

To prove this we need to prove that, given an object (B,g) in C[X], there exists a unique R-semimodule homomorphism

h : R(X)  B with hf = g. (13.3)

For, first we observe that, for each u  R(X), we have

u = u(x)f(x); (13.4) xX indeed, for any y  X, we have

(u(x)f(x))(y) = u(x)(f(x)(y)) (by the second equality in (13.1) xX xX

53 = u(y) (by (13.2)).

Next, if h is an R-semimodule homomorphism satisfying (13.3), then using (13.4) we obtain

h(u) = h(u(x)f(x)) = u(x)hf(x) = u(x)g(x), xX xX xX and so whenever h exists, it is uniquely determined and must be defined by

h(u) = u(x)g(x). (13.5) xX

It remains to show that h, defined by (13.5), is an R-semimodule homomorphism with hf = g. We have:

h(u  v) = ((u  v)(x))g(x) (by (13.5)) xX = (u(x)  v(x))g(x) (by the first equality in (13.1)) xX = (u(x)g(x)  v(x)g(x)) (by the suitable distributivity) xX = u(x)g(x)  u(x)g(x) (since the addition in C is associative and commutative) xX xX = h(u)  h(v) (by (13.5)),

h(ru) = (ru)(x)g(x) ((13.5)) xX = r(u(x))g(x) (by the second equality in (13.1)) xX = r(u(x)g(x)) (by the suitable distributivity) xX = r(h(u)) (by (13.5)),

hf(y) = (f(x)(y))g(x) (by (13.5)) xX = g(y) (by (13.2) and since 0g(x) = 0 for each x), as desired. 

Remark 13.4. Obvious similarity between the proofs in Examples 11.8 and 13.3 can be explained by the fact that to construct the free C-algebra on X is the same as to construct the X-indexed coproduct of C-algebras free on one-element subsets on X. 

Remark 13.5. Consider the special case of R = {0,1} with 1  1 = 1. In this case R-semimodules are nothing but semilattices, since:

 for every R-semimodule A and every a  A, we have a  a = 1a  1a = (1  1)a = 1a = a;  conversely, if A is a semilattice, that is, an idempotent commutative monoid, then 1  1 = 1 holding in A also holds in the semiring End(A); this easily implies that sending 0 to 0 and 1 to 1 determines a (unique) semiring homomorphism R  End(A), hence making A an R-semimodule.

54 In this case the free R-semimodule on a set X can be identified with the semilattice Pfin(X) = (Pfin(X),,) of finite subsets in X. Under this identification a map u : X  {0,1} in R(X) corresponds to the finite subset u1(1) of X, and obviously the (X) addition operation in R corresponds to the union operation in Pfin(X). 

14. Vector spaces

In this section we will recall Zorn Lemma and use it to prove that every vector space is free. In order to formulate Zorn Lemma we need:

Definition 14.1. A subset S of an ordered set P is said to be:

(a) bounded, if there exists p  P with s  p for every s  S;

(b) a chain, if the order of P induces a linear order on S, that is, if for every s, s'  S, either s  s' or s'  s in P. 

Theorem 14.2 (Zorn Lemma). Every ordered set, in which every chain is bounded, has a maximal element. 

Let us also recall that, depending on axioms of set theory we are using, Zorn Lemma can either be put as one of axioms, or deduced from others; under certain “easy” axioms it is equivalent to the so-called Axiom of Choice.

In the rest of this section K denotes a fixed field and V a K-vector space. For any set (X) X, we define the canonical map X : X  K by (13.2), that is, by

1, if x = y, X(x)(y) = 0, if x  y.

(X) Recall from the previous section that this makes (K ,X) free, in the sense that for every map g : X  V there exists a unique linear map (that is, a morphism of K-vector (X) spaces) h : K  V with hX = g; we shall briefly call h the linear map induced by g. This map h can be explicitly defined by (13.5).

Definition 14.2. (a) A map g : X  V is said to be linearly independent if the induced linear map h : K(X)  V is injective.

(b) A subset S of V is said to be linearly independent if so is the inclusion map S  V. 

Since a linear map is injective if and only if it has a trivial kernel (see Theorem I.17.11), formula (13.5) tells us that g : X  V is linearly independent if and only if, for any u  K(X), we have

u(x)g(x) = 0  xX u(x) = 0. (14.1) xX

In particular, a subset S of V is linearly independent if and only if, for any u  K(S), we have

55

u(s)s = 0  sS u(s) = 0. (14.2) sS

Both (14.1) and (14.2) (required for u  K(X) and for u  K(S), respectively) can be called classical definitions of linear independence. Another classical definition is that of a basis: one usually says that a subset S of V is a basis of V if it is linearly independent and generates V. In the situation 14.2(a), g(X) generates V if and only if h : K(X)  V is surjective. However, a linear map is surjective and injective at the same time if and only if it is an isomorphism. Therefore a subset S of V is a basis of V if and only if the pair

(S, inclusion map S  V) is a free K-vector space on S (which is nothing but another name for a free K-semimodule on S). Therefore to say that every K-vector space is free is to say that every K-vector space has a basis, and, again, to prove this fact is the purpose of this section.

Remark 14.4. It is easy to see that:

(a) the empty map and the empty set are always linearly independent;

(b) the vector space {0} has a basis, which is the empty set;

(c) when X has only one element x, g : X  V is linearly independent if and only if g(x)  0; in particular a one-element subset set {s} of V is linearly independent if and only if s  0. 

Lemma 14.5. If S is a maximal linearly independent subset in V, then V is generated by S.

Proof. Let x be an element in V that is not in the set S, which we can assume non- empty by Remark 14.4. Then S{x} is not linearly independent, and so there exist a map u : S{x}  K, for which the set Y = {y  S{x} u(y)  0} is finite and non- empty and

u(y)y = 0. yY

Since S is linearly independent, u(x)  0; indeed, u(x) = 0 would imply

u(s)s = u(y)y = 0, sS yY and so make the restriction of u on S a map whose existence contradicts to the linear independence of S. Since u(x)  0, u(x) is an invertible element in K, and we can write

x = (u(x))1u(x)x = (u(x))1(u(x)x  u(s)s  u(s)s) sS sS

= (u(x))1(u(y)y  u(s)s) = (u(x))1(u(s)s) = (u(x))1u(s)s, yY sS sS sS which shows that x belongs to the subspace of V generated by S. 

56 Theorem 14.6. Every vector space has a basis.

Proof. Using the notation above, for a K-vector space V, let S be the set of all linearly independent subsets of V. Using Zorn Lemma and Lemma 14.5, all we need to show is that every chain in S is bounded. We will show more, namely, that if S' is a chain in S, then its union S' is linearly independent (that is, is in S). For, we have to show that, for u  K(S') with

u(s)s = 0, sS the finite set X = {x  S'  u(x)  0} is actually empty. Since X is a finite subset of S' and S' is a chain, X is included in some S  S. Therefore X = {x  S  u(x)  0}, and

u(s)s = u(s)s = 0. sS sS

Since S is linearly independent, using the restriction of u on S, we conclude that X is empty. 

Remark 14.7. (a) Theorem 14.6 confirms that every vector space is free, as desired (see the discussion above Remark 14.4).

(b) When V is finitely generated, the proof of Theorem 14.6 can avoid Zorn Lemma by considering any minimal generating subset S of V, which obviously exists for a finitely generated V. Indeed, it is easy to show that the minimality of S implies its linear independence. 

57