0% found this document useful (0 votes)
20 views254 pages

Andrzej Trybulec

Formalized Mathematics 1 -1

Uploaded by

fuad.agaev
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
20 views254 pages

Andrzej Trybulec

Formalized Mathematics 1 -1

Uploaded by

fuad.agaev
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 254

Contents

Preface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5

Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7

Tarski Grothendieck Set Theory


By Andrzej Trybulec . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9

Built-in Concepts
By Andrzej Trybulec . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13

Boolean Properties of Sets


By Zinaida Trybulec and Halina Świeczkowska . . . . . . . . . . . 17

Enumerated Sets
By Andrzej Trybulec . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25

Basic Properties of Real Numbers


By Krzysztof Hryniewiecki . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35

The Fundamental Properties of Natural Numbers


By Grzegorz Bancerek . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41

Some Basic Properties of Sets


By Czeslaw Byliński . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47

Functions and Their Basic Properties


By Czeslaw Byliński . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55

Properties of Subsets
By Zinaida Trybulec . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 67

Relations and Their Basic Properties


By Edmund Woronowicz . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 73

1
2 CONTENTS

Properties of Binary Relations


By Edmund Woronowicz and Anna Zalewska . . . . . . . . . . . . . . . 85

The Ordinal Numbers


By Grzegorz Bancerek . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 91

Tuples, Projections and Cartesian Products


By Andrzej Trybulec . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 97

Segments of Natural Numbers and Finite Sequences


By Grzegorz Bancerek and Krzysztof Hryniewiecki . . . . 107

Domains and Their Cartesian Products


By Andrzej Trybulec . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 115

The Well Ordering Relations


By Grzegorz Bancerek . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 123

A Model of ZF Set Theory Language


By Grzegorz Bancerek . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 131

Families of Sets
By Beata Padlewska . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 147

Functions from a Set to a Set


By Czeslaw Byliński . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 153

Finite Sets
By Agata Darmochwal . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 165

Graphs of Functions.
By Czeslaw Byliński . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 169

Binary Operations
By Czeslaw Byliński . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 175

Relations Defined on Sets


By Edmund Woronowicz . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 181

Boolean Domains
By Andrzej Trybulec and Agata Darmochwal . . . . . . . . . . . . . . 187

Models and Satisfiability


By Grzegorz Bancerek . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 191
CONTENTS 3

The Contraction Lemma


By Grzegorz Bancerek . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 201

Axioms of Incidence
By Wojciech A. Trybulec . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 205

Introduction to Lattice Theory


By Stanislaw Żukowski . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 215

Topological Spaces and Continuous Functions


By Beata Padlewska and Agata Darmochwal . . . . . . . . . . . . . . . 223

Subsets of Topological Spaces


By Miroslaw Wysocki and Agata Darmochwal . . . . . . . . . . . . . 231

Connected Spaces
By Beata Padlewska . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 239

Basic Functions and Operations on Functions


By Czeslaw Byliński . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 245
4
Preface

In recent years, several projects have aimed at providing computer assistance for do-
ing mathematics. The project discussed here is called Mizar and concerns computer
oriented formalization of mathematics, begun in 1973. The author of the Mizar
language is Prof.Andrzej Trybulec (Warsaw University), who is also the leader of the
group which prepared the majority of implementations. The project original goal was to
design and implement a software environment to assist the process of preparing math-
ematical papers: the human writes mathematical texts and the machine verifies their
correctness.

Université Catholique de Louvain and Foundation Philippe le Hodey (both of Bel-


gium) has been conducting research related to the applications of the Mizar system since
1984. This research has involved an international group of mathematicians who first met
at the Mizar Summer Workshop in Louvain-la-Neuve (Belgium) in 1985. Of these, the
Polish group is the most active. These researchers cooperate within the framework of
the Mizar Users Group (MizUG).

The papers published in the consecutive issues of ”Formalized Mathematics (a com-


puter assisted approach)” constitute the Main Mizar Library (MML). The power of the
Mizar system lies in the automatic processing of cross–references among articles. This
is done by the continuous actualization of MML. Before the theorems and definitions
are included into the MML, they must be proved valid and correct. MML forms the
basis of a Knowledge Management System for Mathematics supplied with Mizar articles.
MML together with PC MIZAR are the systems for collecting, formalizing and verifying
mathematical knowledge. The latest, the most advanced version of Mizar is PC MIZAR
which together with MML runs on IBM PC under DOS 3.xx (implemented in Poland
under the direction of Prof.A.Trybulec).

In the current issue of ”Formalized Mathematics...” all the papers appear in chrono-
logical order, since they form the very beginning of MML. They concern both very general
and very specialized, narrow subjects. In the future we intend to classify the papers into
groups according to the mathematical domains i.e. foundations of mathematics, geome-
try, etc.

The MizTEX system, used for the automatic editing of this publication is constantly
being developed.

5
6

Finally, I would like to add that for MizUG members we also publish the technical
report ”Main Mizar Library”, containing the list of summaries of the articles; names of
the authors, titles of the articles and names of files; publicity – ranking of theorems and
articles as well as the list of contents of the articles so far published in the ”Formalized
Mathematics...”.

Roman Matuszewski
Introduction

The Mizar project started many years ago and, as it developed, the emphasis on its
different applications varied. It is therefore worthwhile to take this opportunity to recall
that one of the main applications originally considered was using Mizar articles as source
texts for mathematical publications. Of course, none of the following papers, or, rather,
their abstracts, fulfils that expectation. Neverthelless, they let us see how close or how
far are we still from our aim.In order to explain what exactly is published here it is
necessary to at least give an outline of the project itself.
The Mizar language is a strongly standarized mathematial language, or, if one prefers,
an extensively extended formalized language, for writing mathematical papers. Its struc-
ture allows for using a database; the final goal of the project is to provide a knowledge
management system for mathematics. Thus it is possible to write mathematical papers in
Mizar. They are usually 1000 - 2000 line texts corresponding to a short six- to nine-page
publication or to one chapter of a textbook.
An article consists of two parts. The first, usually very short, is the description of the
environment. It contains a list of publications where the notions used in the paper were
introduced or where the theorems we refer to were proved, and other similar information.
The second part is the text proper, where we define new notions, prove the correctness
of the proposed definitions and where we prove new theorems. From the construction of
the article follows that to write a new one we have to have access to the Mizar library
of papers we can refer to. Obviously, to write the first papers we have to start with
some axiomatics. The papers presented below make use of Main Mizar Library (MML),
which was first created at the beginning of 1989 owing to the financial help obtained
from the Ministry of National Education of the Republic Poland (grant RPBP III.24).
The axiomatic foundation of this library is the Tarski-Grothendieck set theory which is
quite a strong theory quaranteeing the existence of universal classes. To enable the Mizar
processor to perform natural number computations, several additional axioms were also
introduced, namely the axiomatics of strong real number arithmetic. So far the Main
Mizar Library comprises of about 80 papers but their number is growing fast.
However, to verify the correctness of a paper the PC Mizar system used to build the
library refers not to the library direct, but to a database automatically created from the
papers there included. The data introduced into the database from a paper pass through
an intermediate stage where the abstract of the paper is created. The abstractor program
removes from the paper all data which are not stored in the database, i.e. justification
of theorems, lemmas and private object definitions.
The evolution of the library requires writing many papers containing well-known
theorems with uninteresting proofs. It seemed to us, therefore, that publication of whole
papers is not justified. To tell the truth, only some of the authors were inclined to devote

7
8

their time to the systematic development of the database; others agreed to write down
only that part of mathematical folklore which makes work on an ambitious paper possible.
Some of the papers submitted to the library concern new, unpublished mathematical
results; thus the level of the papers varies.
As we prepared this collection, we wondered whether it should not be restricted
to chosen, more interesting papers. There were doubts concerning the publication of
such monotonous articles as, for example [2]. Actually, this paper was written mainly
because, while justifying some trivial facts, the checker (system module checking inference
correctness) exceeded certain quantitative limitations and we wanted to show how this
can be overcome. Those who write in Mizar may have found the proofs in this paper
interesting, they were removed, however, when the abstract was created.
Still, there are good reasons for publishing all papers. First, in this way we obtain a
true picture of what the library looks like. It does not seem fair to remove trivial papers,
even though the reader is warned that it’s been done. Second, this publication will serve
to write new papers, and Mizar authors need the information what has been proved and
where. This actually was our original aim, similar to [1].
The abstracts of Mizar papers do not look as well as the present publication would
lead to think, if only because they are ASCII files. These abstracts were automatically
converted into source files of the TEX language. Some fragments were automatically
translated into English, or to be precise, into a language which reminds English a little
and others were left in original Mizar form with slight modifications, for example the
keywords are in bold type. The obtained texts, with the exception of abstracts containing
axiomatics, were not post-edited. The programs used were implemented by the following
group: Grzegorz Bancerek, Czeslaw Byliński, Wojciech Leończuk, Krzysztof Prażmowski,
Michal Muzalewski and the author. They include a program in Turbo Pascal converting
Mizar into TEX and a special TEX format (a set of TEX macros).

Andrzej Trybulec

References
[1] Piotr Rudnicki and Andrzej Trybulec. A Collection of TEXed Mizar Abstracts. Tech-
nical Report University of Alberta, 1989.

[2] Andrzej Trybulec. Enumerated sets. Formalized Mathematics, 1, 1990.


FORMALIZED MATHEMATICS
Number 1, January 1990
Université Catholique de Louvain

Tarski Grothendieck Set Theory

Andrzej Trybulec1
Warsaw University
Bialystok

Summary. This is the first part of the axiomatics of the Mizar system. It
includes the axioms of the Tarski Grothendieck set theory. They are: the axiom
stating that everything is a set, the extensionality axiom, the definitional axiom of
the singleton, the definitional axiom of the pair, the definitional axiom of the union
of a family of sets, the definitional axiom of the boolean (the power set) of a set, the
regularity axiom, the definitional axiom of the ordered pair, the Tarski’s axiom A
introduced in [2] (see also [1]), and the Frænkel scheme. Also, the definition of
equinumerosity is introduced.

For simplicity we adopt the following convention: x, y, z, u will denote objects of the
type Any; N , M , X, Y , Z will denote objects of the type set. Next we state two
axioms:

(1) x is set ,

(2) (for x holds x ∈ X iff x ∈ Y ) implies X = Y.

We now introduce two functors. Let us consider y. The functor

{y},

with values of the type set, is defined by

x ∈ it iff x = y.

Let us consider z. The functor


{y, z},

with values of the type set, is defined by

x ∈ it iff x = y or x = z.
1
Supported by RPBP.III-24.B1.

cf 1990 Fondation Philippe le Hodey


9 ISSN 0777-4028
10 Andrzej Trybulec

The following axioms hold:

(3) X = {y} iff for x holds x ∈ X iff x = y,

(4) X = {y, z} iff for x holds x ∈ X iff x = y or x = z.

Let us consider X, Y . The predicate

X⊆Y is defined by x ∈ X implies x ∈ Y.

Let us consider X. The functor


[
X,

with values of the type set, is defined by

x ∈ it iff ex Y st x ∈ Y & Y ∈ X.

Then we get
[
(5) X= Y iff for x holds x ∈ X iff ex Z st x ∈ Z & Z ∈ Y,

(6) X = bool Y iff for Z holds Z ∈ X iff Z ⊆ Y,

The regularity axiom claims that


(7) x ∈ X implies ex Y st Y ∈ X & not ex x st x ∈ X & x ∈ Y.

The scheme Fraenkel deals with a constant A that has the type set and a binary
predicate P and states that the following holds

ex X st for x holds x ∈ X iff ex y st y ∈ A & P[y, x]

provided the parameters satisfy the following condition:

• for x,y,z st P[x, y] & P[x, z] holds y = z.

Let us consider x, y. The functor

hx, yi,

is defined by

it = {{x, y},{x}}.

According to the definition

(8) hx, yi = {{x, y},{x}}.

Let us consider X, Y . The predicate

X≈Y
Tarski Grothendieck Set Theory 11

is defined by

ex Z st (for x st x ∈ X ex y st y ∈ Y & hx, yi ∈ Z) &


(for y st y ∈ Y ex x st x ∈ X & hx, yi ∈ Z)
& for x,y,z,u st hx, yi ∈ Z & hz, ui ∈ Z holds x = z iff y = u.

The Tarski’s axiom A claims that

(9) ex M st N ∈ M & (for X,Y holds X ∈ M & Y ⊆ X implies Y ∈ M ) &


(for X holds X ∈ M implies bool X ∈ M )
& for X holds X ⊆ M implies X ≈ M or X ∈ M.

References
[1] Alfred Tarski. On well-ordered subsets of any set. Fundamenta Mathematicae,
32:176–183, 1939.

[2] Alfred Tarski. Über Unerreaichbare Kardinalzahlen. Fundamenta Mathematicae,


30:176–183, 1938.

Received January 1, 1989


12
FORMALIZED MATHEMATICS
Number 1, January 1990
Université Catholique de Louvain

Built-in Concepts

Andrzej Trybulec1
Warsaw University
Bialystok

Summary. This abstract contains the second part of the axiomatics of the
Mizar system (the first part is in abstract [1]). The axioms listed here characterize
the Mizar built-in concepts that are automatically attached to every Mizar article.
We give definitional axioms of the following concepts: element, subset, Cartesian
product, domain (non empty subset), subdomain (non empty subset of a domain),
set domain (domain consisting of sets). Axioms of strong arithmetics of real num-
bers are also included.

The notation and terminology used here have been introduced in the axiomatics [1]. For
simplicity we adopt the following convention: x, y, z denote objects of the type Any;
X, X1, X2, X3, X4, Y denote objects of the type set. The following axioms hold:

(1) (ex x st x ∈ X) implies (x is Element of X iff x ∈ X),

(2) X is Subset of Y iff X ⊆ Y,

(3) z ∈ [:X, Y :] iff ex x,y st x ∈ X & y ∈ Y & z = hx, yi,

(4) X is DOMAIN iff ex x st x ∈ X,

(5) [:X1,X2,X3:] = [:[:X1,X2:],X3:],

(6) [:X1,X2,X3,X4:] = [:[:X1,X2,X3:],X4:].

In the sequel D1, D2, D3, D4 will denote objects of the type DOMAIN. Let us
introduce the consecutive axioms:

(7) for X being Element of [:D1,D2:] holds X is TUPLE of D1,D2,

(8) for X being Element of [:D1,D2,D3:] holds X is TUPLE of D1,D2,D3,


1
Supported by RPBP.III-24.B1.
f
c 1990 Fondation Philippe le Hodey
13 ISSN 0777-4028
14 Andrzej Trybulec

(9) for X being Element of [:D1,D2,D3,D4:]


holds X is TUPLE of D1,D2,D3,D4.

In the sequel D has the type DOMAIN. The following axioms hold:
(10) D1 is SUBDOMAIN of D2 iff D1 ⊆ D2,

(11) D is SET DOMAIN .

In the sequel x, y, z denote objects of the type Element of REAL. The following
axioms are true:
(12) x + y = y + x,

(13) x + (y + z) = (x + y) + z,

(14) x + 0 = x,

(15) x · y = y · x,

(16) x · (y · z) = (x · y) · z,

(17) x · 1 = x,

(18) x · (y + z) = x · y + x · z,

(19) ex y st x + y = 0,

(20) x 6= 0 implies ex y st x · y = 1,

(21) x ≤ y & y ≤ x implies x = y,

(22) x ≤ y & y ≤ z implies x ≤ z,

(23) x ≤ y or y ≤ x,

(24) x ≤ y implies x + z ≤ y + z,

(25) x ≤ y & 0 ≤ z implies x · z ≤ y · z,

(26) for X,Y being Subset of REAL st


(ex x st x ∈ X) & (ex x st x ∈ Y ) & for x,y st x ∈ X & y ∈ Y holds x ≤ y
ex z st for x,y st x ∈ X & y ∈ Y holds x ≤ z & z ≤ y,

(27) x is Real ,

(28) x ∈ NAT implies x + 1 ∈ NAT ,

(29) for A being set of Real


st 0 ∈ A & for x st x ∈ A holds x + 1 ∈ A holds NAT ⊆ A,

(30) x ∈ NAT implies x is Nat .


Built-in Concepts 15

References
[1] Andrzej Trybulec. Tarski Grothendieck set theory. Formalized Mathematics, 1, 1990.

Received January 1, 1989


16
FORMALIZED MATHEMATICS
Number 1, January 1990
Université Catholique de Louvain

Boolean Properties of Sets

Zinaida Trybulec1 Halina Świe czkowska2



Warsaw University Warsaw University
Bialystok Bialystok

Summary. The text includes a number of theorems about Boolean opera-


tions on sets: union, intersection, difference, symmetric difference; and relations
on sets: meets (having non-empty intersection), misses (being disjoint) and subset
(inclusion).

The terminology and notation used here are introduced in the article [1]. For simplicity
we adopt the following convention: x will have the type Any; X, Y , Z, V will have
the type set. The scheme Separation concerns a constant A that has the type set and
a unary predicate P and states that the following holds

ex X st for x holds x ∈ X iff x ∈ A & P[x]

for all values of the parameters.


We now define several new constructions. The constant ∅ has the type set, and is
defined by

not ex x st x ∈ it .

Let us consider X, Y . The functor


X ∪ Y,

with values of the type set, is defined by

x ∈ it iff x ∈ X or x ∈ Y.

The functor
X ∩ Y,
1
Supported by RPBP.III-24.C1.
2
Supported by RPBP.III-24.C1.
f
c 1990 Fondation Philippe le Hodey
17 ISSN 0777-4028
18 Zinaida Trybulec and Halina Świeczkowska

with values of the type set, is defined by

x ∈ it iff x ∈ X & x ∈ Y.

The functor
X \ Y,
yields the type set and is defined by

x ∈ it iff x ∈ X & not x ∈ Y.

The predicate

X meets Y is defined by ex x st x ∈ X & x ∈ Y.

The predicate

X misses Y is defined by for x holds x ∈ X implies not x ∈ Y.

Let us consider X, Y . The functor


. Y,
X−

with values of the type set, is defined by

it = (X \ Y ) ∪ (Y \ X).

We now state several propositions:

(1) Z = ∅ iff not ex x st x ∈ Z,

(2) Z = X ∪ Y iff for x holds x ∈ Z iff x ∈ X or x ∈ Y,

(3) Z = X ∩ Y iff for x holds x ∈ Z iff x ∈ X & x ∈ Y,

(4) Z = X \ Y iff for x holds x ∈ Z iff x ∈ X & not x ∈ Y,

(5) X ⊆ Y iff for x holds x ∈ X implies x ∈ Y,

(6) X meets Y iff ex x st x ∈ X & x ∈ Y,

(7) X misses Y iff for x holds x ∈ X implies not x ∈ Y.

Let us consider X, Y . Let us note that one can characterize the predicate

X=Y

by the following (equivalent) condition:

X ⊆ Y & Y ⊆ X.

The following propositions are true:

(8) x ∈ X ∪ Y iff x ∈ X or x ∈ Y,
Boolean Properties of Sets 19

(9) x ∈ X ∩ Y iff x ∈ X & x ∈ Y,

(10) x ∈ X \ Y iff x ∈ X & not x ∈ Y,

(11) x ∈ X & X ⊆ Y implies x ∈ Y,

(12) x ∈ X & X misses Y implies not x ∈ Y,

(13) x ∈ X & x ∈ Y implies X meets Y,

(14) x ∈ X implies X 6= ∅,

(15) X meets Y implies ex x st x ∈ X & x ∈ Y,

(16) (for x st x ∈ X holds x ∈ Y ) implies X ⊆ Y,

(17) (for x st x ∈ X holds not x ∈ Y ) implies X misses Y,

(18) (for x holds x ∈ X iff x ∈ Y or x ∈ Z) implies X = Y ∪ Z,

(19) (for x holds x ∈ X iff x ∈ Y & x ∈ Z) implies X = Y ∩ Z,

(20) (for x holds x ∈ X iff x ∈ Y & not x ∈ Z) implies X = Y \ Z,

(21) not (ex x st x ∈ X) implies X = ∅,

(22) (for x holds x ∈ X iff x ∈ Y ) implies X = Y,

(23) . Y iff not (x ∈ X iff x ∈ Y ),


x∈X−

(24) x ∈ X & x ∈ Y implies X ∩ Y 6= ∅,

(25) . Z,
(for x holds not x ∈ X iff (x ∈ Y iff x ∈ Z)) implies X = Y −

(26) X ⊆ X,

(27) ∅ ⊆ X,

(28) X ⊆ Y & Y ⊆ X implies X = Y,

(29) X ⊆ Y & Y ⊆ Z implies X ⊆ Z,

(30) X ⊆ ∅ implies X = ∅,

(31) X ⊆ X ∪ Y & Y ⊆ X ∪ Y,

(32) X ⊆ Z & Y ⊆ Z implies X ∪ Y ⊆ Z,

(33) X ⊆ Y implies X ∪ Z ⊆ Y ∪ Z & Z ∪ X ⊆ Z ∪ Y,


20 Zinaida Trybulec and Halina Świeczkowska

(34) X ⊆ Y & Z ⊆ V implies X ∪ Z ⊆ Y ∪ V,

(35) X ⊆ Y implies X ∪ Y = Y & Y ∪ X = Y,

(36) X ∪ Y = Y or Y ∪ X = Y implies X ⊆ Y,

(37) X ∩ Y ⊆ X & X ∩ Y ⊆ Y,

(38) X ∩ Y ⊆ X ∪ Z,

(39) Z ⊆ X & Z ⊆ Y implies Z ⊆ X ∩ Y,

(40) X ⊆ Y implies X ∩ Z ⊆ Y ∩ Z & Z ∩ X ⊆ Z ∩ Y,

(41) X ⊆ Y & Z ⊆ V implies X ∩ Z ⊆ Y ∩ V,

(42) X ⊆ Y implies X ∩ Y = X & Y ∩ X = X,

(43) X ∩ Y = X or Y ∩ X = X implies X ⊆ Y,

(44) X ⊆ Z implies X ∪ Y ∩ Z = (X ∪ Y ) ∩ Z,

(45) X \ Y = ∅ iff X ⊆ Y,

(46) X ⊆ Y implies X \ Z ⊆ Y \ Z,

(47) X ⊆ Y implies Z \ Y ⊆ Z \ X,

(48) X ⊆ Y & Z ⊆ V implies X \ V ⊆ Y \ Z,

(49) X \ Y ⊆ X,

(50) X ⊆ Y \ X implies X = ∅,

(51) X ⊆ Y & X ⊆ Z & Y ∩ Z = ∅ implies X = ∅,

(52) X ⊆ Y ∪ Z implies X \ Y ⊆ Z & X \ Z ⊆ Y,

(53) (X ∩ Y ) ∪ (X ∩ Z) = X implies X ⊆ Y ∪ Z,

(54) X ⊆ Y implies Y = X ∪ (Y \ X) & Y = (Y \ X) ∪ X,

(55) X ⊆ Y & Y ∩ Z = ∅ implies X ∩ Z = ∅,

(56) X = Y ∪ Z iff Y ⊆ X & Z ⊆ X & for V st Y ⊆ V & Z ⊆ V holds X ⊆ V,

(57) X = Y ∩ Z iff X ⊆ Y & X ⊆ Z & for V st V ⊆ Y & V ⊆ Z holds V ⊆ X,

(58) . Y,
X \Y ⊆X −
Boolean Properties of Sets 21

(59) X ∪ Y = ∅ iff X = ∅ & Y = ∅,

(60) X ∪ ∅ = X & ∅ ∪ X = X,

(61) X ∩ ∅ = ∅ & ∅ ∩ X = ∅,

(62) X ∪ X = X,

(63) X ∪ Y = Y ∪ X,

(64) (X ∪ Y ) ∪ Z = X ∪ (Y ∪ Z),

(65) X ∩ X = X,

(66) X ∩ Y = Y ∩ X,

(67) (X ∩ Y ) ∩ Z = X ∩ (Y ∩ Z),

(68) X ∩ (X ∪ Y ) = X
& (X ∪ Y ) ∩ X = X & X ∩ (Y ∪ X) = X & (Y ∪ X) ∩ X = X,

(69) X ∪ (X ∩ Y ) = X
& (X ∩ Y ) ∪ X = X & X ∪ (Y ∩ X) = X & (Y ∩ X) ∪ X = X,

(70) X ∩ (Y ∪ Z) = X ∩ Y ∪ X ∩ Z & (Y ∪ Z) ∩ X = Y ∩ X ∪ Z ∩ X,

(71) X ∪ Y ∩ Z = (X ∪ Y ) ∩ (X ∪ Z) & Y ∩ Z ∪ X = (Y ∪ X) ∩ (Z ∪ X),

(72) (X ∩ Y ) ∪ (Y ∩ Z) ∪ (Z ∩ X) = (X ∪ Y ) ∩ (Y ∪ Z) ∩ (Z ∪ X),

(73) X \ X = ∅,

(74) X \ ∅ = X,

(75) ∅ \ X = ∅,

(76) X \ (X ∪ Y ) = ∅ & X \ (Y ∪ X) = ∅,

(77) X \ X ∩ Y = X \ Y & X \ Y ∩ X = X \ Y,

(78) (X \ Y ) ∩ Y = ∅ & Y ∩ (X \ Y ) = ∅,

(79) X ∪ (Y \ X) = X ∪ Y & (Y \ X) ∪ X = Y ∪ X,

(80) X ∩ Y ∪ (X \ Y ) = X & (X \ Y ) ∪ X ∩ Y = X,

(81) X \ (Y \ Z) = (X \ Y ) ∪ X ∩ Z,

(82) X \ (X \ Y ) = X ∩ Y,
22 Zinaida Trybulec and Halina Świeczkowska

(83) (X ∪ Y ) \ Y = X \ Y,

(84) X ∩ Y = ∅ iff X \ Y = X,

(85) X \ (Y ∪ Z) = (X \ Y ) ∩ (X \ Z),

(86) X \ (Y ∩ Z) = (X \ Y ) ∪ (X \ Z),

(87) (X ∪ Y ) \ (X ∩ Y ) = (X \ Y ) ∪ (Y \ X),

(88) (X \ Y ) \ Z = X \ (Y ∪ Z),

(89) (X ∪ Y ) \ Z = (X \ Z) ∪ (Y \ Z),

(90) X \ Y = Y \ X implies X = Y,

(91) . Y = (X \ Y ) ∪ (Y \ X),
X−

(92) . ∅=X &∅−


X− . X = X,

(93) . X = ∅,
X−

(94) . Y =Y −
X− . X,

(95) . Y ) ∪ X ∩ Y,
X ∪ Y = (X −

(96) . Y = (X ∪ Y ) \ X ∩ Y,
X−

(97) . Y ) \ Z = (X \ (Y ∪ Z)) ∪ (Y \ (X ∪ Z)),


(X −

(98) . Z) = X \ (Y ∪ Z) ∪ X ∩ Y ∩ Z,
X \ (Y −

(99) . Y)−
(X − . Z=X−
. (Y −
. Z),

(100) X meets Y ∪ Z iff X meets Y or X meets Z,

(101) X meets Y & Y ⊆ Z implies X meets Z,

(102) X meets Y ∩ Z implies X meets Y & X meets Z,

(103) X meets Y implies Y meets X,

(104) not (X meets ∅ or ∅ meets X),

(105) X misses Y iff not X meets Y,

(106) X misses Y ∪ Z iff X misses Y & X misses Z,

(107) X misses Z & Y ⊆ Z implies X misses Y,


Boolean Properties of Sets 23

(108) X misses Y or X misses Z implies X misses Y ∩ Z,

(109) X misses ∅ & ∅ misses X,

(110) X meets X iff X 6= ∅,

(111) X ∩ Y misses X \ Y,

(112) . Y,
X ∩ Y misses X −

(113) X meets Y \ Z implies X meets Y,

(114) X ⊆ Y & X ⊆ Z & Y misses Z implies X = ∅,

(115) . Y ⊆ Z,
X \ Y ⊆ Z & Y \ X ⊆ Z implies X −

(116) X ∩ (Y \ Z) = (X ∩ Y ) \ Z,

(117) X ∩ (Y \ Z) = X ∩ Y \ X ∩ Z & (Y \ Z) ∩ X = Y ∩ X \ Z ∩ X,

(118) X misses Y iff X ∩ Y = ∅,

(119) X meets Y iff X ∩ Y 6= ∅,

(120) X ⊆ (Y ∪ Z) & X ∩ Z = ∅ implies X ⊆ Y,

(121) Y ⊆ X & X ∩ Y = ∅ implies Y = ∅,

(122) X misses Y implies Y misses X.

References
[1] Andrzej Trybulec. Tarski Grothendieck set theory. Formalized Mathematics, 1, 1990.

Received January 6, 1989


24
FORMALIZED MATHEMATICS
Number 1, January 1990
Université Catholique de Louvain

Enumerated Sets

Andrzej Trybulec1
Warsaw University
Bialystok

Summary. We prove basic facts about enumerated sets: definitional theorems


and their immediate consequences, some theorems related to the decomposition of
an enumerated set into union of two sets, facts about removing elements that occur
more than once, and facts about permutations of enumerated sets (with the length
≤ 4). The article includes also schemes enabling instantiation of up to nine universal
quantifiers.

The terminology and notation used in this paper have been introduced in the papers [1]
and [2]. For simplicity we adopt the following convention: x, x1, x2, x3, x4, x5, x6,
x7, x8 have the type Any; X has the type set. In the article we present several logical
schemes. The scheme UI1 concerns a constant A and a unary predicate P and states
that the following holds

P[A]

provided the parameters satisfy the following condition:

• for x1 holds P[x1].

The scheme UI2 deals with a constant A, a constant B and a binary predicate P
and states that the following holds

P[A, B]

provided the parameters satisfy the following condition:

• for x1,x2 holds P[x1,x2].

The scheme UI3 concerns a constant A, a constant B, a constant C and a ternary


predicate P and states that the following holds

P[A, B,C]
1
Supported by RPBP.III-24.C1.
f
c 1990 Fondation Philippe le Hodey
25 ISSN 0777-4028
26 Andrzej Trybulec

provided the parameters satisfy the following condition:

• for x1,x2,x3 holds P[x1,x2,x3].

The scheme UI4 concerns a constant A, a constant B, a constant C, a constant D


and a 4-ary predicate P and states that the following holds

P[A, B,C,D]

provided the parameters satisfy the following condition:

• for x1,x2,x3,x4 holds P[x1,x2,x3,x4].

The scheme UI5 deals with a constant A, a constant B, a constant C, a constant D,


a constant E and a 5-ary predicate P and states that the following holds

P[A, B,C,D,E]

provided the parameters satisfy the following condition:

• for x1,x2,x3,x4,x5 holds P[x1,x2,x3,x4,x5].

The scheme UI6 deals with a constant A, a constant B, a constant C, a constant D,


a constant E, a constant F and a 6-ary predicate P and states that the following holds

P[A, B,C,D,E,F]

provided the parameters satisfy the following condition:

• for x1,x2,x3,x4,x5,x6 holds P[x1,x2,x3,x4,x5,x6].

The scheme UI7 concerns a constant A, a constant B, a constant C, a constant D,


a constant E, a constant F, a constant G and a 7-ary predicate P and states that the
following holds

P[A, B,C,D,E,F,G]

provided the parameters satisfy the following condition:

• for x1,x2,x3,x4,x5,x6,x7 holds P[x1,x2,x3,x4,x5,x6,x7].

The scheme UI8 concerns a constant A, a constant B, a constant C, a constant D, a


constant E, a constant F, a constant G, a constant H and a 8-ary predicate P and states
that the following holds

P[A, B,C,D,E,F,G,H]

provided the parameters satisfy the following condition:

• for x1,x2,x3,x4,x5,x6,x7,x8 holds P[x1,x2,x3,x4,x5,x6,x7,x8].


Enumerated Sets 27

The scheme UI9 concerns a constant A, a constant B, a constant C, a constant D, a


constant E, a constant F, a constant G, a constant H, a constant I and a 9-ary predicate
P and states that the following holds

P[A, B,C,D,E,F,G,H,I]

provided the parameters satisfy the following condition:

• for x1,x2,x3,x4,x5,x6,x7,x8,x9 being Any


holds P[x1,x2,x3,x4,x5,x6,x7,x8,x9].

We now state a number of propositions:

(1) for x1,X holds X = {x1} iff for x holds x ∈ X iff x = x1,

(2) for x1,x holds x ∈ {x1} iff x = x1,

(3) x ∈ {x1} implies x = x1,

(4) x ∈ {x},

(5) for x1,X st for x holds x ∈ X iff x = x1 holds X = {x1},

(6) for x1,x2,X holds X = {x1,x2} iff for x holds x ∈ X iff x = x1 or x = x2,

(7) for x1,x2 for x holds x ∈ {x1,x2} iff x = x1 or x = x2,

(8) x ∈ {x1,x2} implies x = x1 or x = x2,

(9) x = x1 or x = x2 implies x ∈ {x1,x2},

(10) for x1,x2,X st for x holds x ∈ X iff x = x1 or x = x2 holds X = {x1,x2}.

Let us consider x1, x2, x3. The functor

{x1,x2,x3},

yields the type set and is defined by

x ∈ it iff x = x1 or x = x2 or x = x3.

One can prove the following propositions:

(11) for x1,x2,x3,X


holds X = {x1,x2,x3} iff for x holds x ∈ X iff x = x1 or x = x2 or x = x3,

(12) for x1,x2,x3 for x holds x ∈ {x1,x2,x3} iff x = x1 or x = x2 or x = x3,

(13) x ∈ {x1,x2,x3} implies x = x1 or x = x2 or x = x3,


28 Andrzej Trybulec

(14) x = x1 or x = x2 or x = x3 implies x ∈ {x1,x2,x3},

(15) for x1,x2,x3,X


st for x holds x ∈ X iff x = x1 or x = x2 or x = x3 holds X = {x1,x2,x3}.

Let us consider x1, x2, x3, x4. The functor

{x1,x2,x3,x4},

with values of the type set, is defined by

x ∈ it iff x = x1 or x = x2 or x = x3 or x = x4.

We now state several propositions:

(16) for x1,x2,x3,x4,X holds X = {x1,x2,x3,x4}


iff for x holds x ∈ X iff x = x1 or x = x2 or x = x3 or x = x4,

(17) for x1,x2,x3,x4


for x holds x ∈ {x1,x2,x3,x4} iff x = x1 or x = x2 or x = x3 or x = x4,

(18) x ∈ {x1,x2,x3,x4} implies x = x1 or x = x2 or x = x3 or x = x4,

(19) x = x1 or x = x2 or x = x3 or x = x4 implies x ∈ {x1,x2,x3,x4},

(20) for x1,x2,x3,x4,X st


for x holds x ∈ X iff x = x1 or x = x2 or x = x3 or x = x4
holds X = {x1,x2,x3,x4}.

Let us consider x1, x2, x3, x4, x5. The functor

{x1,x2,x3,x4,x5},

yields the type set and is defined by

x ∈ it iff x = x1 or x = x2 or x = x3 or x = x4 or x = x5.

Next we state several propositions:

(21) for x1,x2,x3,x4,x5 for X being set holds X = {x1,x2,x3,x4,x5}


iff for x holds x ∈ X iff x = x1 or x = x2 or x = x3 or x = x4 or x = x5,

(22) x ∈ {x1,x2,x3,x4,x5} iff x = x1 or x = x2 or x = x3 or x = x4 or x = x5,

(23) x ∈ {x1,x2,x3,x4,x5}
implies x = x1 or x = x2 or x = x3 or x = x4 or x = x5,

(24) x = x1 or x = x2 or x = x3 or x = x4 or x = x5
implies x ∈ {x1,x2,x3,x4,x5},
Enumerated Sets 29

(25) for X being set st


for x holds x ∈ X iff x = x1 or x = x2 or x = x3 or x = x4 or x = x5
holds X = {x1,x2,x3,x4,x5}.

Let us consider x1, x2, x3, x4, x5, x6. The functor

{x1,x2,x3,x4,x5,x6},

with values of the type set, is defined by

x ∈ it iff x = x1 or x = x2 or x = x3 or x = x4 or x = x5 or x = x6.

We now state several propositions:

(26) for x1,x2,x3,x4,x5,x6 for X being set holds X = {x1,x2,x3,x4,x5,x6} iff


for x
holds x ∈ X iff x = x1 or x = x2 or x = x3 or x = x4 or x = x5 or x = x6,

(27) x ∈ {x1,x2,x3,x4,x5,x6}
iff x = x1 or x = x2 or x = x3 or x = x4 or x = x5 or x = x6,

(28) x ∈ {x1,x2,x3,x4,x5,x6}
implies x = x1 or x = x2 or x = x3 or x = x4 or x = x5 or x = x6,

(29) x = x1 or x = x2 or x = x3 or x = x4 or x = x5 or x = x6
implies x ∈ {x1,x2,x3,x4,x5,x6},

(30) for X being set st


for x
holds x ∈ X iff x = x1 or x = x2 or x = x3 or x = x4 or x = x5 or x = x6
holds X = {x1,x2,x3,x4,x5,x6}.

Let us consider x1, x2, x3, x4, x5, x6, x7. The functor

{x1,x2,x3,x4,x5,x6,x7},

yields the type set and is defined by

x ∈ it iff x = x1 or x = x2 or x = x3 or x = x4 or x = x5 or x = x6 or x = x7.

The following propositions are true:

(31) for x1,x2,x3,x4,x5,x6,x7 for X being set holds X = {x1,x2,x3,x4,x5,x6,x7}


iff for x holds x ∈ X
iff x = x1 or x = x2 or x = x3 or x = x4 or x = x5 or x = x6 or x = x7,
30 Andrzej Trybulec

(32) x ∈ {x1,x2,x3,x4,x5,x6,x7}
iff x = x1 or x = x2 or x = x3 or x = x4 or x = x5 or x = x6 or x = x7,

(33) x ∈ {x1,x2,x3,x4,x5,x6,x7} implies


x = x1 or x = x2 or x = x3 or x = x4 or x = x5 or x = x6 or x = x7,

(34) x = x1 or x = x2 or x = x3 or x = x4 or x = x5 or x = x6 or x = x7
implies x ∈ {x1,x2,x3,x4,x5,x6,x7},

(35) for X being set st


for x holds x ∈ X
iff x = x1 or x = x2 or x = x3 or x = x4 or x = x5 or x = x6 or x = x7
holds X = {x1,x2,x3,x4,x5,x6,x7}.

Let us consider x1, x2, x3, x4, x5, x6, x7, x8. The functor

{x1,x2,x3,x4,x5,x6,x7,x8},

with values of the type set, is defined by

x ∈ it
iff x = x1 or x = x2 or x = x3 or x = x4 or x = x5 or x = x6 or x = x7 or x = x8.

Next we state a number of propositions:

(36) for x1,x2,x3,x4,x5,x6,x7,x8 for X being set holds


X = {x1,x2,x3,x4,x5,x6,x7,x8} iff for x holds x ∈ X iff x = x1
or x = x2 or x = x3 or x = x4 or x = x5 or x = x6 or x = x7 or x = x8,

(37) x ∈ {x1,x2,x3,x4,x5,x6,x7,x8} iff x = x1


or x = x2 or x = x3 or x = x4 or x = x5 or x = x6 or x = x7 or x = x8,

(38) x ∈ {x1,x2,x3,x4,x5,x6,x7,x8} implies x = x1


or x = x2 or x = x3 or x = x4 or x = x5 or x = x6 or x = x7 or x = x8,

(39) x = x1
or x = x2 or x = x3 or x = x4 or x = x5 or x = x6 or x = x7 or x = x8
implies x ∈ {x1,x2,x3,x4,x5,x6,x7,x8},

(40) for X being set st


for x holds x ∈ X iff x = x1
or x = x2 or x = x3 or x = x4 or x = x5 or x = x6 or x = x7 or x = x8
holds X = {x1,x2,x3,x4,x5,x6,x7,x8},
Enumerated Sets 31

(41) {x1,x2} = {x1} ∪ {x2},

(42) {x1,x2,x3} = {x1} ∪ {x2,x3},

(43) {x1,x2,x3} = {x1,x2} ∪ {x3},

(44) {x1,x2,x3,x4} = {x1} ∪ {x2,x3,x4},

(45) {x1,x2,x3,x4} = {x1,x2} ∪ {x3,x4},

(46) {x1,x2,x3,x4} = {x1,x2,x3} ∪ {x4},

(47) {x1,x2,x3,x4,x5} = {x1} ∪ {x2,x3,x4,x5},

(48) {x1,x2,x3,x4,x5} = {x1,x2} ∪ {x3,x4,x5},

(49) {x1,x2,x3,x4,x5} = {x1,x2,x3} ∪ {x4,x5},

(50) {x1,x2,x3,x4,x5} = {x1,x2,x3,x4} ∪ {x5},

(51) {x1,x2,x3,x4,x5,x6} = {x1} ∪ {x2,x3,x4,x5,x6},

(52) {x1,x2,x3,x4,x5,x6} = {x1,x2} ∪ {x3,x4,x5,x6},

(53) {x1,x2,x3,x4,x5,x6} = {x1,x2,x3} ∪ {x4,x5,x6},

(54) {x1,x2,x3,x4,x5,x6} = {x1,x2,x3,x4} ∪ {x5,x6},

(55) {x1,x2,x3,x4,x5,x6} = {x1,x2,x3,x4,x5} ∪ {x6},

(56) {x1,x2,x3,x4,x5,x6,x7} = {x1} ∪ {x2,x3,x4,x5,x6,x7},

(57) {x1,x2,x3,x4,x5,x6,x7} = {x1,x2} ∪ {x3,x4,x5,x6,x7},

(58) {x1,x2,x3,x4,x5,x6,x7} = {x1,x2,x3} ∪ {x4,x5,x6,x7},

(59) {x1,x2,x3,x4,x5,x6,x7} = {x1,x2,x3,x4} ∪ {x5,x6,x7},

(60) {x1,x2,x3,x4,x5,x6,x7} = {x1,x2,x3,x4,x5} ∪ {x6,x7},

(61) {x1,x2,x3,x4,x5,x6,x7} = {x1,x2,x3,x4,x5,x6} ∪ {x7},

(62) {x1,x2,x3,x4,x5,x6,x7,x8} = {x1} ∪ {x2,x3,x4,x5,x6,x7,x8},

(63) {x1,x2,x3,x4,x5,x6,x7,x8} = {x1,x2} ∪ {x3,x4,x5,x6,x7,x8},

(64) {x1,x2,x3,x4,x5,x6,x7,x8} = {x1,x2,x3} ∪ {x4,x5,x6,x7,x8},

(65) {x1,x2,x3,x4,x5,x6,x7,x8} = {x1,x2,x3,x4} ∪ {x5,x6,x7,x8},


32 Andrzej Trybulec

(66) {x1,x2,x3,x4,x5,x6,x7,x8} = {x1,x2,x3,x4,x5} ∪ {x6,x7,x8},

(67) {x1,x2,x3,x4,x5,x6,x7,x8} = {x1,x2,x3,x4,x5,x6} ∪ {x7,x8},

(68) {x1,x2,x3,x4,x5,x6,x7,x8} = {x1,x2,x3,x4,x5,x6,x7} ∪ {x8},

(69) {x1,x1} = {x1},

(70) {x1,x1,x2} = {x1,x2},

(71) {x1,x1,x2,x3} = {x1,x2,x3},

(72) {x1,x1,x2,x3,x4} = {x1,x2,x3,x4},

(73) {x1,x1,x2,x3,x4,x5} = {x1,x2,x3,x4,x5},

(74) {x1,x1,x2,x3,x4,x5,x6} = {x1,x2,x3,x4,x5,x6},

(75) {x1,x1,x2,x3,x4,x5,x6,x7} = {x1,x2,x3,x4,x5,x6,x7},

(76) {x1,x1,x1} = {x1},

(77) {x1,x1,x1,x2} = {x1,x2},

(78) {x1,x1,x1,x2,x3} = {x1,x2,x3},

(79) {x1,x1,x1,x2,x3,x4} = {x1,x2,x3,x4},

(80) {x1,x1,x1,x2,x3,x4,x5} = {x1,x2,x3,x4,x5},

(81) {x1,x1,x1,x2,x3,x4,x5,x6} = {x1,x2,x3,x4,x5,x6},

(82) {x1,x1,x1,x1} = {x1},

(83) {x1,x1,x1,x1,x2} = {x1,x2},

(84) {x1,x1,x1,x1,x2,x3} = {x1,x2,x3},

(85) {x1,x1,x1,x1,x2,x3,x4} = {x1,x2,x3,x4},

(86) {x1,x1,x1,x1,x2,x3,x4,x5} = {x1,x2,x3,x4,x5},

(87) {x1,x1,x1,x1,x1} = {x1},

(88) {x1,x1,x1,x1,x1,x2} = {x1,x2},

(89) {x1,x1,x1,x1,x1,x2,x3} = {x1,x2,x3},

(90) {x1,x1,x1,x1,x1,x2,x3,x4} = {x1,x2,x3,x4},


Enumerated Sets 33

(91) {x1,x1,x1,x1,x1,x1} = {x1},

(92) {x1,x1,x1,x1,x1,x1,x2} = {x1,x2},

(93) {x1,x1,x1,x1,x1,x1,x2,x3} = {x1,x2,x3},

(94) {x1,x1,x1,x1,x1,x1,x1} = {x1},

(95) {x1,x1,x1,x1,x1,x1,x1,x2} = {x1,x2},

(96) {x1,x1,x1,x1,x1,x1,x1,x1} = {x1},

(97) {x1,x2} = {x2,x1},

(98) {x1,x2,x3} = {x1,x3,x2},

(99) {x1,x2,x3} = {x2,x1,x3},

(100) {x1,x2,x3} = {x2,x3,x1},

(101) {x1,x2,x3} = {x3,x1,x2},

(102) {x1,x2,x3} = {x3,x2,x1},

(103) {x1,x2,x3,x4} = {x1,x2,x4,x3},

(104) {x1,x2,x3,x4} = {x1,x3,x2,x4},

(105) {x1,x2,x3,x4} = {x1,x3,x4,x2},

(106) {x1,x2,x3,x4} = {x1,x4,x2,x3},

(107) {x1,x2,x3,x4} = {x1,x4,x3,x2},

(108) {x1,x2,x3,x4} = {x2,x1,x3,x4},

(109) {x1,x2,x3,x4} = {x2,x1,x4,x3},

(110) {x1,x2,x3,x4} = {x2,x3,x1,x4},

(111) {x1,x2,x3,x4} = {x2,x3,x4,x1},

(112) {x1,x2,x3,x4} = {x2,x4,x1,x3},

(113) {x1,x2,x3,x4} = {x2,x4,x3,x1},

(114) {x1,x2,x3,x4} = {x3,x1,x2,x4},

(115) {x1,x2,x3,x4} = {x3,x1,x4,x2},


34 Andrzej Trybulec

(116) {x1,x2,x3,x4} = {x3,x2,x1,x4},

(117) {x1,x2,x3,x4} = {x3,x2,x4,x1},

(118) {x1,x2,x3,x4} = {x3,x4,x1,x2},

(119) {x1,x2,x3,x4} = {x3,x4,x2,x1},

(120) {x1,x2,x3,x4} = {x4,x1,x2,x3},

(121) {x1,x2,x3,x4} = {x4,x1,x3,x2},

(122) {x1,x2,x3,x4} = {x4,x2,x1,x3},

(123) {x1,x2,x3,x4} = {x4,x2,x3,x1},

(124) {x1,x2,x3,x4} = {x4,x3,x1,x2},

(125) {x1,x2,x3,x4} = {x4,x3,x2,x1}.

References
[1] Andrzej Trybulec. Tarski Grothendieck set theory. Formalized Mathematics, 1, 1990.

[2] Zinaida Trybulec and Halina Świe czkowska. Boolean properties of sets. Formalized

Mathematics, 1, 1990.

Received January 8, 1989


FORMALIZED MATHEMATICS
Number 1, January 1990
Université Catholique de Louvain

Basic Properties of Real Numbers

Krzysztof Hryniewiecki1
Warsaw University

Summary. Basic facts of arithmetics of real numbers are presented: definitions


and properties of the complement element, the inverse element, subtraction and
division; some basic properties of the set REAL (e.g. density), and the scheme of
separation for sets of reals.

For simplicity we adopt the following convention: x, y, z, t will denote objects of the
type Real; r will denote an object of the type Any. Let us consider x, y. Let us note
that it makes sense to consider the following functors on restricted areas. Then

x+y is Real ,

x·y is Real .

One can prove the following propositions:

(1) r is Real iff r ∈ REAL ,

(2) x + y = y + x,

(3) x + (y + z) = (x + y) + z,

(4) x + 0 = x & 0 + x = x,

(5) x · y = y · x,

(6) x · (y · z) = (x · y) · z,

(7) x · 1 = x & 1 · x = x,

(8) (x + y) · z = x · z + y · z & z · (x + y) = z · x + z · y,

(9) z 6= 0 & x 6= y implies x · z 6= y · z & z · x 6= y · z & z · x 6= z · y & x · z 6= z · y,


1
This work has been supported by RPBP III.24 C1
f
c 1990 Fondation Philippe le Hodey
35 ISSN 0777-4028
36 Krzysztof Hryniewiecki

(10) z + x = z + y or x + z = y + z or z + x = y + z or x + z = z + y
implies x = y,

(11) x 6= y iff x + z 6= y + z,

(12) z 6= 0 & (x · z = y · z or z · x = z · y or x · z = z · y or z · x = y · z)
implies x = y.

We now define two new functors. Let us consider x. The functor

− x,

with values of the type Real, is defined by

x + it = 0.

Assume that the following holds

x 6= 0.

The functor
x -1 ,

yields the type Real and is defined by

x · it = 1.

We now define two new functors. Let us consider x, y. The functor

x − y,

yields the type Real and is defined by

it = x + (− y).

Assume that the following holds

y 6= 0.

The functor
x/y,

yields the type Real and is defined by

it = x · y -1 .

The following propositions are true:

(13) x + − x = 0 & − x + x = 0,

(14) x − y = x + − y,
Basic Properties of Real Numbers 37

(15) x 6= 0 implies x · x -1 = 1 & x -1 · x = 1,

(16) y 6= 0 implies x/y = x · y -1 & x/y = y -1 · x,

(17) x + y − z = x + (y − z),

(18) − (− x) = x,

(19) 0 − x = − x,

(20) x · 0 = 0 & 0 · x = 0,

(21) (− x) · y = − (x · y) & x · (− y) = − (x · y) & (− x) · y = x · (− y),

(22) x 6= 0 iff − x 6= 0,

(23) x · y = 0 iff x = 0 or y = 0,

(24) x 6= 0 & y 6= 0 implies x -1 · y -1 = (x · y) -1 ,

(25) x − 0 = x,

(26) − 0 = 0,

(27) x − (y + z) = x − y − z,

(28) x − (y − z) = x − y + z,

(29) x · (y − z) = x · y − x · z & (y − z) · x = y · x − z · x,

(30) x + z = y implies x = y − z & z = y − x,

(31) x 6= 0 implies x -1 6= 0,

(32) x 6= 0 implies x -1 -1 = x,

(33) x 6= 0 implies 1/x = x -1 & 1/x -1 = x,

(34) x 6= 0 implies x · (1/x) = 1 & (1/x) · x = 1,

(35) y 6= 0 & t 6= 0 implies (x/y) · (z/t) = (x · z)/(y · t),

(36) x − x = 0,

(37) x 6= 0 implies x/x = 1,

(38) y 6= 0 & z 6= 0 implies x/y = (x · z)/(y · z),

(39) y 6= 0 implies − x/y = (− x)/y & x/(− y) = − x/y,


38 Krzysztof Hryniewiecki

(40) z 6= 0 implies x/z + y/z = (x + y)/z & x/z − y/z = (x − y)/z,

(41) y 6= 0 & t 6= 0
implies x/y + z/t = (x · t + z · y)/(y · t) & x/y − z/t = (x · t − z · y)/(y · t),

(42) y 6= 0 & z 6= 0 implies x/(y/z) = (x · z)/y,

(43) y 6= 0 implies x/y · y = x,

(44) for x,y ex z st x = y + z & x = z + y,

(45) for x,y st y 6= 0 ex z st x = y · z & x = z · y,

(46) x ≤ y & y ≤ x implies x = y,

(47) x ≤ y & y ≤ z implies x ≤ z,

(48) x ≤ y or y ≤ x,

(49) x ≤ y implies x + z ≤ y + z & x − z ≤ y − z,

(50) x ≤ y iff − y ≤ − x,

(51) x ≤ y & 0 ≤ z implies x · z ≤ y · z & z · x ≤ z · y & z · x ≤ y · z & x · z ≤ z · y,

(52) x ≤ y & z ≤ 0 implies y · z ≤ x · z & z · y ≤ z · x & y · z ≤ z · x & z · y ≤ x · z,

(53) x ≤ y iff x + z ≤ y + z,

(54) x ≤ y iff x − z ≤ y − z,

(55) x≤y&z≤t
implies x + z ≤ y + t & x + z ≤ t + y & z + x ≤ t + y & z + x ≤ y + t,

(56) x ≤ x.

Let us consider x, y. The predicate

x<y is defined by x ≤ y & x 6= y.

One can prove the following propositions:

(57) x < y iff x ≤ y & x 6= y,

(58) x ≤ y & y < z or x < y & y ≤ z or x < y & y < z implies x < z,

(59) x < y implies x + z < y + z


& x − z < y − z & z + x < z + y & x + z < z + y & z + x < y + z,
Basic Properties of Real Numbers 39

(60) x+z <y+z


or z + x < z + y or x + z < z + y or z + x < y + z or x − z < y − z
implies x < y,

(61) x 6= y implies x < y or y < x,

(62) not x < y iff y ≤ x,

(63) x < y or y < x or x = y,

(64) x < y implies not y < x,

(65) 0 < 1,

(66) x < 0 iff 0 < − x,

(67) x < y & z ≤ t or x ≤ y & z < t or x < y & z < t


implies x + z < y + t & z + x < y + t & z + x < t + y & x + z < t + y,

(68) x < y iff − y < − x,

(69) for x,y st 0 < x holds y < y + x,

(70) 0 < z & x < y implies x · z < y · z & z · x < z · y & x · z < z · y & z · x < y · z,

(71) z < 0 & x < y implies y · z < x · z & z · y < z · x & y · z < z · x & z · y < x · z,

(72) 0 < z implies 0 < z -1 ,

(73) 0 < z implies (x < y iff x/z < y/z),

(74) z < 0 implies (x < y iff y/z < x/z),

(75) x < y implies ex z st x < z & z < y,

(76) for x ex y st x < y,

(77) for x ex y st y < x,

(78) for X,Y being Subset of REAL st


(ex x st x ∈ X) & (ex x st x ∈ Y ) & for x,y st x ∈ X & y ∈ Y holds x ≤ y
ex z st for x,y st x ∈ X & y ∈ Y holds x ≤ z & z ≤ y.

The scheme SepReal concerns a unary predicate P states that the following holds

ex X being set of Real st for x holds x ∈ X iff P[x]

for all values of the parameter.


40 Krzysztof Hryniewiecki

The following propositions are true:

(79) y = − x iff x + y = 0,

(80) for x,y st x 6= 0 holds y = x -1 iff x · y = 1,

(81) for x,y st x 6= 0 & y 6= 0 holds (x/y) -1 = y/x,

(82) for x,y,z,t st y 6= 0 & z 6= 0 & t 6= 0 holds (x/y)/(z/t) = (x · t)/(y · z),

(83) − (x − y) = y − x,

(84) x + y ≤ z iff x ≤ z − y,

(85) x + y ≤ z iff y ≤ z − x,

(86) x ≤ y + z iff x − y ≤ z,

(87) x ≤ y + z iff x − z ≤ y,

(88) x + y < z iff x < z − y,

(89) x + y < z iff y < z − x,

(90) x < z + y iff x − z < y,

(91) x < y + z iff x − z < y,

(92) (x ≤ y & z ≤ t implies x − t ≤ y − z)


& (x < y & z ≤ t or x ≤ y & z < t or x < y & z < t implies x − t < y − z),

(93) 0 ≤ x · x.

Received January 8, 1989


FORMALIZED MATHEMATICS
Number 1, January 1990
Université Catholique de Louvain

The Fundamental Properties of Natural


Numbers

Grzegorz Bancerek1
Warsaw University
Bialystok

Summary. Some fundamental properties of addition, multiplication, order


relations, exact division, the remainder, divisibility, the least common multiple, the
greatest common divisor are presented. A proof of Euclid algorithm is also given.

The article [1] provides the terminology and notation for this paper. For simplicity we
adopt the following convention: x will denote an object of the type Real; k, l, m, n
will denote objects of the type Nat; X will denote an object of the type set of Real.
One can prove the following propositions:

(1) x is Nat implies x + 1 is Nat ,

(2) for X st 0 ∈ X & for x st x ∈ X holds x + 1 ∈ X for k holds k ∈ X,

(3) k + n = n + k,

(4) k + m + n = k + (m + n),

(5) k + 0 = k & 0 + k = k,

(6) k · n = n · k,

(7) k · (m · n) = (k · m) · n,

(8) k · 1 = k & 1 · k = k,

(9) k · (n + m) = k · n + k · m & (n + m) · k = n · k + m · k,

(10) k + m = n + m or k + m = m + n or m + k = m + n implies k = n,
1
Supported by RPBP III.24 C1
f
c 1990 Fondation Philippe le Hodey
41 ISSN 0777-4028
42 Grzegorz Bancerek

(11) k · 0 = 0 & 0 · k = 0.

Let us consider n, k. Let us note that it makes sense to consider the following functor
on a restricted area. Then
n+k is Nat .

The scheme Ind deals with a unary predicate P states that the following holds

for k holds P[k]

provided the parameter satisfies the following conditions:

• P[0],

• for k st P[k] holds P[k + 1].

Let us consider n, k. Let us note that it makes sense to consider the following functor
on a restricted area. Then
n·k is Nat .

One can prove the following propositions:

(12) k ≤ n & n ≤ k implies k = n,

(13) k ≤ n & n ≤ m implies k ≤ m,

(14) k ≤ n or n ≤ k,

(15) k ≤ k,

(16) k ≤ n implies
k + m ≤ n + m & k + m ≤ m + n & m + k ≤ m + n & m + k ≤ n + m,

(17) k + m ≤ n + m or k + m ≤ m + n or m + k ≤ m + n or m + k ≤ n + m
implies k ≤ n,

(18) for k holds 0 ≤ k,

(19) 0 6= k implies 0 < k,

(20) k ≤ n implies k · m ≤ n · m & k · m ≤ m · n & m · k ≤ n · m & m · k ≤ m · n,

(21) 0 6= k + 1,

(22) k = 0 or ex n st k = n + 1,

(23) k + n = 0 implies k = 0 & n = 0,

(24) k 6= 0 & (n · k = m · k or n · k = k · m or k · n = k · m) implies n = m,


The Fundamental Properties of Natural . . . 43

(25) k · n = 0 implies k = 0 or n = 0.

The scheme Def by Ind concerns a constant A that has the type Nat, a binary functor
F yielding values of the type Nat and a binary predicate P and states that the following
holds

(for k ex n st P[k, n]) & for k,n,m st P[k, n] & P[k, m] holds n = m

provided the parameters satisfy the following condition:

• for k,n holds


P[k, n] iff k = 0 & n = A or ex m,l st k = m + 1 & P[m, l] & n = F(k, l).

Next we state several propositions:

(26) for k,n st k ≤ n + 1 holds k ≤ n or k = n + 1,

(27) for n,k st n ≤ k & k ≤ n + 1 holds n = k or k = n + 1,

(28) for k,n st k ≤ n ex m st n = k + m,

(29) k ≤ k + m,

(30) k < n iff k ≤ n & k 6= n,

(31) not k < 0.

Now we present three schemes. The scheme Comp Ind deals with a unary predicate
P states that the following holds

for k holds P[k]

provided the parameter satisfies the following condition:

• for k st for n st n < k holds P[n] holds P[k].

The scheme Min concerns a unary predicate P states that the following holds

ex k st P[k] & for n st P[n] holds k ≤ n

provided the parameter satisfies the following condition:

• ex k st P[k].

The scheme Max concerns a unary predicate P and a constant A that has the type
Nat, and states that the following holds

ex k st P[k] & for n st P[n] holds n ≤ k

provided the parameters satisfy the following conditions:

• for k st P[k] holds k ≤ A,


44 Grzegorz Bancerek

• ex k st P[k].

We now state a number of propositions:

(32) not (k < n & n < k),

(33) k < n & n < m implies k < m,

(34) k < n or k = n or n < k,

(35) not k < k,

(36) k < n implies


k + m < n + m & k + m < m + n & m + k < m + n & m + k < n + m,

(37) k ≤ n implies k ≤ n + m,

(38) k < n + 1 iff k ≤ n,

(39) k ≤ n & n < m or k < n & n ≤ m or k < n & n < m implies k < m,

(40) k · n = 1 implies k = 1 & n = 1,

(41) k + 1 ≤ n iff k < n.

The scheme Regr concerns a unary predicate P states that the following holds

P[0]

provided the parameter satisfies the following conditions:

• ex k st P[k],

• for k st k 6= 0 & P[k] ex n st n < k & P[n].

In the sequel k1, t, t1 will denote objects of the type Nat. The following
propositions are true:

(42) for m st 0 < m for n ex k,t st n = (m · k) + t & t < m,

(43) for n,m,k,k1,t,t1


st n = m · k + t & t < m & n = m · k1 + t1 & t1 < m holds k = k1 & t = t1.

We now define two new functors. Let k, l have the type Nat. The functor

k ÷ l,

yields the type Nat and is defined by

(ex t st k = l · it + t & t < l) or it = 0 & l = 0.


The Fundamental Properties of Natural . . . 45

The functor
k mod l,

yields the type Nat and is defined by

(ex t st k = l · t + it & it < l) or it = 0 & l = 0.

Next we state four propositions:

(44) for k,l,n being Nat


holds n = k ÷ l iff (ex t st k = l · n + t & t < l) or n = 0 & l = 0,

(45) for k,l,n being Nat


holds n = k mod l iff (ex t st k = l · t + n & n < l) or n = 0 & l = 0,

(46) for m,n st 0 < m holds n mod m < m,

(47) for n,m st 0 < m holds n = m · (n ÷ m) + (n mod m).

Let k, l have the type Nat. The predicate

k|l is defined by ex t st l = k · t.

Next we state a number of propositions:

(48) for k,l being Nat holds k | l iff ex t st l = k · t,

(49) for n,m holds m | n iff n = m · (n ÷ m),

(50) for n holds n | n,

(51) for n,m,l st n | m & m | l holds n | l,

(52) for n,m st n | m & m | n holds n = m,

(53) k | 0 & 1 | k,

(54) for n,m st 0 < m & n | m holds n ≤ m,

(55) for n,m,l st n | m & n | l holds n | m + l,

(56) n | k implies n | k · m,

(57) for n,m,l st n | m & n | m + l holds n | l,

(58) n | m & n | k implies n | m mod k.

Let us consider k, n. The functor

k lcm n,
46 Grzegorz Bancerek

with values of the type Nat, is defined by

k | it & n | it & for m st k | m & n | m holds it | m.

Next we state a proposition

(59) for M being Nat


holds M = k lcm n iff k | M & n | M & for m st k | m & n | m holds M | m.

Let us consider k, n. The functor

k gcd n,

yields the type Nat and is defined by

it | k & it | n & for m st m | k & m | n holds m | it .

We now state a proposition

(60) for M being Nat


holds M = k gcd n iff M | k & M | n & for m st m | k & m | n holds m | M.

The scheme Euklides deals with a unary functor F yielding values of the type Nat,
a constant A that has the type Nat and a constant B that has the type Nat, and states
that the following holds

ex n st F(n) = A gcd B & F(n + 1) = 0

provided the parameters satisfy the following conditions:

• 0 < B & B < A,

• F (0) = A & F(1) = B,

• for n holds F(n + 2) = F(n) mod F(n + 1).

References
[1] Krzysztof Hryniewiecki. Basic properties of real numbers. Formalized Mathematics,
1, 1990.

Received January 11, 1989


FORMALIZED MATHEMATICS
Number 1, January 1990
Université Catholique de Louvain

Some Basic Properties of Sets

Czeslaw Byliński1
Warsaw University
Bialystok

Summary. In this article some basic theorems about singletons, pairs, power
sets, unions of families of sets, and the cartesian product of two sets are proved.

The articles [1] and [2] provide the terminology and notation for this paper. One can
prove the following propositions:

(1) bool ∅ = {∅},


[
(2) ∅ = ∅.

For simplicity we adopt the following convention: x, x1, x2, y, y1, y2, z will denote
objects of the type Any; A, B, X, X1, X2, Y , Y 1, Y 2, Z will denote objects of the
type set. One can prove the following propositions:

(3) {x} 6= ∅,

(4) {x, y} 6= ∅,

(5) {x} = {x, x},

(6) {x} = {y} implies x = y,

(7) {x1,x2} = {x2,x1},

(8) {x} = {y1,y2} implies x = y1 & x = y2,

(9) {x} = {y1,y2} implies y1 = y2,

(10) {x1,x2} = {y1,y2} implies (x1 = y1 or x1 = y2) & (x2 = y1 or x2 = y2),

(11) {x1,x2} = {x1} ∪ {x2},


1
Supported by RPBP.III-24.C1.
f
c 1990 Fondation Philippe le Hodey
47 ISSN 0777-4028
48 Czeslaw Byliński

(12) {x} ⊆ {x, y} & {y} ⊆ {x, y},

(13) {x} ∪ {y} = {x} or {x} ∪ {y} = {y} implies x = y,

(14) {x} ∪ {x, y} = {x, y} & {x, y} ∪ {x} = {x, y},

(15) {y} ∪ {x, y} = {x, y} & {x, y} ∪ {y} = {x, y},

(16) {x} ∩ {y} = ∅ or {y} ∩ {x} = ∅ implies x 6= y,

(17) x 6= y implies {x} ∩ {y} = ∅ & {y} ∩ {x} = ∅,

(18) {x} ∩ {y} = {x} or {x} ∩ {y} = {y} implies x = y,

(19) {x} ∩ {x, y} = {x}


& {y} ∩ {x, y} = {y} & {x, y} ∩ {x} = {x} & {x, y} ∩ {y} = {y},

(20) {x} \ {y} = {x} iff x 6= y,

(21) {x} \ {y} = ∅ implies x = y,

(22) {x} \ {x, y} = ∅ & {y} \ {x, y} = ∅,

(23) x 6= y implies {x, y} \ {y} = {x} & {x, y} \ {x} = {y},

(24) {x} ⊆ {y} implies {x} = {y},

(25) {z} ⊆ {x, y} implies z = x or z = y,

(26) {x, y} ⊆ {z} implies x = z & y = z,

(27) {x, y} ⊆ {z} implies {x, y} = {z},

(28) {x1,x2} ⊆ {y1,y2} implies (x1 = y1 or x1 = y2) & (x2 = y1 or x2 = y2),

(29) . {y} = {x, y},


x 6= y implies {x} −

(30) bool{x} = {∅,{x}},


[
(31) {x} = x,
[
(32) {{x},{y}} = {x, y},

(33) hx1,x2i = hy1,y2i implies x1 = y1 & x2 = y2,

(34) hx, yi ∈ [:{x1},{y1}:] iff x = x1 & y = y1,

(35) [:{x},{y}:] = {hx, yi},


Some Basic Properties of Sets 49

(36) [:{x},{y, z}:] = {hx, yi,hx, zi} & [:{x, y},{z}:] = {hx, zi,hy, zi},

(37) {x} ⊆ X iff x ∈ X,

(38) {x1,x2} ⊆ Z iff x1 ∈ Z & x2 ∈ Z,

(39) Y ⊆ {x} iff Y = ∅ or Y = {x},

(40) Y ⊆ X & not x ∈ Y implies Y ⊆ X \ {x},

(41) X 6= {x} & x ∈ X implies ex y st y ∈ X & y 6= x,

(42) Z ⊆ {x1,x2} iff Z = ∅ or Z = {x1} or Z = {x2} or Z = {x1,x2},

(43) {z} = X ∪ Y
implies X = {z} & Y = {z} or X = ∅ & Y = {z} or X = {z} & Y = ∅,

(44) {z} = X ∪ Y & X 6= Y implies X = ∅ or Y = ∅,

(45) {x} ∪ X = X or X ∪ {x} = X implies x ∈ X,

(46) x ∈ X implies {x} ∪ X = X & X ∪ {x} = X,

(47) {x, y} ∪ Z = Z or Z ∪ {x, y} = Z implies x ∈ Z & y ∈ Z,

(48) x ∈ Z & y ∈ Z implies {x, y} ∪ Z = Z & Z ∪ {x, y} = Z,

(49) {x} ∪ X 6= ∅ & X ∪ {x} 6= ∅,

(50) {x, y} ∪ X 6= ∅ & X ∪ {x, y} 6= ∅,

(51) X ∩ {x} = {x} or {x} ∩ X = {x} implies x ∈ X,

(52) x ∈ X implies X ∩ {x} = {x} & {x} ∩ X = {x},

(53) x ∈ Z & y ∈ Z implies {x, y} ∩ Z = {x, y} & {x, y} = Z ∩ {x, y},

(54) {x} ∩ X = ∅ or X ∩ {x} = ∅ implies not x ∈ X,

(55) {x, y} ∩ Z = ∅ or Z ∩ {x, y} = ∅ implies not x ∈ Z & not y ∈ Z,

(56) not x ∈ X implies {x} ∩ X = ∅ & X ∩ {x} = ∅,

(57) not x ∈ Z & not y ∈ Z implies {x, y} ∩ Z = ∅ & Z ∩ {x, y} = ∅,

(58) {x} ∩ X = ∅ or {x} ∩ X = {x} & X ∩ {x} = {x},

(59) {x, y} ∩ X = {x} or X ∩ {x, y} = {x} implies not y ∈ X or x = y,


50 Czeslaw Byliński

(60) x ∈ X & (not y ∈ X or x = y) implies {x, y} ∩ X = {x} & X ∩ {x, y} = {x},

(61) {x, y} ∩ X = {y} or X ∩ {x, y} = {y} implies not x ∈ X or x = y,

(62) y ∈ X & (not x ∈ X or x = y) implies {x, y} ∩ X = {y} & X ∩ {x, y} = {y},

(63) {x, y} ∩ X = {x, y} or X ∩ {x, y} = {x, y} implies x ∈ X & y ∈ X,

(64) z ∈ X \ {x} iff z ∈ X & z 6= x,

(65) X \ {x} = X iff not x ∈ X,

(66) X \ {x} = ∅ implies X = ∅ or X = {x},

(67) {x} \ X = {x} iff not x ∈ X,

(68) {x} \ X = ∅ iff x ∈ X,

(69) {x} \ X = ∅ or {x} \ X = {x},

(70) {x, y} \ X = {x} iff not x ∈ X & (y ∈ X or x = y),

(71) {x, y} \ X = {y} iff (x ∈ X or x = y) & not y ∈ X,

(72) {x, y} \ X = {x, y} iff not x ∈ X & not y ∈ X,

(73) {x, y} \ X = ∅ iff x ∈ X & y ∈ X,

(74) {x, y} \ X = ∅
or {x, y} \ X = {x} or {x, y} \ X = {y} or {x, y} \ X = {x, y},

(75) X \ {x, y} = ∅ iff X = ∅ or X = {x} or X = {y} or X = {x, y},

(76) ∅ ∈ bool A,

(77) A ∈ bool A,

(78) bool A 6= ∅,

(79) A ⊆ B implies bool A ⊆ bool B,

(80) {A} ⊆ bool A,

(81) bool A ∪ bool B ⊆ bool(A ∪ B),

(82) bool A ∪ bool B = bool(A ∪ B) implies A ⊆ B or B ⊆ A,

(83) bool(A ∩ B) = bool A ∩ bool B,


Some Basic Properties of Sets 51

(84) bool(A \ B) ⊆ {∅} ∪ (bool A \ bool B),

(85) X ∈ bool(A \ B) iff X ⊆ A & X misses B,

(86) . B),
bool(A \ B) ∪ bool(B \ A) ⊆ bool(A −

(87) . B) iff X ⊆ A ∪ B & X misses A ∩ B,


X ∈ bool(A −

(88) X ∈ bool A & Y ∈ bool A implies X ∪ Y ∈ bool A,

(89) X ∈ bool A or Y ∈ bool A implies X ∩ Y ∈ bool A,

(90) X ∈ bool A implies X \ Y ∈ bool A,

(91) . Y ∈ bool A,
X ∈ bool A & Y ∈ bool A implies X −
[
(92) X ∈ A implies X ⊆ A,
[
(93) {X, Y } = X ∪ Y,
[
(94) (for X st X ∈ A holds X ⊆ Z) implies A ⊆ Z,
[ [
(95) A ⊆ B implies A⊆ B,
[ [ [
(96) (A ∪ B) = A∪ B,
[ [ [
(97) (A ∩ B) ⊆ A∩ B,
[
(98) (for X st X ∈ A holds X ∩ B = ∅) implies (A) ∩ B = ∅,
[
(99) bool A = A,
[
(100) A ⊆ bool A,

(101) (for X,Y st X 6= Y & X ∈ A ∪ B & Y ∈ A ∪ B holds X ∩ Y = ∅)


[ [ [
implies (A ∩ B) = A ∩ B,

(102) z ∈ [:X, Y :] implies ex x,y st hx, yi = z,

(103) A ⊆ [:X, Y :] & z ∈ A implies ex x,y st x ∈ X & y ∈ Y & z = hx, yi,

(104) z ∈ [:X1,Y 1:] ∩ [:X2,Y 2:]


implies ex x,y st z = hx, yi & x ∈ X1 ∩ X2 & y ∈ Y 1 ∩ Y 2,

(105) [:X, Y :] ⊆ bool bool(X ∪ Y ),

(106) hx, yi ∈ [:X, Y :] iff x ∈ X & y ∈ Y,


52 Czeslaw Byliński

(107) hx, yi ∈ [:X, Y :] implies hy, xi ∈ [:Y, X:],

(108) (for x,y holds hx, yi ∈ [:X1,Y 1:] iff hx, yi ∈ [:X2,Y 2:])
implies [:X1,Y 1:] = [:X2,Y 2:],

(109) A ⊆ [:X, Y :] & (for x,y st hx, yi ∈ A holds hx, yi ∈ B) implies A ⊆ B,

(110) A ⊆ [:X1,Y 1:] & B ⊆ [:X2,Y 2:] & (for x,y holds hx, yi ∈ A iff hx, yi ∈ B)
implies A = B,

(111) (for z st z ∈ A ex x,y st z = hx, yi) & (for x,y st hx, yi ∈ A holds hx, yi ∈ B)
implies A ⊆ B,

(112) (for z st z ∈ A ex x,y st z = hx, yi) &


(for z st z ∈ B ex x,y st z = hx, yi) & (for x,y holds hx, yi ∈ A iff hx, yi ∈ B)
implies A = B,

(113) [:X, Y :] = ∅ iff X = ∅ or Y = ∅,

(114) X 6= ∅ & Y 6= ∅ & [:X, Y :] = [:Y, X:] implies X = Y,

(115) [:X, X:] = [:Y, Y :] implies X = Y,

(116) X ⊆ [:X, X:] implies X = ∅,

(117) Z 6= ∅ & ([:X, Z:] ⊆ [:Y, Z:] or [:Z, X:] ⊆ [:Z, Y :]) implies X ⊆ Y,

(118) X ⊆ Y implies [:X, Z:] ⊆ [:Y, Z:] & [:Z, X:] ⊆ [:Z, Y :],

(119) X1 ⊆ Y 1 & X2 ⊆ Y 2 implies [:X1,X2:] ⊆ [:Y 1,Y 2:],

(120) [:X ∪ Y,Z:] = [:X, Z:] ∪ [:Y, Z:] & [:Z, X ∪ Y :] = [:Z, X:] ∪ [:Z, Y :],

(121) [:X1 ∪ X2,Y 1 ∪ Y 2:] = [:X1,Y 1:] ∪ [:X1,Y 2:] ∪ [:X2,Y 1:] ∪ [:X2,Y 2:],

(122) [:X ∩ Y,Z:] = [:X, Z:] ∩ [:Y, Z:] & [:Z, X ∩ Y :] = [:Z, X:] ∩ [:Z, Y :],

(123) [:X1 ∩ X2,Y 1 ∩ Y 2:] = [:X1,Y 1:] ∩ [:X2,Y 2:],

(124) A ⊆ X & B ⊆ Y implies [:A, Y :] ∩ [:X, B:] = [:A, B:],

(125) [:X \ Y,Z:] = [:X, Z:] \ [:Y, Z:] & [:Z, X \ Y :] = [:Z, X:] \ [:Z, Y :],

(126) [:X1,X2:] \ [:Y 1,Y 2:] = [:X1 \ Y 1,X2:] ∪ [:X1,X2 \ Y 2:],

(127) X1 ∩ X2 = ∅ or Y 1 ∩ Y 2 = ∅ implies [:X1,Y 1:] ∩ [:X2,Y 2:] = ∅,


Some Basic Properties of Sets 53

(128) hx, yi ∈ [:{z},Y :] iff x = z & y ∈ Y,

(129) hx, yi ∈ [:X, {z}:] iff x ∈ X & y = z,

(130) X 6= ∅ implies [:{x},X:] 6= ∅ & [:X, {x}:] 6= ∅,

(131) x 6= y implies [:{x},X:] ∩ [:{y},Y :] = ∅ & [:X, {x}:] ∩ [:Y, {y}:] = ∅,

(132) [:{x, y},X:] = [:{x},X:] ∪ [:{y},X:] & [:X, {x, y}:] = [:X, {x}:] ∪ [:X, {y}:],

(133) Z = [:X, Y :] iff for z holds z ∈ Z iff ex x,y st x ∈ X & y ∈ Y & z = hx, yi,

(134) X1 6= ∅ & Y 1 6= ∅ & [:X1,Y 1:] = [:X2,Y 2:] implies X1 = X2 & Y 1 = Y 2,

(135) X ⊆ [:X, Y :] or X ⊆ [:Y, X:] implies X = ∅.

References
[1] Andrzej Trybulec. Tarski Grothendieck set theory. Formalized Mathematics, 1, 1990.

[2] Zinaida Trybulec and Halina Świe czkowska. Boolean properties of sets. Formalized

Mathematics, 1, 1990.

Received February 1, 1989


54
FORMALIZED MATHEMATICS
Number 1, January 1990
Université Catholique de Louvain

Functions and Their Basic Properties

Czeslaw Byliński1
Warsaw University
Bialystok

Summary. The definitions of the mode Function and the graph of a function
are introduced. The graph of a function is defined to be identical with the function.
The following concepts are also defined: the domain of a function, the range of
a function, the identity function, the composition of functions, the 1-1 function,
the inverse function, the restriction of a function, the image and the inverse image.
Certain basic facts about functions and the notions defined in the article are proved.

The notation and terminology used here are introduced in the papers [1] and [2]. For
simplicity we adopt the following convention: X, X1, X2, Y , Y 1, Y 2 have the type
set; p, x, x1, x2, y, y1, y2, z have the type Any. The mode

Function ,

which widens to the type Any, is defined by

ex F being set st it = F & (for p st p ∈ F ex x,y st hx, yi = p)


& for x,y1,y2 st hx, y1i ∈ F & hx, y2i ∈ F holds y1 = y2.

In the sequel f , g, h will have the type Function. Let us consider f . The functor

graph f,

yields the type set and is defined by

f = it .

Next we state several propositions:

(1) graph f = f,
1
Supported by RPBP.III-24.C1.
f
c 1990 Fondation Philippe le Hodey
55 ISSN 0777-4028
56 Czeslaw Byliński

(2) for F being set st


(for p st p ∈ F ex x,y st hx, yi = p)
& for x,y1,y2 st hx, y1i ∈ F & hx, y2i ∈ F holds y1 = y2
ex f being Function st graph f = F,

(3) p ∈ graph f implies ex x,y st hx, yi = p,

(4) hx, y1i ∈ graph f & hx, y2i ∈ graph f implies y1 = y2,

(5) graph f = graph g implies f = g.

The scheme GraphFunc concerns a constant A that has the type set and a binary
predicate P and states that the following holds

ex f st for x,y holds hx, yi ∈ graph f iff x ∈ A & P[x, y]

provided the parameters satisfy the following condition:

• for x,y1,y2 st P[x, y1] & P[x, y2] holds y1 = y2.

Let us consider f . The functor


dom f,

yields the type set and is defined by

for x holds x ∈ it iff ex y st hx, yi ∈ graph f.

One can prove the following proposition

(6) X = dom f iff for x holds x ∈ X iff ex y st hx, yi ∈ graph f.

Let us consider f , x. Assume that the following holds

x ∈ dom f.

The functor
f .x,

yields the type Any and is defined by

hx, iti ∈ graph f.

The following three propositions are true:

(7) x ∈ dom f implies (y = f .x iff hx, yi ∈ graph f ),

(8) hx, yi ∈ graph f iff x ∈ dom f & y = f .x,

(9) X = dom f & X = dom g & (for x st x ∈ X holds f .x = g .x) implies f = g.


Functions and Their Basic Properties 57

Let us consider f . The functor


rng f,

with values of the type set, is defined by

for y holds y ∈ it iff ex x st x ∈ dom f & y = f .x.

One can prove the following propositions:

(10) Y = rng f iff for y holds y ∈ Y iff ex x st x ∈ dom f & y = f .x,

(11) y ∈ rng f iff ex x st x ∈ dom f & y = f .x,

(12) x ∈ dom f implies f .x ∈ rng f,

(13) dom f = ∅ iff rng f = ∅,

(14) dom f = {x} implies rng f = {f .x}.

Now we present two schemes. The scheme FuncEx concerns a constant A that has
the type set and a binary predicate P and states that the following holds

ex f st dom f = A & for x st x ∈ A holds P[x, f .x]

provided the parameters satisfy the following conditions:

• for x,y1,y2 st x ∈ A & P[x, y1] & P[x, y2] holds y1 = y2,

• for x st x ∈ A ex y st P[x, y].

The scheme Lambda concerns a constant A that has the type set and a unary functor
F and states that the following holds

ex f being Function st dom f = A & for x st x ∈ A holds f .x = F(x)

for all values of the parameters.


Next we state several propositions:

(15) X 6= ∅ implies for y ex f st dom f = X & rng f = {y},

(16) (for f,g st dom f = X & dom g = X holds f = g) implies X = ∅,

(17) dom f = dom g & rng f = {y} & rng g = {y} implies f = g,

(18) Y 6= ∅ or X = ∅ implies ex f st X = dom f & rng f ⊆ Y,

(19) (for y st y ∈ Y ex x st x ∈ dom f & y = f .x) implies Y ⊆ rng f.

Let us consider f , g. The functor


g · f,
58 Czeslaw Byliński

yields the type Function and is defined by

(for x holds x ∈ dom it iff x ∈ dom f & f .x ∈ dom g)


& for x st x ∈ dom it holds it.x = g .(f .x).

The following propositions are true:

(20) h = g · f iff (for x holds x ∈ dom h iff x ∈ dom f & f .x ∈ dom g)


& for x st x ∈ dom h holds h.x = g .(f .x),

(21) x ∈ dom (g · f ) iff x ∈ dom f & f .x ∈ dom g,

(22) x ∈ dom (g · f ) implies (g · f ).x = g .(f .x),

(23) x ∈ dom f & f .x ∈ dom g implies (g · f ).x = g .(f .x),

(24) dom (g · f ) ⊆ dom f,

(25) z ∈ rng (g · f ) implies z ∈ rng g,

(26) rng (g · f ) ⊆ rng g,

(27) rng f ⊆ dom g iff dom (g · f ) = dom f,

(28) dom g ⊆ rng f implies rng (g · f ) = rng g,

(29) rng f = dom g implies dom (g · f ) = dom f & rng (g · f ) = rng g,

(30) h · (g · f ) = (h · g) · f,

(31) rng f ⊆ dom g & x ∈ dom f implies (g · f ).x = g .(f .x),

(32) rng f = dom g & x ∈ dom f implies (g · f ).x = g .(f .x),

(33) rng f ⊆ Y & (for g,h st dom g = Y & dom h = Y & g · f = h · f holds g = h)
implies Y = rng f.

Let us consider X. The functor


id X,

with values of the type Function, is defined by

dom it = X & for x st x ∈ X holds it.x = x.

Next we state a number of propositions:

(34) f = id X iff dom f = X & for x st x ∈ X holds f .x = x,

(35) x ∈ X implies (id X).x = x,


Functions and Their Basic Properties 59

(36) dom id X = X & rng id X = X,

(37) dom (f · (id X)) = dom f ∩ X,

(38) x ∈ dom f ∩ X implies f .x = (f · (id X)).x,

(39) dom f ⊆ X implies f · (id X) = f,

(40) x ∈ dom ((id Y ) · f ) iff x ∈ dom f & f .x ∈ Y,

(41) rng f ⊆ Y implies (id Y ) · f = f,

(42) f · (id dom f ) = f & (id rng f ) · f = f,

(43) (id X) · (id Y ) = id (X ∩ Y ),

(44) dom f = X & rng f = X & dom g = X & g · f = f implies g = id X.

Let us consider f . The predicate

f is one-to-one

is defined by

for x1,x2 st x1 ∈ dom f & x2 ∈ dom f & f .x1 = f .x2 holds x1 = x2.

One can prove the following propositions:

(45) f is one-to-one
iff for x1,x2 st x1 ∈ dom f & x2 ∈ dom f & f .x1 = f .x2 holds x1 = x2,

(46) f is one-to-one & g is one-to-one implies g · f is one-to-one ,

(47) g · f is one-to-one & rng f ⊆ dom g implies f is one-to-one ,

(48) g · f is one-to-one & rng f = dom g implies f is one-to-one & g is one-to-one ,

(49) f is one-to-one iff for g,h st


rng g ⊆ dom f & rng h ⊆ dom f & dom g = dom h & f · g = f · h holds g = h,

(50) dom f = X & dom g = X & rng g ⊆ X & f is one-to-one & f · g = f


implies g = id X,

(51) rng (g · f ) = rng g & g is one-to-one implies dom g ⊆ rng f,

(52) id X is one-to-one ,

(53) (ex g st g · f = id dom f ) implies f is one-to-one .


60 Czeslaw Byliński

Let us consider f . Assume that the following holds

f is one-to-one .

The functor
f -1 ,
with values of the type Function, is defined by

dom it = rng f & for y,x holds y ∈ rng f & x = it.y iff x ∈ dom f & y = f .x.

We now state a number of propositions:

(54) f is one-to-one implies (g = f -1 iff


dom g = rng f & for y,x holds y ∈ rng f & x = g .y iff x ∈ dom f & y = f .x),

(55) f is one-to-one implies rng f = dom (f -1 ) & dom f = rng (f -1 ),

(56) f is one-to-one & x ∈ dom f implies x = (f -1 ).(f .x) & x = (f -1 · f ).x,

(57) f is one-to-one & y ∈ rng f implies y = f .((f -1 ).y) & y = (f · f -1 ).y,

(58) f is one-to-one implies dom (f -1 · f ) = dom f & rng (f -1 · f ) = dom f,

(59) f is one-to-one implies dom (f · f -1 ) = rng f & rng (f · f -1 ) = rng f,

(60) f is one-to-one & dom f = rng g & rng f = dom g


& (for x,y st x ∈ dom f & y ∈ dom g holds f .x = y iff g .y = x)
implies g = f -1 ,

(61) f is one-to-one implies f -1 · f = id dom f & f · f -1 = id rng f,

(62) f is one-to-one implies f -1 is one-to-one ,

(63) f is one-to-one & rng f = dom g & g · f = id dom f implies g = f -1 ,

(64) f is one-to-one & rng g = dom f & f · g = id rng f implies g = f -1 ,

(65) f is one-to-one implies (f -1 ) -1 = f,

(66) f is one-to-one & g is one-to-one implies (g · f ) -1 = f -1 · g -1 ,

(67) (id X) -1 = (id X).

Let us consider f , X. The functor

f | X,

yields the type Function and is defined by

dom it = dom f ∩ X & for x st x ∈ dom it holds it.x = f .x.


Functions and Their Basic Properties 61

We now state a number of propositions:

(68) g = f | X iff dom g = dom f ∩ X & for x st x ∈ dom g holds g .x = f .x,

(69) dom (f | X) = dom f ∩ X,

(70) x ∈ dom (f | X) implies (f | X).x = f .x,

(71) x ∈ dom f ∩ X implies (f | X).x = f .x,

(72) x ∈ dom f & x ∈ X implies (f | X).x = f .x,

(73) x ∈ dom f & x ∈ X implies f .x ∈ rng (f | X),

(74) X ⊆ dom f implies dom (f | X) = X,

(75) dom (f | X) ⊆ X,

(76) dom (f | X) ⊆ dom f & rng (f | X) ⊆ rng f,

(77) f | X = f · (id X),

(78) dom f ⊆ X implies f | X = f,

(79) f | (dom f ) = f,

(80) (f | X) | Y = f | (X ∩ Y ),

(81) (f | X) | X = f | X,

(82) X ⊆ Y implies (f | X) | Y = f | X & (f | Y ) | X = f | X,

(83) (g · f ) | X = g · (f | X),

(84) f is one-to-one implies f | X is one-to-one .

Let us consider Y , f . The functor

Y | f,

with values of the type Function, is defined by

(for x holds x ∈ dom it iff x ∈ dom f & f .x ∈ Y )


& for x st x ∈ dom it holds it.x = f .x.

We now state a number of propositions:

(85) g = Y | f iff (for x holds x ∈ dom g iff x ∈ dom f & f .x ∈ Y )


& for x st x ∈ dom g holds g .x = f .x,
62 Czeslaw Byliński

(86) x ∈ dom (Y | f ) iff x ∈ dom f & f .x ∈ Y,

(87) x ∈ dom (Y | f ) implies (Y | f ).x = f .x,

(88) rng (Y | f ) ⊆ Y,

(89) dom (Y | f ) ⊆ dom f & rng (Y | f ) ⊆ rng f,

(90) rng (Y | f ) = rng f ∩ Y,

(91) Y ⊆ rng f implies rng (Y | f ) = Y,

(92) Y | f = (id Y ) · f,

(93) rng f ⊆ Y implies Y | f = f,

(94) (rng f ) | f = f,

(95) Y | (X | f ) = (Y ∩ X) | f,

(96) Y | (Y | f ) = Y | f,

(97) X ⊆ Y implies Y | (X | f ) = X | f & X | (Y | f ) = X | f,

(98) Y | (g · f ) = (Y | g) · f,

(99) f is one-to-one implies Y | f is one-to-one ,

(100) (Y | f ) | X = Y | (f | X).

Let us consider f , X. The functor

f ◦ X,

yields the type set and is defined by

for y holds y ∈ it iff ex x st x ∈ dom f & x ∈ X & y = f .x.

The following propositions are true:

(101) Y = f ◦ X iff for y holds y ∈ Y iff ex x st x ∈ dom f & x ∈ X & y = f .x,

(102) y ∈ f ◦ X iff ex x st x ∈ dom f & x ∈ X & y = f .x,

(103) f ◦ X ⊆ rng f,

(104) f ◦ (X) = f ◦ (dom f ∩ X),

(105) f ◦ (dom f ) = rng f,

(106) f ◦ X ⊆ f ◦ (dom f ),
Functions and Their Basic Properties 63

(107) rng (f | X) = f ◦ X,

(108) f ◦ X = ∅ iff dom f ∩ X = ∅,

(109) f ◦ ∅ = ∅,

(110) X 6= ∅ & X ⊆ dom f implies f ◦ X 6= ∅,

(111) X1 ⊆ X2 implies f ◦ X1 ⊆ f ◦ X2,

(112) f ◦ (X1 ∪ X2) = f ◦ X1 ∪ f ◦ X2,

(113) f ◦ (X1 ∩ X2) ⊆ f ◦ X1 ∩ f ◦ X2,

(114) f ◦ X1 \ f ◦ X2 ⊆ f ◦ (X1 \ X2),

(115) (g · f ) ◦ X = g ◦ (f ◦ X),

(116) rng (g · f ) = g ◦ (rng f ),

(117) x ∈ dom f implies f ◦ {x} = {f .x},

(118) x1 ∈ dom f & x2 ∈ dom f implies f ◦ {x1,x2} = {f .x1,f .x2},

(119) (f | Y ) ◦ X ⊆ f ◦ X,

(120) (Y | f ) ◦ X ⊆ f ◦ X,

(121) f is one-to-one implies f ◦ (X1 ∩ X2) = f ◦ X1 ∩ f ◦ X2,

(122) (for X1,X2 holds f ◦ (X1 ∩ X2) = f ◦ X1 ∩ f ◦ X2)


implies f is one-to-one ,

(123) f is one-to-one implies f ◦ (X1 \ X2) = f ◦ X1 \ f ◦ X2,

(124) (for X1,X2 holds f ◦ (X1 \ X2) = f ◦ X1 \ f ◦ X2) implies f is one-to-one ,

(125) X ∩ Y = ∅ & f is one-to-one implies f ◦ X ∩ f ◦ Y = ∅,

(126) (Y | f ) ◦ X = Y ∩ f ◦ X.

Let us consider f , Y . The functor

f -1 Y,

yields the type set and is defined by

for x holds x ∈ it iff x ∈ dom f & f .x ∈ Y.


64 Czeslaw Byliński

We now state a number of propositions:

(127) X = f -1 Y iff for x holds x ∈ X iff x ∈ dom f & f .x ∈ Y,

(128) x ∈ f -1 Y iff x ∈ dom f & f .x ∈ Y,

(129) f -1 Y ⊆ dom f,

(130) f -1 Y = f -1 (rng f ∩ Y ),

(131) f -1 (rng f ) = dom f,

(132) f -1 ∅ = ∅,

(133) f -1 Y = ∅ iff rng f ∩ Y = ∅,

(134) Y ⊆ rng f implies (f -1 Y = ∅ iff Y = ∅),

(135) Y 1 ⊆ Y 2 implies f -1 Y 1 ⊆ f -1 Y 2,

(136) f -1 (Y 1 ∪ Y 2) = f -1 Y 1 ∪ f -1 Y 2,

(137) f -1 (Y 1 ∩ Y 2) = f -1 Y 1 ∩ f -1 Y 2,

(138) f -1 (Y 1 \ Y 2) = f -1 Y 1 \ f -1 Y 2,

(139) (f | X) -1 Y = X ∩ (f -1 Y ),

(140) (g · f ) -1 Y = f -1 (g -1 Y ),

(141) dom (g · f ) = f -1 (dom g),

(142) y ∈ rng f iff f -1 {y} 6= ∅,

(143) (for y st y ∈ Y holds f -1 {y} 6= ∅) implies Y ⊆ rng f,

(144) (for y st y ∈ rng f ex x st f -1 {y} = {x}) iff f is one-to-one ,

(145) f ◦ (f -1 Y ) ⊆ Y,

(146) X ⊆ dom f implies X ⊆ f -1 (f ◦ X),

(147) Y ⊆ rng f implies f ◦ (f -1 Y ) = Y,

(148) f ◦ (f -1 Y ) = Y ∩ f ◦ (dom f ),

(149) f ◦ (X ∩ f -1 Y ) ⊆ (f ◦ X) ∩ Y,

(150) f ◦ (X ∩ f -1 Y ) = (f ◦ X) ∩ Y,
Functions and Their Basic Properties 65

(151) X ∩ f -1 Y ⊆ f -1 (f ◦ X ∩ Y ),

(152) f is one-to-one implies f -1 (f ◦ X) ⊆ X,

(153) (for X holds f -1 (f ◦ X) ⊆ X) implies f is one-to-one ,

(154) f is one-to-one implies f ◦ X = (f -1 ) -1 X,

(155) f is one-to-one implies f -1 Y = (f -1 ) ◦ Y,

(156) Y = rng f & dom g = Y & dom h = Y & g · f = h · f implies g = h,

(157) f ◦ X1 ⊆ f ◦ X2 & X1 ⊆ dom f & f is one-to-one implies X1 ⊆ X2,

(158) f -1 Y 1 ⊆ f -1 Y 2 & Y 1 ⊆ rng f implies Y 1 ⊆ Y 2,

(159) f is one-to-one iff for y ex x st f -1 {y} ⊆ {x},

(160) rng f ⊆ dom g implies f -1 X ⊆ (g · f ) -1 (g ◦ X).

References
[1] Andrzej Trybulec. Tarski Grothendieck set theory. Formalized Mathematics, 1, 1990.

[2] Zinaida Trybulec and Halina Świe czkowska. Boolean properties of sets. Formalized

Mathematics, 1, 1990.

Received March 3, 1989


66
FORMALIZED MATHEMATICS
Number 1, January 1990
Université Catholique de Louvain

Properties of Subsets

Zinaida Trybulec1
Warsaw University
Bialystok

Summary. The text includes theorems concerning properties of subsets, and


some operations on sets. The functions yielding improper subsets of a set, i.e. the
empty set and the set itself are introduced. Functions and predicates introduced
for sets are redefined. Some theorems about enumerated sets are proved.

The articles [2], [3], and [1] provide the terminology and notation for this paper. In
the sequel E, X denote objects of the type set; x denotes an object of the type Any.
One can prove the following propositions:

(1) E 6= ∅ implies (x is Element of E iff x ∈ E),

(2) x ∈ E implies x is Element of E,

(3) X is Subset of E iff X ⊆ E.

We now define two new functors. Let us consider E. The functor

∅E,

yields the type Subset of E and is defined by

it = ∅.

The functor
Ω E,
with values of the type Subset of E, is defined by

it = E.

We now state two propositions:

(4) ∅ is Subset of X,
1
Supported by RPBP.III-24.C1.
f
c 1990 Fondation Philippe le Hodey
67 ISSN 0777-4028
68 Zinaida Trybulec

(5) X is Subset of X.

In the sequel A, B, C denote objects of the type Subset of E. Next we state


several propositions:

(6) x ∈ A implies x is Element of E,

(7) (for x being Element of E holds x ∈ A implies x ∈ B) implies A ⊆ B,

(8) (for x being Element of E holds x ∈ A iff x ∈ B) implies A = B,

(9) x ∈ A implies x ∈ E,

(10) A 6= ∅ iff ex x being Element of E st x ∈ A.

Let us consider E, A. The functor

Ac,

yields the type Subset of E and is defined by

it = E \ A.

Let us consider B. Let us note that it makes sense to consider the following functors on
restricted areas. Then
A∪B is Subset of E,
A∩B is Subset of E,
A\B is Subset of E,
. B
A− is Subset of E.
One can prove the following propositions:

(11) x ∈ A ∩ B implies x is Element of A & x is Element of B,

(12) x ∈ A ∪ B implies x is Element of A or x is Element of B,

(13) x ∈ A \ B implies x is Element of A,

(14) . B implies x is Element of A or x is Element of B,


x∈A−

(15) (for x being Element of E holds x ∈ A iff x ∈ B or x ∈ C)


implies A = B ∪ C,

(16) (for x being Element of E holds x ∈ A iff x ∈ B & x ∈ C)


implies A = B ∩ C,

(17) (for x being Element of E holds x ∈ A iff x ∈ B & not x ∈ C)


implies A = B \ C,
Properties of Subsets 69

(18) (for x being Element of E holds x ∈ A iff not (x ∈ B iff x ∈ C))


implies A = B − . C,

(19) ∅E = ∅,

(20) Ω E = E,

(21) ∅E = (Ω E) c ,

(22) Ω E = (∅E) c ,

(23) A c = E \ A,

(24) A c c = A,

(25) A ∪ A c = Ω E & A c ∪ A = Ω E,

(26) A ∩ A c = ∅E & A c ∩ A = ∅E,

(27) A ∩ ∅E = ∅E & ∅E ∩ A = ∅E,

(28) A ∪ Ω E = Ω E & Ω E ∪ A = Ω E,

(29) (A ∪ B) c = A c ∩ B c ,

(30) (A ∩ B) c = A c ∪ B c ,

(31) A ⊆ B iff B c ⊆ A c ,

(32) A\B =A∩Bc,

(33) (A \ B) c = A c ∪ B,

(34) . B) c = A ∩ B ∪ A c ∩ B c ,
(A −

(35) A ⊆ B c implies B ⊆ A c ,

(36) A c ⊆ B implies B c ⊆ A,

(37) ∅E ⊆ E,

(38) A ⊆ A c iff A = ∅E,

(39) A c ⊆ A iff A = Ω E,

(40) X ⊆ A & X ⊆ A c implies X = ∅,

(41) (A ∪ B) c ⊆ A c & (A ∪ B) c ⊆ B c ,
70 Zinaida Trybulec

(42) A c ⊆ (A ∩ B) c & B c ⊆ (A ∩ B) c ,

(43) A misses B iff A ⊆ B c ,

(44) A misses B c iff A ⊆ B,

(45) A misses A c ,

(46) A misses B & A c misses B c implies A = B c ,

(47) A ⊆ B & C misses B implies A ⊆ C c ,

(48) (for a being Element of A holds a ∈ B) implies A ⊆ B,

(49) (for x being Element of E holds x ∈ A) implies E = A,

(50) E 6= ∅ implies for A,B


holds A = B c iff for x being Element of E holds x ∈ A iff not x ∈ B,

(51) E 6= ∅ implies for A,B


c
holds A = B iff for x being Element of E holds not x ∈ A iff x ∈ B,

(52) E 6= ∅ implies for A,B


c
holds A = B iff for x being Element of E holds not (x ∈ A iff x ∈ B),

(53) x ∈ A c implies not x ∈ A.

In the sequel x1, x2, x3, x4, x5, x6, x7, x8 will have the type Element of X. One
can prove the following propositions:

(54) X 6= ∅ implies {x1} is Subset of X,

(55) X 6= ∅ implies {x1,x2} is Subset of X,

(56) X 6= ∅ implies {x1,x2,x3} is Subset of X,

(57) X 6= ∅ implies {x1,x2,x3,x4} is Subset of X,

(58) X 6= ∅ implies {x1,x2,x3,x4,x5} is Subset of X,

(59) X 6= ∅ implies {x1,x2,x3,x4,x5,x6} is Subset of X,

(60) X 6= ∅ implies {x1,x2,x3,x4,x5,x6,x7} is Subset of X,

(61) X 6= ∅ implies {x1,x2,x3,x4,x5,x6,x7,x8} is Subset of X.

In the sequel x1, x2, x3, x4, x5, x6, x7, x8 denote objects of the type Any. We
now state several propositions:

(62) x1 ∈ X implies {x1} is Subset of X,


Properties of Subsets 71

(63) x1 ∈ X & x2 ∈ X implies {x1,x2} is Subset of X,

(64) x1 ∈ X & x2 ∈ X & x3 ∈ X implies {x1,x2,x3} is Subset of X,

(65) x1 ∈ X & x2 ∈ X & x3 ∈ X & x4 ∈ X implies {x1,x2,x3,x4} is Subset of X,

(66) x1 ∈ X & x2 ∈ X & x3 ∈ X & x4 ∈ X & x5 ∈ X


implies {x1,x2,x3,x4,x5} is Subset of X,

(67) x1 ∈ X & x2 ∈ X & x3 ∈ X & x4 ∈ X & x5 ∈ X & x6 ∈ X


implies {x1,x2,x3,x4,x5,x6} is Subset of X,

(68) x1 ∈ X & x2 ∈ X & x3 ∈ X & x4 ∈ X & x5 ∈ X & x6 ∈ X & x7 ∈ X


implies {x1,x2,x3,x4,x5,x6,x7} is Subset of X,

(69) x1 ∈ X
& x2 ∈ X & x3 ∈ X & x4 ∈ X & x5 ∈ X & x6 ∈ X & x7 ∈ X & x8 ∈ X
implies {x1,x2,x3,x4,x5,x6,x7,x8} is Subset of X.

The scheme Subset Ex concerns a constant A that has the type set and a unary
predicate P and states that the following holds

ex X being Subset of A st for x holds x ∈ X iff x ∈ A & P[x]

for all values of the parameters.

References
[1] Andrzej Trybulec. Enumerated sets. Formalized Mathematics, 1, 1990.

[2] Andrzej Trybulec. Tarski Grothendieck set theory. Formalized Mathematics, 1, 1990.

[3] Zinaida Trybulec and Halina Świe czkowska. Boolean properties of sets. Formalized

Mathematics, 1, 1990.

Received March 4, 1989


72
FORMALIZED MATHEMATICS
Number 1, January 1990
Université Catholique de Louvain

Relations and Their Basic Properties

Edmund Woronowicz1
Warsaw University
Bialystok

Summary. We define here: mode Relation as a set of pairs, the domain,


the codomain, and the field of relation, the empty and the identity relations, the
composition of relations, the image and the inverse image of a set under a relation.
Two predicates = and ⊆ , and three functions ∪, ∩ and \ are redefined. Basic facts
about the above mentioned notions are presented.

The terminology and notation used in this paper have been introduced in the articles [1]
and [2]. For simplicity we adopt the following convention: A, B, X, Y , Y 1, Y 2 denote
objects of the type set; a, b, c, d, x, y, z denote objects of the type Any. The mode

Relation ,

which widens to the type set, is defined by

x ∈ it implies ex y,z st x = hy, zi.

One can prove the following proposition

(1) for R being set st for x st x ∈ R ex y,z st x = hy, zi holds R is Relation .

In the sequel P , P 1, P 2, Q, R, S will have the type Relation. Next we state


several propositions:

(2) x ∈ R implies ex y,z st x = hy, zi,

(3) A ⊆ R implies A is Relation ,

(4) {hx, yi} is Relation ,

(5) {ha, bi,hc, di} is Relation ,

(6) [:X, Y :] is Relation .


1
Supported by RPBP III.24 C1
f
c 1990 Fondation Philippe le Hodey
73 ISSN 0777-4028
74 Edmund Woronowicz

The scheme Rel Existence deals with a constant A that has the type set, a constant
B that has the type set and a binary predicate P and states that the following holds

ex R being Relation st for x,y holds hx, yi ∈ R iff x ∈ A & y ∈ B & P[x, y]

for all values of the parameters.


Let us consider P , R. Let us note that one can characterize the predicate

P =R

by the following (equivalent) condition:

for a,b holds ha, bi ∈ P iff ha, bi ∈ R.

The following proposition is true

(7) P = R iff for a,b holds ha, bi ∈ P iff ha, bi ∈ R.

For convenience we may adopt another formulas defining notions considered in the
paper. From now on we shall treat them as new definitions.
Let us consider P , R. Let us note that it makes sense to consider the following
functors on restricted areas. Then

P ∩R is Relation ,

P ∪R is Relation ,

P \R is Relation .

Let us note that one can characterize the predicate

P ⊆R

by the following (equivalent) condition:

for a,b holds ha, bi ∈ P implies ha, bi ∈ R.

The following three propositions are true:

(8) P ⊆ R iff for a,b holds ha, bi ∈ P implies ha, bi ∈ R,

(9) X ∩ R is Relation & R ∩ X is Relation ,

(10) R \ X is Relation .

Let us consider R. The functor


dom R,

with values of the type set, is defined by

x ∈ it iff ex y st hx, yi ∈ R.
Relations and Their Basic Properties 75

We now state several propositions:

(11) X = dom R iff for x holds x ∈ X iff ex y st hx, yi ∈ R,

(12) x ∈ dom R iff ex y st hx, yi ∈ R,

(13) dom (P ∪ R) = dom P ∪ dom R,

(14) dom (P ∩ R) ⊆ dom P ∩ dom R,

(15) dom P \ dom R ⊆ dom (P \ R).

Let us consider R. The functor


rng R,

yields the type set and is defined by

y ∈ it iff ex x st hx, yi ∈ R.

One can prove the following propositions:

(16) X = rng R iff for x holds x ∈ X iff ex y st hy, xi ∈ R,

(17) x ∈ rng R iff ex y st hy, xi ∈ R,

(18) x ∈ dom R implies ex y st y ∈ rng R,

(19) y ∈ rng R implies ex x st x ∈ dom R,

(20) hx, yi ∈ R implies x ∈ dom R & y ∈ rng R,

(21) R ⊆ [:dom R,rng R:],

(22) R ∩ [:dom R,rng R:] = R,

(23) R = {hx, yi} implies dom R = {x} & rng R = {y},

(24) R = {ha, bi,hx, yi} implies dom R = {a, x} & rng R = {b, y},

(25) P ⊆ R implies dom P ⊆ dom R & rng P ⊆ rng R,

(26) rng (P ∪ R) = rng P ∪ rng R,

(27) rng (P ∩ R) ⊆ rng P ∩ rng R,

(28) rng P \ rng R ⊆ rng (P \ R).

Let us consider R. The functor


field R,
76 Edmund Woronowicz

yields the type set and is defined by

it = dom R ∪ rng R.

We now state several propositions:

(29) field R = dom R ∪ rng R,

(30) ha, bi ∈ R implies a ∈ field R & b ∈ field R,

(31) P ⊆ R implies field P ⊆ field R,

(32) R = {hx, yi} implies field R = {x, y},

(33) field (P ∪ R) = field P ∪ field R,

(34) field (P ∩ R) ⊆ field P ∩ field R.

Let us consider R. The functor


R˜,

yields the type Relation and is defined by

hx, yi ∈ it iff hy, xi ∈ R.

One can prove the following propositions:

(35) R = P ˜ iff for x,y holds hx, yi ∈ R iff hy, xi ∈ P,

(36) hx, yi ∈ P ˜ iff hy, xi ∈ P,

(37) (R˜)˜ = R,

(38) field R = field (R˜),

(39) (P ∩ R)˜ = P ˜∩ R˜,

(40) (P ∪ R)˜ = P ˜∪ R˜,

(41) (P \ R)˜ = P ˜\ R˜.

Let us consider P , R. The functor

P · R,

with values of the type Relation, is defined by

hx, yi ∈ it iff ex z st hx, zi ∈ P & hz, yi ∈ R.

We now state a number of propositions:

(42) Q = P · R iff for x,y holds hx, yi ∈ Q iff ex z st hx, zi ∈ P & hz, yi ∈ R,
Relations and Their Basic Properties 77

(43) hx, yi ∈ P · R iff ex z st hx, zi ∈ P & hz, yi ∈ R,

(44) dom (P · R) ⊆ dom P,

(45) rng (P · R) ⊆ rng R,

(46) rng R ⊆ dom P implies dom (R · P ) = dom R,

(47) dom P ⊆ rng R implies rng (R · P ) = rng P,

(48) P ⊆ R implies Q · P ⊆ Q · R,

(49) P ⊆ Q implies P · R ⊆ Q · R,

(50) P ⊆ R & Q ⊆ S implies P · Q ⊆ R · S,

(51) P · (R ∪ Q) = (P · R) ∪ (P · Q),

(52) P · (R ∩ Q) ⊆ (P · R) ∩ (P · Q),

(53) (P · R) \ (P · Q) ⊆ P · (R \ Q),

(54) (P · R)˜ = R˜· P ˜,

(55) (P · R) · Q = P · (R · Q).

The constant Ø has the type Relation, and is defined by

not hx, yi ∈ it .

One can prove the following propositions:

(56) R = Ø iff for x,y holds not hx, yi ∈ R,

(57) not hx, yi ∈ Ø ,

(58) Ø ⊆ [:A, B:],

(59) Ø ⊆ R,

(60) dom Ø = ∅ & rng Ø = ∅,

(61) Ø ∩ R = Ø & Ø ∪ R = R,

(62) Ø · R = Ø & R · Ø = Ø,

(63) R · Ø = Ø · R,

(64) dom R = ∅ or rng R = ∅ implies R = Ø ,


78 Edmund Woronowicz

(65) dom R = ∅ iff rng R = ∅,

(66) ؘ = Ø ,

(67) rng R ∩ dom P = ∅ implies R · P = Ø .

Let us consider X. The functor


4 X,

with values of the type Relation, is defined by

hx, yi ∈ it iff x ∈ X & x = y.

The following propositions are true:

(68) P = 4 X iff for x,y holds hx, yi ∈ P iff x ∈ X & x = y,

(69) hx, yi ∈ 4 X iff x ∈ X & x = y,

(70) x ∈ X iff hx, xi ∈ 4 X,

(71) dom 4 X = X & rng 4 X = X,

(72) (4 X)˜ = 4 X,

(73) (for x st x ∈ X holds hx, xi ∈ R) implies 4 X ⊆ R,

(74) hx, yi ∈ (4 X) · R iff x ∈ X & hx, yi ∈ R,

(75) hx, yi ∈ R · 4 Y iff y ∈ Y & hx, yi ∈ R,

(76) R · (4 X) ⊆ R & (4 X) · R ⊆ R,

(77) dom R ⊆ X implies (4 X) · R = R,

(78) (4 dom R) · R = R,

(79) rng R ⊆ Y implies R · (4 Y ) = R,

(80) R · (4 rng R) = R,

(81) 4∅ = Ø,

(82) dom R = X & rng P 2 ⊆ X & P 2 · R = 4 (dom P 1) & R · P 1 = 4 X


implies P 1 = P 2,

(83) dom R = X & rng P 2 = X & P 2 · R = 4 (dom P 1) & R · P 1 = 4 X


implies P 1 = P 2.
Relations and Their Basic Properties 79

Let us consider R, X. The functor

R | X,

with values of the type Relation, is defined by

hx, yi ∈ it iff x ∈ X & hx, yi ∈ R.

We now state a number of propositions:

(84) P = R | X iff for x,y holds hx, yi ∈ P iff x ∈ X & hx, yi ∈ R,

(85) hx, yi ∈ R | X iff x ∈ X & hx, yi ∈ R,

(86) x ∈ dom (R | X) iff x ∈ X & x ∈ dom R,

(87) dom (R | X) ⊆ X,

(88) R | X ⊆ R,

(89) dom (R | X) ⊆ dom R,

(90) dom (R | X) = dom R ∩ X,

(91) X ⊆ dom R implies dom (R | X) = X,

(92) (R | X) · P ⊆ R · P,

(93) P · (R | X) ⊆ P · R,

(94) R | X = (4 X) · R,

(95) R | X = Ø iff (dom R) ∩ X = ∅,

(96) R | X = R ∩ [:X, rng R:],

(97) dom R ⊆ X implies R | X = R,

(98) R | dom R = R,

(99) rng (R | X) ⊆ rng R,

(100) (R | X) | Y = R | (X ∩ Y ),

(101) (R | X) | X = R | X,

(102) X ⊆ Y implies (R | X) | Y = R | X,

(103) Y ⊆ X implies (R | X) | Y = R | Y,

(104) X ⊆ Y implies R | X ⊆ R | Y,
80 Edmund Woronowicz

(105) P ⊆ R implies P | X ⊆ R | X,

(106) P ⊆ R & X ⊆ Y implies P | X ⊆ R | Y,

(107) R | (X ∪ Y ) = (R | X) ∪ (R | Y ),

(108) R | (X ∩ Y ) = (R | X) ∩ (R | Y ),

(109) R | (X \ Y ) = R | X \ R | Y,

(110) R |∅ = Ø,

(111) Ø|X = Ø,

(112) (P · R) | X = (P | X) · R.

Let us consider Y , R. The functor

Y | R,

yields the type Relation and is defined by

hx, yi ∈ it iff y ∈ Y & hx, yi ∈ R.

The following propositions are true:

(113) P = Y | R iff for x,y holds hx, yi ∈ P iff y ∈ Y & hx, yi ∈ R,

(114) hx, yi ∈ Y | R iff y ∈ Y & hx, yi ∈ R,

(115) y ∈ rng (Y | R) iff y ∈ Y & y ∈ rng R,

(116) rng (Y | R) ⊆ Y,

(117) Y | R ⊆ R,

(118) rng (Y | R) ⊆ rng R,

(119) rng (Y | R) = rng R ∩ Y,

(120) Y ⊆ rng R implies rng (Y | R) = Y,

(121) (Y | R) · P ⊆ R · P,

(122) P · (Y | R) ⊆ P · R,

(123) Y | R = R · (4 Y ),

(124) Y | R = R ∩ [:dom R,Y :],

(125) rng R ⊆ Y implies Y | R = R,


Relations and Their Basic Properties 81

(126) rng R | R = R,

(127) Y | (X | R) = (Y ∩ X) | R,

(128) Y | (Y | R) = Y | R,

(129) X ⊆ Y implies Y | (X | R) = X | R,

(130) Y ⊆ X implies Y | (X | R) = Y | R,

(131) X ⊆ Y implies X | R ⊆ Y | R,

(132) P 1 ⊆ P 2 implies Y | P 1 ⊆ Y | P 2,

(133) P 1 ⊆ P 2 & Y 1 ⊆ Y 2 implies Y 1 | P 1 ⊆ Y 2 | P 2,

(134) (X ∪ Y ) | R = (X | R) ∪ (Y | R),

(135) (X ∩ Y ) | R = X | R ∩ Y | R,

(136) (X \ Y ) | R = X | R \ Y | R,

(137) ∅|R = Ø,

(138) Y |Ø = Ø,

(139) Y | (P · R) = P · (Y | R),

(140) (Y | R) | X = Y | (R | X).

Let us consider R, X. The functor

R ◦ X,

yields the type set and is defined by

y ∈ it iff ex x st hx, yi ∈ R & x ∈ X.

One can prove the following propositions:

(141) Y = R ◦ X iff for y holds y ∈ Y iff ex x st hx, yi ∈ R & x ∈ X,

(142) y ∈ R ◦ X iff ex x st hx, yi ∈ R & x ∈ X,

(143) y ∈ R ◦ X iff ex x st x ∈ dom R & hx, yi ∈ R & x ∈ X,

(144) R ◦ X ⊆ rng R,

(145) R ◦ X = R ◦ (dom R ∩ X),

(146) R ◦ dom R = rng R,


82 Edmund Woronowicz

(147) R ◦ X ⊆ R ◦ (dom R),

(148) rng (R | X) = R ◦ X,

(149) R ◦ ∅ = ∅,

(150) Ø ◦ X = ∅,

(151) R ◦ X = ∅ iff dom R ∩ X = ∅,

(152) X 6= ∅ & X ⊆ dom R implies R ◦ X 6= ∅,

(153) R ◦ (X ∪ Y ) = R ◦ X ∪ R ◦ Y,

(154) R ◦ (X ∩ Y ) ⊆ R ◦ X ∩ R ◦ Y,

(155) R ◦ X \ R ◦ Y ⊆ R ◦ (X \ Y ),

(156) X ⊆ Y implies R ◦ X ⊆ R ◦ Y,

(157) P ⊆ R implies P ◦ X ⊆ R ◦ X,

(158) P ⊆ R & X ⊆ Y implies P ◦ X ⊆ R ◦ Y,

(159) (P · R) ◦ X = R ◦ (P ◦ X),

(160) rng (P · R) = R ◦ (rng P ),

(161) (R | X) ◦ Y ⊆ R ◦ Y,

(162) R | X = Ø iff (dom R) ∩ X = ∅,

(163) (dom R) ∩ X ⊆ (R˜) ◦ (R ◦ X).

Let us consider R, Y . The functor

R -1 Y,

with values of the type set, is defined by

x ∈ it iff ex y st hx, yi ∈ R & y ∈ Y.

Next we state a number of propositions:

(164) X = R -1 Y iff for x holds x ∈ X iff ex y st hx, yi ∈ R & y ∈ Y,

(165) x ∈ R -1 Y iff ex y st hx, yi ∈ R & y ∈ Y,

(166) x ∈ R -1 Y iff ex y st y ∈ rng R & hx, yi ∈ R & y ∈ Y,

(167) R -1 Y ⊆ dom R,
Relations and Their Basic Properties 83

(168) R -1 Y = R -1 (rng R ∩ Y ),

(169) R -1 rng R = dom R,

(170) R -1 Y ⊆ R -1 rng R,

(171) R -1 ∅ = ∅,

(172) Ø -1 Y = ∅,

(173) R -1 Y = ∅ iff rng R ∩ Y = ∅,

(174) Y 6= ∅ & Y ⊆ rng R implies R -1 Y 6= ∅,

(175) R -1 (X ∪ Y ) = R -1 X ∪ R -1 Y,

(176) R -1 (X ∩ Y ) ⊆ R -1 Y ∩ R -1 Y,

(177) R -1 X \ R -1 Y ⊆ R -1 (X \ Y ),

(178) X ⊆ Y implies R -1 X ⊆ R -1 Y,

(179) P ⊆ R implies P -1 Y ⊆ R -1 Y,

(180) P ⊆ R & X ⊆ Y implies P -1 X ⊆ R -1 Y,

(181) (P · R) -1 Y = P -1 (R -1 Y ),

(182) dom (P · R) = P -1 (dom R),

(183) (rng R) ∩ Y ⊆ (R˜) -1 (R -1 Y ).

References
[1] Andrzej Trybulec. Tarski Grothendieck set theory. Formalized Mathematics, 1, 1990.

[2] Zinaida Trybulec and Halina Świe czkowska. Boolean properties of sets. Formalized

Mathematics, 1, 1990.

Received March 15, 1989


84
FORMALIZED MATHEMATICS
Number 1, January 1990
Université Catholique de Louvain

Properties of Binary Relations

Edmund Woronowicz1 Anna Zalewska2


Warsaw University Warsaw University
Bialystok Bialystok

Summary. The paper contains definitions of some properties of binary rela-


tions: reflexivity, irreflexivity, symmetry, asymmetry, antisymmetry, connectedness,
strong connectedness, and transitivity. Basic theorems relating the above mentioned
notions are given.

The terminology and notation used here have been introduced in the following articles:
[1], [2], and [3]. For simplicity we adopt the following convention: X will have the type
set; x, y, z will have the type Any; P , R will have the type Relation. We now define
several new predicates. Let us consider R, X. The predicate

R is reflexive in X is defined by x ∈ X implies hx, xi ∈ R.

The predicate

R is irreflexive in X is defined by x ∈ X implies not hx, xi ∈ R.

The predicate
R is symmetric in X

is defined by

x ∈ X & y ∈ X & hx, yi ∈ R implies hy, xi ∈ R.

The predicate
R is antisymmetric in X

is defined by

x ∈ X & y ∈ X & hx, yi ∈ R & hy, xi ∈ R implies x = y.


1
Supported by RPBP III.24 C1.
2
Supported by RPBP III.24 C1.

cf 1990 Fondation Philippe le Hodey


85 ISSN 0777-4028
86 Edmund Woronowicz and Anna Zalewska

The predicate
R is asymmetric in X

is defined by

x ∈ X & y ∈ X & hx, yi ∈ R implies not hy, xi ∈ R.

The predicate
R is connected in X

is defined by

x ∈ X & y ∈ X & x 6= y implies hx, yi ∈ R or hy, xi ∈ R.

The predicate
R is strongly connected in X

is defined by

x ∈ X & y ∈ X implies hx, yi ∈ R or hy, xi ∈ R.

The predicate
R is transitive in X

is defined by

x ∈ X & y ∈ X & z ∈ X & hx, yi ∈ R & hy, zi ∈ R implies hx, zi ∈ R.

We now state several propositions:

(1) R is reflexive in X iff for x st x ∈ X holds hx, xi ∈ R,

(2) R is irreflexive in X iff for x st x ∈ X holds not hx, xi ∈ R,

(3) R is symmetric in X
iff for x,y st x ∈ X & y ∈ X & hx, yi ∈ R holds hy, xi ∈ R,

(4) R is antisymmetric in X
iff for x,y st x ∈ X & y ∈ X & hx, yi ∈ R & hy, xi ∈ R holds x = y,

(5) R is asymmetric in X
iff for x,y st x ∈ X & y ∈ X & hx, yi ∈ R holds not hy, xi ∈ R,

(6) R is connected in X
iff for x,y st x ∈ X & y ∈ X & x 6= y holds hx, yi ∈ R or hy, xi ∈ R,

(7) R is strongly connected in X


iff for x,y st x ∈ X & y ∈ X holds hx, yi ∈ R or hy, xi ∈ R,
Properties of Binary Relations 87

(8) R is transitive in X iff for x,y,z


st x ∈ X & y ∈ X & z ∈ X & hx, yi ∈ R & hy, zi ∈ R holds hx, zi ∈ R.

We now define several new predicates. Let us consider R. The predicate

R is reflexive is defined by R is reflexive in field R.

The predicate

R is irreflexive is defined by R is irreflexive in field R.

The predicate

R is symmetric is defined by R is symmetric in field R.

The predicate

R is antisymmetric is defined by R is antisymmetric in field R.

The predicate

R is asymmetric is defined by R is asymmetric in field R.

The predicate

R is connected is defined by R is connected in field R.

The predicate

R is strongly connected is defined by R is strongly connected in field R.

The predicate

R is transitive is defined by R is transitive in field R.

We now state a number of propositions:

(9) R is reflexive iff R is reflexive in field R,

(10) R is irreflexive iff R is irreflexive in field R,

(11) R is symmetric iff R is symmetric in field R,

(12) R is antisymmetric iff R is antisymmetric in field R,

(13) R is asymmetric iff R is asymmetric in field R,

(14) R is connected iff R is connected in field R,

(15) R is strongly connected iff R is strongly connected in field R,

(16) R is transitive iff R is transitive in field R,


88 Edmund Woronowicz and Anna Zalewska

(17) R is reflexive iff 4 field R ⊆ R,

(18) R is irreflexive iff 4 (field R) ∩ R = Ø ,

(19) R is antisymmetric in X iff R \ 4 X is asymmetric in X,

(20) R is asymmetric in X implies R ∪ 4 X is antisymmetric in X,

(21) R is antisymmetric in X implies R \ 4 X is asymmetric in X,

(22) R is symmetric & R is transitive implies R is reflexive ,

(23) 4 X is symmetric & 4 X is transitive ,

(24) 4 X is antisymmetric & 4 X is reflexive ,

(25) R is irreflexive & R is transitive implies R is asymmetric ,

(26) R is asymmetric implies R is irreflexive & R is antisymmetric ,

(27) R is reflexive implies R˜is reflexive ,

(28) R is irreflexive implies R˜is irreflexive ,

(29) R is reflexive implies dom R = dom (R˜) & rng R = rng (R˜),

(30) R is symmetric iff R = R˜,

(31) P is reflexive & R is reflexive implies P ∪ R is reflexive & P ∩ R is reflexive ,

(32) P is irreflexive & R is irreflexive


implies P ∪ R is irreflexive & P ∩ R is irreflexive ,

(33) P is irreflexive implies P \ R is irreflexive ,

(34) R is symmetric implies R˜is symmetric ,

(35) P is symmetric & R is symmetric


implies P ∪ R is symmetric & P ∩ R is symmetric & P \ R is symmetric ,

(36) R is asymmetric implies R˜is asymmetric ,

(37) P is asymmetric & R is asymmetric implies P ∩ R is asymmetric ,

(38) P is asymmetric implies P \ R is asymmetric ,

(39) R is antisymmetric iff R ∩ (R˜) ⊆ 4 (dom R),

(40) R is antisymmetric implies R˜is antisymmetric ,


Properties of Binary Relations 89

(41) P is antisymmetric
implies P ∩ R is antisymmetric & P \ R is antisymmetric ,

(42) R is transitive implies R˜is transitive ,

(43) P is transitive & R is transitive implies P ∩ R is transitive ,

(44) R is transitive iff R · R ⊆ R,

(45) R is connected iff [:field R,field R:] \ 4 (field R) ⊆ R ∪ R˜,

(46) R is strongly connected implies R is connected & R is reflexive ,

(47) R is strongly connected iff [:field R,field R:] = R ∪ R˜.

References
[1] Andrzej Trybulec. Tarski Grothendieck set theory. Formalized Mathematics, 1, 1990.

[2] Zinaida Trybulec and Halina Świe czkowska. Boolean properties of sets. Formalized

Mathematics, 1, 1990.

[3] Edmund Woronowicz. Relations and their basic properties. Formalized Mathematics,
1, 1990.

Received March 15, 1989


90
FORMALIZED MATHEMATICS
Number 1, January 1990
Université Catholique de Louvain

The Ordinal Numbers

Grzegorz Bancerek1
Warsaw University
Bialystok

Summary. In the beginning of article we show some consequences of the


regularity axiom. In the second part we introduce the successor of a set and the
notions of transitivity and connectedness wrt membership relation. Then we define
ordinal numbers as transitive and connected sets, and we prove some theorems of
them and of their sets. Lastly we introduce the concept of a transfinite sequence
and we show transfinite induction and schemes of defining by transfinite induction.

The notation and terminology used in this paper have been introduced in the following
articles: [2], [3], and [1]. For simplicity we adopt the following convention: X, Y , Z,
A, B, X1, X2, X3, X4, X5, X6 will denote objects of the type set; x will denote an
object of the type Any. Next we state several propositions:

(1) not X ∈ X,

(2) not (X ∈ Y & Y ∈ X),

(3) not (X ∈ Y & Y ∈ Z & Z ∈ X),

(4) not (X1 ∈ X2 & X2 ∈ X3 & X3 ∈ X4 & X4 ∈ X1),

(5) not (X1 ∈ X2 & X2 ∈ X3 & X3 ∈ X4 & X4 ∈ X5 & X5 ∈ X1),

(6) not (X1 ∈ X2 & X2 ∈ X3 & X3 ∈ X4 & X4 ∈ X5 & X5 ∈ X6 & X6 ∈ X1),

(7) Y ∈ X implies not X ⊆ Y.

The scheme Comprehension deals with a constant A that has the type set and a
unary predicate P and states that the following holds

ex B st for Z being set holds Z ∈ B iff Z ∈ A & P[Z]


1
Supported by RPBP III.24 C1

cf 1990 Fondation Philippe le Hodey


91 ISSN 0777-4028
92 Grzegorz Bancerek

for all values of the parameters.


One can prove the following proposition

(8) (for X holds X ∈ A iff X ∈ B) implies A = B.

Let us consider X. The functor


succ X,

with values of the type set, is defined by

it = X ∪ {X}.

Next we state several propositions:

(9) succ X = X ∪ {X},

(10) X ∈ succ X,

(11) succ X 6= ∅,

(12) succ X = succ Y implies X = Y,

(13) x ∈ succ X iff x ∈ X or x = X,

(14) X 6= succ X.

For simplicity we adopt the following convention: a has the type Any; X, Y , Z,
x, y have the type set. We now define two new predicates. Let us consider X. The
predicate

X is ∈-transitive is defined by for x st x ∈ X holds x ⊆ X.

The predicate
X is ∈-connected

is defined by

for x,y st x ∈ X & y ∈ X holds x ∈ y or x = y or y ∈ x.

One can prove the following two propositions:

(15) X is ∈-transitive iff for x st x ∈ X holds x ⊆ X,

(16) X is ∈-connected iff for x,y st x ∈ X & y ∈ X holds x ∈ y or x = y or y ∈ x.

The mode
Ordinal ,

which widens to the type set, is defined by

it is ∈-transitive & it is ∈-connected .


The Ordinal Numbers 93

In the sequel A, B, C will have the type Ordinal. The following propositions are
true:

(17) X is Ordinal iff X is ∈-transitive & X is ∈-connected ,

(18) x ∈ A implies x ⊆ A,

(19) A ∈ B & B ∈ C implies A ∈ C,

(20) x ∈ A & y ∈ A implies x ∈ y or x = y or y ∈ x,

(21) for x,A being Ordinal st x ⊆ A & x 6= A holds x ∈ A,

(22) A ⊆ B & B ∈ C implies A ∈ C,

(23) a ∈ A implies a is Ordinal ,

(24) A ∈ B or A = B or B ∈ A,

(25) A ⊆ B or B ⊆ A,

(26) A ⊆ B or B ∈ A,

(27) ∅ is Ordinal .

The constant 0 has the type Ordinal, and is defined by

it = ∅.

Next we state three propositions:

(28) 0 = ∅,

(29) x is Ordinal implies succ x is Ordinal ,


[
(30) x is Ordinal implies x is Ordinal .

Let us consider A. Let us note that it makes sense to consider the following functors
on restricted areas. Then
succ A is Ordinal ,
[
A is Ordinal .

One can prove the following propositions:

(31) (for x st x ∈ X holds x is Ordinal & x ⊆ X) implies X is Ordinal ,

(32) X ⊆ A & X 6= ∅ implies ex C st C ∈ X & for B st B ∈ X holds C ⊆ B,

(33) A ∈ B iff succ A ⊆ B,


94 Grzegorz Bancerek

(34) A ∈ succ C iff A ⊆ C.

Now we present two schemes. The scheme Ordinal Min concerns a unary predicate
P states that the following holds

ex A st P[A] & for B st P[B] holds A ⊆ B

provided the parameter satisfies the following condition:

• ex A st P[A].

The scheme Transfinite Ind concerns a unary predicate P states that the following
holds

for A holds P[A]

provided the parameter satisfies the following condition:

• for A st for C st C ∈ A holds P[C] holds P[A].

One can prove the following propositions:


[
(35) for X st for a st a ∈ X holds a is Ordinal holds X is Ordinal ,

(36) for X st for a st a ∈ X holds a is Ordinal ex A st X ⊆ A,

(37) not ex X st for x holds x ∈ X iff x is Ordinal ,

(38) not ex X st for A holds A ∈ X,

(39) for X ex A st not A ∈ X & for B st not B ∈ X holds A ⊆ B.

Let us consider A. The predicate


[
A is limit ordinal is defined by A= A.

One can prove the following three propositions:


[
(40) A is limit ordinal iff A = A,

(41) for A holds A is limit ordinal iff for C st C ∈ A holds succ C ∈ A,

(42) not A is limit ordinal iff ex B st A = succ B.

In the sequel F denotes an object of the type Function. The mode

Transfinite-Sequence ,

which widens to the type Function, is defined by

ex A st dom it = A.
The Ordinal Numbers 95

Let us consider Z. The mode

Transfinite-Sequence of Z,

which widens to the type Transfinite-Sequence, is defined by

rng it ⊆ Z.

The following propositions are true:

(43) F is Transfinite-Sequence iff ex A st dom F = A,

(44) F is Transfinite-Sequence of Z iff F is Transfinite-Sequence & rng F ⊆ Z,

(45) ∅ is Transfinite-Sequence of Z.

In the sequel L, L1, L2 will have the type Transfinite-Sequence. The following
proposition is true

(46) dom F is Ordinal implies F is Transfinite-Sequence of rng F.

Let us consider L. Let us note that it makes sense to consider the following functor
on a restricted area. Then
dom L is Ordinal .
We now state a proposition

(47) X ⊆ Y implies
for L being Transfinite-Sequence of X holds L is Transfinite-Sequence of Y.

Let us consider L, A. Let us note that it makes sense to consider the following functor
on a restricted area. Then

L|A is Transfinite-Sequence of rng L.

The following two propositions are true:

(48) for L being Transfinite-Sequence of X


for A holds L | A is Transfinite-Sequence of X,

(49) (for a st a ∈ X holds a is Transfinite-Sequence) & (for L1,L2


st L1 ∈ X & L2 ∈ X holds graph L1 ⊆ graph L2 or graph L2 ⊆ graph L1)
[
implies X is Transfinite-Sequence .

Now we present three schemes. The scheme TS Uniq deals with a constant A that has
the type Ordinal, a unary functor F, a constant B that has the type Transfinite-Sequence
and a constant C that has the type Transfinite-Sequence, and states that the following
holds

B=C
96 Grzegorz Bancerek

provided the parameters satisfy the following conditions:

• dom B = A & for B,L st B ∈ A & L = B | B holds B.B = F(L),

• dom C = A & for B,L st B ∈ A & L = C | B holds C .B = F(L).

The scheme TS Exist deals with a constant A that has the type Ordinal and a unary
functor F and states that the following holds

ex L st dom L = A & for B,L1 st B ∈ A & L1 = L | B holds L.B = F(L1)

for all values of the parameters.


The scheme Func TS concerns a constant A that has the type Transfinite-Sequence,
a unary functor F and a unary functor G and states that the following holds

for B st B ∈ dom A holds A.B = G(A | B)

provided the parameters satisfy the following conditions:

• for A,a holds a = F(A)


iff ex L st a = G(L) & dom L = A & for B st B ∈ A holds L.B = G(L | B),

• for A st A ∈ dom A holds A.A = F(A).

References
[1] Czeslaw Byliński. Functions and their basic properties. Formalized Mathematics, 1,
1990.

[2] Andrzej Trybulec. Tarski Grothendieck set theory. Formalized Mathematics, 1, 1990.

[3] Zinaida Trybulec and Halina Świe czkowska. Boolean properties of sets. Formalized

Mathematics, 1, 1990.

Received March 20, 1989


FORMALIZED MATHEMATICS
Number 1, January 1990
Université Catholique de Louvain

Tuples, Projections and Cartesian Products

Andrzej Trybulec1
Warsaw University
Bialystok

Summary. The purpose of this article is to define projections of ordered pairs,


and to introduce triples and quadruples, and their projections. The theorems in this
paper may be roughly divided into two groups: theorems describing basic properties
of introduced concepts and theorems related to the regularity, analogous to those
proved for ordered pairs by Cz. Byliński [1]. Cartesian products of subsets are
redefined as subsets of Cartesian products.

The notation and terminology used here are introduced in the following papers: [3], [4],
and [2]. For simplicity we adopt the following convention: v, x, x1, x2, x3, x4, y, y1,
y2, y3, y4, z denote objects of the type Any; X, X1, X2, X3, X4, Y , Y 1, Y 2, Y 3, Y 4,
Y 5, Z denote objects of the type set. One can prove the following propositions:

(1) X 6= ∅ implies ex Y st Y ∈ X & Y misses X,

(2) X 6= ∅ implies ex Y st Y ∈ X & for Y 1 st Y 1 ∈ Y holds Y 1 misses X,

(3) X 6= ∅ implies
ex Y st Y ∈ X & for Y 1,Y 2 st Y 1 ∈ Y 2 & Y 2 ∈ Y holds Y 1 misses X,

(4) X 6= ∅ implies ex Y st Y ∈ X
& for Y 1,Y 2,Y 3 st Y 1 ∈ Y 2 & Y 2 ∈ Y 3 & Y 3 ∈ Y holds Y 1 misses X,

(5) X 6= ∅ implies ex Y st Y ∈ X & for Y 1,Y 2,Y 3,Y 4


st Y 1 ∈ Y 2 & Y 2 ∈ Y 3 & Y 3 ∈ Y 4 & Y 4 ∈ Y holds Y 1 misses X,

(6) X 6= ∅ implies ex Y st Y ∈ X & for Y 1,Y 2,Y 3,Y 4,Y 5 st


Y 1 ∈ Y 2 & Y 2 ∈ Y 3 & Y 3 ∈ Y 4 & Y 4 ∈ Y 5 & Y 5 ∈ Y holds Y 1 misses X.
1
Supported by RPBP.III-24.C1.

cf 1990 Fondation Philippe le Hodey


97 ISSN 0777-4028
98 Andrzej Trybulec

We now define two new functors. Let us consider x. Assume there exist x1, x2, of
the type Any such that

x = hx1,x2i.

The functor
x1 ,

is defined by

x = hy1,y2i implies it = y1.

The functor
x2 ,

is defined by

x = hy1,y2i implies it = y2.

We now state a number of propositions:

(7) hx, yi 1 = x & hx, yi 2 = y,

(8) (ex x,y st z = hx, yi) implies hz 1 ,z 2 i = z,

(9) X 6= ∅ implies ex v st v ∈ X & not ex x,y st (x ∈ X or y ∈ X) & v = hx, yi,

(10) z ∈ [:X, Y :] implies z 1 ∈ X & z 2 ∈ Y,

(11) (ex x,y st z = hx, yi) & z 1 ∈ X & z 2 ∈ Y implies z ∈ [:X, Y :],

(12) z ∈ [:{x},Y :] implies z 1 = x & z 2 ∈ Y,

(13) z ∈ [:X, {y}:] implies z 1 ∈ X & z 2 = y,

(14) z ∈ [:{x},{y}:] implies z 1 = x & z 2 = y,

(15) z ∈ [:{x1,x2},Y :] implies (z 1 = x1 or z 1 = x2) & z 2 ∈ Y,

(16) z ∈ [:X, {y1,y2}:] implies z 1 ∈ X & (z 2 = y1 or z 2 = y2),

(17) z ∈ [:{x1,x2},{y}:] implies (z 1 = x1 or z 1 = x2) & z 2 = y,

(18) z ∈ [:{x},{y1,y2}:] implies z 1 = x & (z 2 = y1 or z 2 = y2),

(19) z ∈ [:{x1,x2},{y1,y2}:]
implies (z 1 = x1 or z 1 = x2) & (z 2 = y1 or z 2 = y2),

(20) (ex y,z st x = hy, zi) implies x 6= x 1 & x 6= x 2 .


Tuples, Projections and Cartesian . . . 99

In the sequel xx will have the type Element of X; yy will have the type Element
of Y . One can prove the following propositions:

(21) X 6= ∅ & Y 6= ∅ implies hxx,yyi ∈ [:X, Y :],

(22) X 6= ∅ & Y 6= ∅ implies hxx,yyi is Element of [:X, Y :],

(23) x ∈ [:X, Y :] implies x = hx 1 ,x 2 i,

(24) X 6= ∅ & Y 6= ∅ implies for x being Element of [:X, Y :] holds x = hx 1 ,x 2 i,

(25) [:{x1,x2},{y1,y2}:] = {hx1,y1i,hx1,y2i,hx2,y1i,hx2,y2i},

(26) X 6= ∅ & Y 6= ∅
implies for x being Element of [:X, Y :] holds x 6= x 1 & x 6= x 2 .

Let us consider x1, x2, x3. The functor

hx1,x2,x3i,

is defined by

it = hhx1,x2i,x3i.

One can prove the following three propositions:

(27) hx1,x2,x3i = hhx1,x2i,x3i,

(28) hx1,x2,x3i = hy1,y2,y3i implies x1 = y1 & x2 = y2 & x3 = y3,

(29) X 6= ∅
implies ex v st v ∈ X & not ex x,y,z st (x ∈ X or y ∈ X) & v = hx, y, zi.

Let us consider x1, x2, x3, x4. The functor

hx1,x2,x3,x4i,

is defined by

it = hhx1,x2,x3i,x4i.

The following propositions are true:

(30) hx1,x2,x3,x4i = hhx1,x2,x3i,x4i,

(31) hx1,x2,x3,x4i = hhhx1,x2i,x3i,x4i,

(32) hx1,x2,x3,x4i = hhx1,x2i,x3,x4i,

(33) hx1,x2,x3,x4i = hy1,y2,y3,y4i


implies x1 = y1 & x2 = y2 & x3 = y3 & x4 = y4,
100 Andrzej Trybulec

(34) X 6= ∅ implies ex v
st v ∈ X & not ex x1,x2,x3,x4 st (x1 ∈ X or x2 ∈ X) & v = hx1,x2,x3,x4i,

(35) X1 6= ∅ & X2 6= ∅ & X3 6= ∅ iff [:X1,X2,X3:] 6= ∅.

In the sequel xx1 has the type Element of X1; xx2 has the type Element of X2;
xx3 has the type Element of X3. One can prove the following propositions:

(36) X1 6= ∅ & X2 6= ∅ & X3 6= ∅ implies


([:X1,X2,X3:] = [:Y 1,Y 2,Y 3:] implies X1 = Y 1 & X2 = Y 2 & X3 = Y 3),

(37) [:X1,X2,X3:] 6= ∅ & [:X1,X2,X3:] = [:Y 1,Y 2,Y 3:]


implies X1 = Y 1 & X2 = Y 2 & X3 = Y 3,

(38) [:X, X, X:] = [:Y, Y, Y :] implies X = Y,

(39) [:{x1},{x2},{x3}:] = {hx1,x2,x3i},

(40) [:{x1,y1},{x2},{x3}:] = {hx1,x2,x3i,hy1,x2,x3i},

(41) [:{x1},{x2,y2},{x3}:] = {hx1,x2,x3i,hx1,y2,x3i},

(42) [:{x1},{x2},{x3,y3}:] = {hx1,x2,x3i,hx1,x2,y3i},

(43) [:{x1,y1},{x2,y2},{x3}:] = {hx1,x2,x3i,hy1,x2,x3i,hx1,y2,x3i,hy1,y2,x3i},

(44) [:{x1,y1},{x2},{x3,y3}:] = {hx1,x2,x3i,hy1,x2,x3i,hx1,x2,y3i,hy1,x2,y3i},

(45) [:{x1},{x2,y2},{x3,y3}:] = {hx1,x2,x3i,hx1,y2,x3i,hx1,x2,y3i,hx1,y2,y3i},

(46) [:{x1,y1},{x2,y2},{x3,y3}:] = {hx1,x2,x3i,


hx1,y2,x3i,hx1,x2,y3i,hx1,y2,y3i,hy1,x2,x3i,hy1,y2,x3i,hy1,x2,y3i,hy1,y2,y3i}.

We now define three new functors. Let us consider X1, X2, X3. Assume that the
following holds

X1 6= ∅ & X2 6= ∅ & X3 6= ∅.

Let x have the type Element of [:X1,X2,X3:]. The functor

x1 ,

with values of the type Element of X1, is defined by

x = hx1,x2,x3i implies it = x1.

The functor
x2 ,
Tuples, Projections and Cartesian . . . 101

yields the type Element of X2 and is defined by

x = hx1,x2,x3i implies it = x2.

The functor
x3 ,
with values of the type Element of X3, is defined by

x = hx1,x2,x3i implies it = x3.

One can prove the following propositions:

(47) X1 6= ∅ & X2 6= ∅ & X3 6= ∅ implies for x being Element of [:X1,X2,X3:]


for x1,x2,x3 st x = hx1,x2,x3i holds x 1 = x1 & x 2 = x2 & x 3 = x3,

(48) X1 6= ∅ & X2 6= ∅ & X3 6= ∅


implies for x being Element of [:X1,X2,X3:] holds x = hx 1 ,x 2 ,x 3 i,

(49) X ⊆ [:X, Y, Z:] or X ⊆ [:Y, Z, X:] or X ⊆ [:Z, X, Y :] implies X = ∅,

(50) X1 6= ∅ & X2 6= ∅ & X3 6= ∅ implies for x being Element of [:X1,X2,X3:]


holds x 1 = (x qua Any) 1 1 & x 2 = (x qua Any) 1 2 & x 3 = (x qua Any) 2 ,

(51) X1 6= ∅ & X2 6= ∅ & X3 6= ∅ implies


for x being Element of [:X1,X2,X3:] holds x 6= x 1 & x 6= x 2 & x 6= x 3 ,

(52) [:X1,X2,X3:] meets [:Y 1,Y 2,Y 3:]


implies X1 meets Y 1 & X2 meets Y 2 & X3 meets Y 3,

(53) [:X1,X2,X3,X4:] = [:[:[:X1,X2:],X3:],X4:],

(54) [:[:X1,X2:],X3,X4:] = [:X1,X2,X3,X4:],

(55) X1 6= ∅ & X2 6= ∅ & X3 6= ∅ & X4 6= ∅ iff [:X1,X2,X3,X4:] 6= ∅,

(56) X1 6= ∅ & X2 6= ∅ & X3 6= ∅ & X4 6= ∅ implies


([:X1,X2,X3,X4:] = [:Y 1,Y 2,Y 3,Y 4:]
implies X1 = Y 1 & X2 = Y 2 & X3 = Y 3 & X4 = Y 4),

(57) [:X1,X2,X3,X4:] 6= ∅ & [:X1,X2,X3,X4:] = [:Y 1,Y 2,Y 3,Y 4:]


implies X1 = Y 1 & X2 = Y 2 & X3 = Y 3 & X4 = Y 4,

(58) [:X, X, X, X:] = [:Y, Y, Y, Y :] implies X = Y.

In the sequel xx4 will have the type Element of X4. We now define four new
functors. Let us consider X1, X2, X3, X4. Assume that the following holds
X1 6= ∅ & X2 6= ∅ & X3 6= ∅ & X4 6= ∅.
102 Andrzej Trybulec

Let x have the type Element of [:X1,X2,X3,X4:]. The functor

x1 ,

yields the type Element of X1 and is defined by

x = hx1,x2,x3,x4i implies it = x1.

The functor
x2 ,
with values of the type Element of X2, is defined by

x = hx1,x2,x3,x4i implies it = x2.

The functor
x3 ,
yields the type Element of X3 and is defined by

x = hx1,x2,x3,x4i implies it = x3.

The functor
x4 ,
with values of the type Element of X4, is defined by

x = hx1,x2,x3,x4i implies it = x4.

Next we state several propositions:

(59) X1 6= ∅ & X2 6= ∅ & X3 6= ∅ & X4 6= ∅ implies


for x being Element of [:X1,X2,X3,X4:] for x1,x2,x3,x4
st x = hx1,x2,x3,x4i holds x 1 = x1 & x 2 = x2 & x 3 = x3 & x 4 = x4,

(60) X1 6= ∅ & X2 6= ∅ & X3 6= ∅ & X4 6= ∅


implies for x being Element of [:X1,X2,X3,X4:] holds x = hx 1 ,x 2 ,x 3 ,x 4 i,

(61) X1 6= ∅ & X2 6= ∅ & X3 6= ∅ & X4 6= ∅ implies


for x being Element of [:X1,X2,X3,X4:] holds x 1 = (x qua Any) 1 1 1
& x 2 = (x qua Any) 1 1 2 & x 3 = (x qua Any) 1 2 & x 4 = (x qua Any) 2 ,

(62) X1 6= ∅ & X2 6= ∅ & X3 6= ∅ & X4 6= ∅ implies


for x being Element of [:X1,X2,X3,X4:]
holds x 6= x 1 & x 6= x 2 & x 6= x 3 & x 6= x 4 ,

(63) X1 ⊆ [:X1,X2,X3,X4:] or
X1 ⊆ [:X2,X3,X4,X1:] or X1 ⊆ [:X3,X4,X1,X2:] or X1 ⊆ [:X4,X1,X2,X3:]
implies X1 = ∅,
Tuples, Projections and Cartesian . . . 103

(64) [:X1,X2,X3,X4:] meets [:Y 1,Y 2,Y 3,Y 4:]


implies X1 meets Y 1 & X2 meets Y 2 & X3 meets Y 3 & X4 meets Y 4,

(65) [:{x1},{x2},{x3},{x4}:] = {hx1,x2,x3,x4i},

(66) [:X, Y :] 6= ∅ implies for x being Element of [:X, Y :] holds x 6= x 1 & x 6= x 2 ,

(67) x ∈ [:X, Y :] implies x 6= x 1 & x 6= x 2 .

For simplicity we adopt the following convention: A1 will denote an object of the
type Subset of X1; A2 will denote an object of the type Subset of X2; A3 will denote
an object of the type Subset of X3; A4 will denote an object of the type Subset of
X4; x will denote an object of the type Element of [:X1,X2,X3:]. We now state a
number of propositions:

(68) X1 6= ∅ & X2 6= ∅ & X3 6= ∅ implies


for x1,x2,x3 st x = hx1,x2,x3i holds x 1 = x1 & x 2 = x2 & x 3 = x3,

(69) X1 6= ∅ &
X2 6= ∅ & X3 6= ∅ & (for xx1,xx2,xx3 st x = hxx1,xx2,xx3i holds y1 = xx1)
implies y1 = x 1 ,

(70) X1 6= ∅ &
X2 6= ∅ & X3 6= ∅ & (for xx1,xx2,xx3 st x = hxx1,xx2,xx3i holds y2 = xx2)
implies y2 = x 2 ,

(71) X1 6= ∅ &
X2 6= ∅ & X3 6= ∅ & (for xx1,xx2,xx3 st x = hxx1,xx2,xx3i holds y3 = xx3)
implies y3 = x 3 ,

(72) z ∈ [:X1,X2,X3:]
implies ex x1,x2,x3 st x1 ∈ X1 & x2 ∈ X2 & x3 ∈ X3 & z = hx1,x2,x3i,

(73) hx1,x2,x3i ∈ [:X1,X2,X3:] iff x1 ∈ X1 & x2 ∈ X2 & x3 ∈ X3,

(74) (for z holds


z ∈ Z iff ex x1,x2,x3 st x1 ∈ X1 & x2 ∈ X2 & x3 ∈ X3 & z = hx1,x2,x3i)
implies Z = [:X1,X2,X3:],

(75) X1 6= ∅ & X2 6= ∅ & X3 6= ∅ & Y 1 6= ∅ & Y 2 6= ∅ & Y 3 6= ∅ implies


for x being Element of [:X1,X2,X3:], y being Element of [:Y 1,Y 2,Y 3:]
holds x = y implies x 1 = y 1 & x 2 = y 2 & x 3 = y 3 ,
104 Andrzej Trybulec

(76) for x being Element of [:X1,X2,X3:]


st x ∈ [:A1,A2,A3:] holds x 1 ∈ A1 & x 2 ∈ A2 & x 3 ∈ A3,

(77) X1 ⊆ Y 1 & X2 ⊆ Y 2 & X3 ⊆ Y 3 implies [:X1,X2,X3:] ⊆ [:Y 1,Y 2,Y 3:].

In the sequel x has the type Element of [:X1,X2,X3,X4:]. We now state a number
of propositions:

(78) X1 6= ∅ & X2 6= ∅ & X3 6= ∅ & X4 6= ∅ implies for x1,x2,x3,x4


st x = hx1,x2,x3,x4i holds x 1 = x1 & x 2 = x2 & x 3 = x3 & x 4 = x4,

(79) X1 6= ∅ & X2 6= ∅ & X3 6= ∅ &


X4 6= ∅ & (for xx1,xx2,xx3,xx4 st x = hxx1,xx2,xx3,xx4i holds y1 = xx1)
implies y1 = x 1 ,

(80) X1 6= ∅ & X2 6= ∅ & X3 6= ∅ &


X4 6= ∅ & (for xx1,xx2,xx3,xx4 st x = hxx1,xx2,xx3,xx4i holds y2 = xx2)
implies y2 = x 2 ,

(81) X1 6= ∅ & X2 6= ∅ & X3 6= ∅ &


X4 6= ∅ & (for xx1,xx2,xx3,xx4 st x = hxx1,xx2,xx3,xx4i holds y3 = xx3)
implies y3 = x 3 ,

(82) X1 6= ∅ & X2 6= ∅ & X3 6= ∅ &


X4 6= ∅ & (for xx1,xx2,xx3,xx4 st x = hxx1,xx2,xx3,xx4i holds y4 = xx4)
implies y4 = x 4 ,

(83) z ∈ [:X1,X2,X3,X4:] implies ex x1,x2,x3,x4


st x1 ∈ X1 & x2 ∈ X2 & x3 ∈ X3 & x4 ∈ X4 & z = hx1,x2,x3,x4i,

(84) hx1,x2,x3,x4i ∈ [:X1,X2,X3,X4:]


iff x1 ∈ X1 & x2 ∈ X2 & x3 ∈ X3 & x4 ∈ X4,

(85) (for z holds z ∈ Z iff ex x1,x2,x3,x4


st x1 ∈ X1 & x2 ∈ X2 & x3 ∈ X3 & x4 ∈ X4 & z = hx1,x2,x3,x4i)
implies Z = [:X1,X2,X3,X4:],

(86) X1 6= ∅
& X2 6= ∅ & X3 6= ∅ & X4 6= ∅ & Y 1 6= ∅ & Y 2 6= ∅ & Y 3 6= ∅ & Y 4 6= ∅
implies
for x being Element of [:X1,X2,X3,X4:], y being Element of [:Y 1,Y 2,Y 3,Y 4:]
holds x = y implies x 1 = y 1 & x 2 = y 2 & x 3 = y 3 & x 4 = y 4 ,
Tuples, Projections and Cartesian . . . 105

(87) for x being Element of [:X1,X2,X3,X4:]


st x ∈ [:A1,A2,A3,A4:] holds x 1 ∈ A1 & x 2 ∈ A2 & x 3 ∈ A3 & x 4 ∈ A4,

(88) X1 ⊆ Y 1 & X2 ⊆ Y 2 & X3 ⊆ Y 3 & X4 ⊆ Y 4


implies [:X1,X2,X3,X4:] ⊆ [:Y 1,Y 2,Y 3,Y 4:].

Let us consider X1, X2, A1, A2. Let us note that it makes sense to consider the
following functor on a restricted area. Then

[:A1,A2:] is Subset of [:X1,X2:].

Let us consider X1, X2, X3, A1, A2, A3. Let us note that it makes sense to consider
the following functor on a restricted area. Then

[:A1,A2,A3:] is Subset of [:X1,X2,X3:].

Let us consider X1, X2, X3, X4, A1, A2, A3, A4. Let us note that it makes sense
to consider the following functor on a restricted area. Then

[:A1,A2,A3,A4:] is Subset of [:X1,X2,X3,X4:].

References
[1] Czeslaw Byliński. Some basic properties of sets. Formalized Mathematics, 1, 1990.

[2] Andrzej Trybulec. Enumerated sets. Formalized Mathematics, 1, 1990.

[3] Andrzej Trybulec. Tarski Grothendieck set theory. Formalized Mathematics, 1, 1990.

[4] Zinaida Trybulec and Halina Świe czkowska. Boolean properties of sets. Formalized

Mathematics, 1, 1990.

Received March 30, 1989


106
FORMALIZED MATHEMATICS
Number 1, January 1990
Université Catholique de Louvain

Segments of Natural Numbers and Finite


Sequences

Grzegorz Bancerek1 Krzysztof Hryniewiecki2


Warsaw University Warsaw University
Bialystok Warsaw

Summary. We define the notion of an initial segment of natural numbers and


prove a number of their properties. Using this notion we introduce finite sequences,
subsequences, the empty sequence, a sequence of a domain, and the operation of
concatenation of two sequences.

The papers [4], [5], [2], [3], and [1] provide the notation and terminology for this paper.
For simplicity we adopt the following convention: k, l, m, n, k1, k2 denote objects of
the type Nat; X denotes an object of the type set; x, y, z, y1, y2 denote objects of the
type Any; f denotes an object of the type Function. Let us consider n. The functor

Seg n,

with values of the type set, is defined by

it = { k : 1 ≤ k & k ≤ n }.

Let us consider n. Let us note that it makes sense to consider the following functor
on a restricted area. Then

Seg n is set of Nat .

One can prove the following propositions:

(1) Seg n = { k : 1 ≤ k & k ≤ n },

(2) x ∈ Seg n implies x is Nat ,

(3) k ∈ Seg n iff 1 ≤ k & k ≤ n,


1
Supported by RPBP III.24 C1
2
Supported by RPBP III.24 C1
f
c 1990 Fondation Philippe le Hodey
107 ISSN 0777-4028
108 Grzegorz Bancerek and Krzysztof Hryniewiecki

(4) Seg 0 = ∅ & Seg 1 = {1} & Seg 2 = {1,2},

(5) n = 0 or n ∈ Seg n,

(6) n + 1 ∈ Seg (n + 1),

(7) n ≤ m iff Seg n ⊆ Seg m,

(8) Seg n = Seg m implies n = m,

(9) k ≤ n implies Seg k = Seg k ∩ Seg n & Seg k = Seg n ∩ Seg k,

(10) Seg k = Seg k ∩ Seg n or Seg k = Seg n ∩ Seg k implies k ≤ n,

(11) Seg n ∪ {n + 1} = Seg (n + 1).

The mode
FinSequence ,

which widens to the type Function, is defined by

ex n st dom it = Seg n.

In the sequel p, q, r denote objects of the type FinSequence. Let us consider p.


The functor
len p,

with values of the type Nat, is defined by

Seg it = dom p.

Next we state four propositions:

(12) for f being Function holds f is FinSequence iff ex n st dom f = Seg n,

(13) k = len p iff Seg k = dom p,

(14) ∅ is FinSequence ,

(15) (ex k st dom f ⊆ Seg k) implies ex p st graph f ⊆ graph p.

In the article we present several logical schemes. The scheme SeqEx concerns a
constant A that has the type Nat and a binary predicate P and states that the following
holds

ex p st dom p = Seg A & for k st k ∈ Seg A holds P[k, p.k]

provided the parameters satisfy the following conditions:

• for k,y1,y2 st k ∈ Seg A & P[k, y1] & P[k, y2] holds y1 = y2,
Segments of Natural Numbers and Finite . . . 109

• for k st k ∈ Seg A ex x st P[k, x].

The scheme SeqLambda deals with a constant A that has the type Nat and a unary
functor F and states that the following holds

ex p being FinSequence st len p = A & for k st k ∈ Seg A holds p.k = F(k)

for all values of the parameters.


We now state several propositions:

(16) z ∈ graph p implies ex k st k ∈ dom p & z = hk, p.ki,

(17) X = dom p & X = dom q & (for k st k ∈ X holds p.k = q.k) implies p = q,

(18) for p,q


st len p = len q & for k st 1 ≤ k & k ≤ len p holds p.k = q.k holds p = q,

(19) p | (Seg n) is FinSequence ,

(20) rng p ⊆ dom f implies f · p is FinSequence ,

(21) k ≤ len p & q = p | (Seg k) implies len q = k & dom q = Seg k.

Let D have the type DOMAIN. The mode

FinSequence of D,

which widens to the type FinSequence, is defined by

rng it ⊆ D.

In the sequel D will have the type DOMAIN. The following three propositions
are true:

(22) p is FinSequence of D iff rng p ⊆ D,

(23) for D,k for p being FinSequence of D holds p | (Seg k) is FinSequence of D,

(24) ex p being FinSequence of D st len p = k.

The constant ε has the type FinSequence, and is defined by

len it = 0.

The following propositions are true:

(25) p = ε iff len p = 0,

(26) p = ε iff dom p = ∅,

(27) p = ε iff rng p = ∅,


110 Grzegorz Bancerek and Krzysztof Hryniewiecki

(28) graph ε = ∅,

(29) for D holds ε is FinSequence of D.

Let D have the type DOMAIN. The functor

ε D,

yields the type FinSequence of D and is defined by

it = ε .

One can prove the following four propositions:

(30) p = ε (D) iff dom p = ∅,

(31) ε (D) = ε ,

(32) p = ε (D) iff len p = 0,

(33) p = ε (D) iff rng p = ∅.

Let us consider p, q. The functor

p _ q,

with values of the type FinSequence, is defined by

dom it = Seg (len p + len q) &


(for k st k ∈ dom p holds it.k = p.k) & for k st k ∈ dom q holds it.(len p + k) = q.k.

One can prove the following propositions:

(34) r = p _ q iff dom r = Seg (len p + len q) &


(for k st k ∈ dom p holds r.k = p.k)
& for k st k ∈ dom q holds r.(len p + k) = q.k,

(35) len (p _ q) = len p + len q,

(36) for k st len p + 1 ≤ k & k ≤ len p + len q holds (p _ q).k = q.(k − len p),

(37) len p < k & k ≤ len (p _ q) implies (p _ q).k = q.(k − len p),

(38) k ∈ dom (p _ q) implies k ∈ dom p or ex n st n ∈ dom q & k = len p + n,

(39) dom p ⊆ dom (p _ q),

(40) x ∈ dom q implies ex k st k = x & len p + k ∈ dom (p _ q),

(41) k ∈ dom q implies len p + k ∈ dom (p _ q),


Segments of Natural Numbers and Finite . . . 111

(42) rng p ⊆ rng (p _ q),

(43) rng q ⊆ rng (p _ q),

(44) rng (p _ q) = rng p ∪ rng q,

(45) p _ q _ r = p _ (q _ r),

(46) p _ r = q _ r or r _ p = r _ q implies p = q,

(47) p _ ε = p & ε _ p = p,

(48) p _ q = ε implies p = ε & q = ε .

The arguments of the notions defined below are the following: D which is an object
of the type reserved above; p, q which are objects of the type FinSequence of D. Let
us note that it makes sense to consider the following functor on a restricted area. Then

p_q is FinSequence of D.

One can prove the following proposition

(49) for p,q being FinSequence of D holds p _ q is FinSequence of D.

Let us consider x. The functor


<x>,

with values of the type FinSequence, is defined by

dom it = Seg 1 & it.1 = x.

The following proposition is true

(50) p _ q is FinSequence of D
implies p is FinSequence of D & q is FinSequence of D.

We now define two new functors. Let us consider x, y. The functor

<x, y>,

with values of the type FinSequence, is defined by

it = <x> _ <y>.

Let us consider z. The functor


<x, y, z>,

with values of the type FinSequence, is defined by

it = <x> _ <y> _ <z>.


112 Grzegorz Bancerek and Krzysztof Hryniewiecki

Next we state a number of propositions:

(51) p = <x> iff dom p = Seg 1 & p.1 = x,

(52) graph <x> = {h1,xi},

(53) <x, y> = <x> _ <y>,

(54) <x, y, z> = <x> _ <y> _ <z>,

(55) p = <x> iff dom p = Seg 1 & rng p = {x},

(56) p = <x> iff len p = 1 & rng p = {x},

(57) p = <x> iff len p = 1 & p.1 = x,

(58) (<x> _ p).1 = x,

(59) (p _ <x>).(len p + 1) = x,

(60) <x, y, z> = <x> _ <y, z> & <x, y, z> = <x, y> _ <z>,

(61) p = <x, y> iff len p = 2 & p.1 = x & p.2 = y,

(62) p = <x, y, z> iff len p = 3 & p.1 = x & p.2 = y & p.3 = z,

(63) for p st p 6= ε ex q,x st p = q _ <x>.

The arguments of the notions defined below are the following: D which is an object
of the type reserved above; x which is an object of the type Element of D. Let us note
that it makes sense to consider the following functor on a restricted area. Then

<x> is FinSequence of D.

The arguments of the notions defined below are the following: D which is an object
of the type reserved above; S which is an object of the type SUBDOMAIN of D; x
which is an object of the type Element of S. Let us note that it makes sense to consider
the following functor on a restricted area. Then

<x> is FinSequence of S.

The arguments of the notions defined below are the following: S which is an object
of the type SUBDOMAIN of REAL; x which is an object of the type Element of S.
Let us note that it makes sense to consider the following functor on a restricted area.
Then
<x> is FinSequence of S.
The scheme IndSeq concerns a unary predicate P states that the following holds

for p holds P[p]


Segments of Natural Numbers and Finite . . . 113

provided the parameter satisfies the following conditions:

• P[ε],

• for p,x st P[p] holds P[p _ <x>].

One can prove the following proposition

(64) for p,q,r,s being FinSequence


st p _
q=r _
s & len p ≤ len r ex t being FinSequence st p _ t = r.

Let us consider D. The functor


D*,
yields the type DOMAIN and is defined by

x ∈ it iff x is FinSequence of D.

One can prove the following propositions:

(65) x ∈ D * iff x is FinSequence of D,

(66) ε ∈ D*.

The scheme SepSeq deals with a constant A that has the type DOMAIN and a unary
predicate P and states that the following holds

ex X st for x holds x ∈ X iff ex p st p ∈ A * & P[p] & x = p

for all values of the parameters.


The mode
FinSubsequence ,
which widens to the type Function, is defined by

ex k st dom it ⊆ Seg k.

The following three propositions are true:

(67) f is FinSubsequence iff ex k st dom f ⊆ Seg k,

(68) for p being FinSequence holds p is FinSubsequence ,

(69) for p,X holds p | X is FinSubsequence & X | p is FinSubsequence .

In the sequel p0 has the type FinSubsequence. Let us consider X. Assume there
exists k, such that

X ⊆ Seg k.

The functor
Sgm X,
114 Grzegorz Bancerek and Krzysztof Hryniewiecki

with values of the type FinSequence of NAT, is defined by

rng it = X &
for l,m,k1,k2 st 1 ≤ l & l < m & m ≤ len it & k1 = it.l & k2 = it.m holds k1 < k2.

One can prove the following propositions:

(70) (ex k st X ⊆ Seg k) implies for p being FinSequence of NAT holds


p = Sgm X iff rng p = X & for l,m,k1,k2
st 1 ≤ l & l < m & m ≤ len p & k1 = p.l & k2 = p.m holds k1 < k2,

(71) rng Sgm dom p0 = dom p0 .

Let us consider p0 . The functor


Seq p0 ,

yields the type FinSequence and is defined by

it = p0 · Sgm (dom p0 ).

Next we state two propositions:

(72) for X st ex k st X ⊆ Seg k holds Sgm X = ε iff X = ∅,

(73) p = Seq p0 iff p = p0 · Sgm (dom p0 ).

References
[1] Grzegorz Bancerek. The fundamental properties of natural numbers. Formalized
Mathematics, 1, 1990.

[2] Czeslaw Byliński. Functions and their basic properties. Formalized Mathematics, 1,
1990.

[3] Krzysztof Hryniewiecki. Basic properties of real numbers. Formalized Mathematics,


1, 1990.

[4] Andrzej Trybulec. Tarski Grothendieck set theory. Formalized Mathematics, 1, 1990.

[5] Zinaida Trybulec and Halina Świe czkowska. Boolean properties of sets. Formalized

Mathematics, 1, 1990.

Received April 1, 1989


FORMALIZED MATHEMATICS
Number 1, January 1990
Université Catholique de Louvain

Domains and Their Cartesian Products

Andrzej Trybulec1
Warsaw University
Bialystok

Summary. The article includes: theorems related to domains, theorems re-


lated to Cartesian products presented earlier in various articles and simplified here
by substituting domains for sets and omitting the assumption that the sets involved
must not be empty. Several schemes and theorems related to Fraenkel operator are
given. We also redefine subset yielding functions such as the pair of elements of a
set and the union of two subsets of a set.

The terminology and notation used in this paper have been introduced in the following
articles: [2], [5], [1], [4], and [3]. For simplicity we adopt the following convention: a,
b, c, d will have the type Any; A, B will have the type set; D, X1, X2, X3, X4, Y 1,
Y 2, Y 3, Y 4 will have the type DOMAIN; x1, y1, z1 will have the type Element of
X1; x2 will have the type Element of X2; x3 will have the type Element of X3; x4
will have the type Element of X4. The following three propositions are true:

(1) A is DOMAIN iff A 6= ∅,

(2) D 6= ∅,

(3) a is Element of D implies a ∈ D.

In the sequel A1, B1 will denote objects of the type Subset of X1. One can prove
the following propositions:

(4) A1 = B1 c iff for x1 holds x1 ∈ A1 iff not x1 ∈ B1,

(5) A1 = B1 c iff for x1 holds not x1 ∈ A1 iff x1 ∈ B1,

(6) A1 = B1 c iff for x1 holds not (x1 ∈ A1 iff x1 ∈ B1),

(7) hx1,x2i ∈ [:X1,X2:],


1
Supported by RPBP.III-24.C1.
f
c 1990 Fondation Philippe le Hodey
115 ISSN 0777-4028
116 Andrzej Trybulec

(8) hx1,x2i is Element of [:X1,X2:],

(9) a ∈ [:X1,X2:] implies ex x1,x2 st a = hx1,x2i.

In the sequel x denotes an object of the type Element of [:X1,X2:]. One can prove
the following propositions:

(10) x = hx 1 ,x 2 i,

(11) x 6= x 1 & x 6= x 2 ,

(12) for x,y being Element of [:X1,X2:] st x 1 = y 1 & x 2 = y 2 holds x = y,

(13) [:A, D:] ⊆ [:B, D:] or [:D, A:] ⊆ [:D, B:] implies A ⊆ B,

(14) [:X1,X2:] = [:A, B:] implies X1 = A & X2 = B.

Let us consider X1, X2, x1, x2. Let us note that it makes sense to consider the
following functor on a restricted area. Then

hx1,x2i is Element of [:X1,X2:].

The arguments of the notions defined below are the following: X1, X2 which are
objects of the type reserved above; x which is an object of the type Element of [:X1,X2:].
Let us note that it makes sense to consider the following functors on restricted areas.
Then
x1 is Element of X1,

x2 is Element of X2.

One can prove the following propositions:

(15) a ∈ [:X1,X2,X3:] iff ex x1,x2,x3 st a = hx1,x2,x3i,

(16) (for a holds a ∈ D iff ex x1,x2,x3 st a = hx1,x2,x3i)


implies D = [:X1,X2,X3:],

(17) D = [:X1,X2,X3:] iff for a holds a ∈ D iff ex x1,x2,x3 st a = hx1,x2,x3i,

(18) [:X1,X2,X3:] = [:Y 1,Y 2,Y 3:] implies X1 = Y 1 & X2 = Y 2 & X3 = Y 3.

In the sequel x, y will have the type Element of [:X1,X2,X3:]. Next we state
several propositions:

(19) x = ha, b, ci implies x 1 = a & x 2 = b & x 3 = c,

(20) x = hx 1 ,x 2 ,x 3 i,

(21) x 1 = (x qua Any) 1 1 & x 2 = (x qua Any) 1 2 & x 3 = (x qua Any) 2 ,


Domains and Their Cartesian Products 117

(22) x 6= x 1 & x 6= x 2 & x 6= x 3 ,

(23) hx1,x2,x3i ∈ [:X1,X2,X3:].

Let us consider X1, X2, X3, x1, x2, x3. Let us note that it makes sense to consider
the following functor on a restricted area. Then

hx1,x2,x3i is Element of [:X1,X2,X3:].

The arguments of the notions defined below are the following: X1, X2, X3 which
are objects of the type reserved above; x which is an object of the type Element of
[:X1,X2,X3:]. Let us note that it makes sense to consider the following functors on
restricted areas. Then
x1 is Element of X1,
x2 is Element of X2,
x3 is Element of X3.
The following propositions are true:

(24) a = x 1 iff for x1,x2,x3 st x = hx1,x2,x3i holds a = x1,

(25) b = x 2 iff for x1,x2,x3 st x = hx1,x2,x3i holds b = x2,

(26) c = x 3 iff for x1,x2,x3 st x = hx1,x2,x3i holds c = x3,

(27) hx 1 ,x 2 ,x 3 i = x,

(28) x 1 = y 1 & x 2 = y 2 & x 3 = y 3 implies x = y,

(29) hx1,x2,x3i 1 = x1 & hx1,x2,x3i 2 = x2 & hx1,x2,x3i 3 = x3,

(30) for x being Element of [:X1,X2,X3:], y being Element of [:Y 1,Y 2,Y 3:]
holds x = y implies x 1 = y 1 & x 2 = y 2 & x 3 = y 3 ,

(31) a ∈ [:X1,X2,X3,X4:] iff ex x1,x2,x3,x4 st a = hx1,x2,x3,x4i,

(32) (for a holds a ∈ D iff ex x1,x2,x3,x4 st a = hx1,x2,x3,x4i)


implies D = [:X1,X2,X3,X4:],

(33) D = [:X1,X2,X3,X4:]
iff for a holds a ∈ D iff ex x1,x2,x3,x4 st a = hx1,x2,x3,x4i.

In the sequel x denotes an object of the type Element of [:X1,X2,X3,X4:]. The


following propositions are true:

(34) [:X1,X2,X3,X4:] = [:Y 1,Y 2,Y 3,Y 4:]


implies X1 = Y 1 & X2 = Y 2 & X3 = Y 3 & X4 = Y 4,
118 Andrzej Trybulec

(35) x = ha, b, c, di implies x 1 = a & x 2 = b & x 3 = c & x 4 = d,

(36) x = hx 1 ,x 2 ,x 3 ,x 4 i,

(37) x 1 = (x qua Any) 1 1 1


& x 2 = (x qua Any) 1 1 2 & x 3 = (x qua Any) 1 2 & x 4 = (x qua Any) 2 ,

(38) x 6= x 1 & x 6= x 2 & x 6= x 3 & x 6= x 4 ,

(39) hx1,x2,x3,x4i ∈ [:X1,X2,X3,X4:].

Let us consider X1, X2, X3, X4, x1, x2, x3, x4. Let us note that it makes sense to
consider the following functor on a restricted area. Then

hx1,x2,x3,x4i is Element of [:X1,X2,X3,X4:].

The arguments of the notions defined below are the following: X1, X2, X3, X4
which are objects of the type reserved above; x which is an object of the type Element
of [:X1,X2,X3,X4:]. Let us note that it makes sense to consider the following functors
on restricted areas. Then

x1 is Element of X1,

x2 is Element of X2,

x3 is Element of X3,

x4 is Element of X4.

The following propositions are true:

(40) a = x 1 iff for x1,x2,x3,x4 st x = hx1,x2,x3,x4i holds a = x1,

(41) b = x 2 iff for x1,x2,x3,x4 st x = hx1,x2,x3,x4i holds b = x2,

(42) c = x 3 iff for x1,x2,x3,x4 st x = hx1,x2,x3,x4i holds c = x3,

(43) d = x 4 iff for x1,x2,x3,x4 st x = hx1,x2,x3,x4i holds d = x4,

(44) for x being Element of [:X1,X2,X3,X4:] holds hx 1 ,x 2 ,x 3 ,x 4 i = x,

(45) for x,y being Element of [:X1,X2,X3,X4:]


st x 1 = y 1 & x 2 = y 2 & x 3 = y 3 & x 4 = y 4 holds x = y,

(46) hx1,x2,x3,x4i 1 = x1
& hx1,x2,x3,x4i 2 = x2 & hx1,x2,x3,x4i 3 = x3 & hx1,x2,x3,x4i 4 = x4,

(47) for x being Element of [:X1,X2,X3,X4:], y being Element of [:Y 1,Y 2,Y 3,Y 4:]
holds x = y implies x 1 = y 1 & x 2 = y 2 & x 3 = y 3 & x 4 = y 4 .
Domains and Their Cartesian Products 119

In the sequel A2 will denote an object of the type Subset of X2; A3 will denote
an object of the type Subset of X3; A4 will denote an object of the type Subset of
X4. In the article we present several logical schemes. The scheme Fraenkel1 deals with
a unary predicate P states that the following holds

for X1 holds { x1 : P[x1] } is Subset of X1

for all values of the parameter.


The scheme Fraenkel2 deals with a binary predicate P states that the following holds

for X1,X2 holds { hx1,x2i : P[x1,x2] } is Subset of [:X1,X2:]

for all values of the parameter.


The scheme Fraenkel3 concerns a ternary predicate P states that the following holds

for X1,X2,X3 holds { hx1,x2,x3i : P[x1,x2,x3] } is Subset of [:X1,X2,X3:]

for all values of the parameter.


The scheme Fraenkel4 deals with a 4-ary predicate P states that the following holds

for X1,X2,X3,X4
holds { hx1,x2,x3,x4i : P[x1,x2,x3,x4] } is Subset of [:X1,X2,X3,X4:]

for all values of the parameter.


The scheme Fraenkel5 concerns a unary predicate P and a unary predicate Q and
states that the following holds

for X1 st for x1 holds P[x1] implies Q[x1] holds { y1 : P[y1] } ⊆ { z1 : Q[z1] }

for all values of the parameters.


The scheme Fraenkel6 deals with a unary predicate P and a unary predicate Q and
states that the following holds

for X1 st for x1 holds P[x1] iff Q[x1] holds { y1 : P[y1] } = { z1 : Q[z1] }

for all values of the parameters.


Next we state several propositions:

(48) X1 = { x1 : not contradiction },

(49) [:X1,X2:] = { hx1,x2i : not contradiction },

(50) [:X1,X2,X3:] = { hx1,x2,x3i : not contradiction },

(51) [:X1,X2,X3,X4:] = { hx1,x2,x3,x4i : not contradiction },

(52) A1 = { x1 : x1 ∈ A1 }.
120 Andrzej Trybulec

Let us consider X1, X2, A1, A2. Let us note that it makes sense to consider the
following functor on a restricted area. Then

[:A1,A2:] is Subset of [:X1,X2:].

Next we state a proposition

(53) [:A1,A2:] = { hx1,x2i : x1 ∈ A1 & x2 ∈ A2 }.

Let us consider X1, X2, X3, A1, A2, A3. Let us note that it makes sense to consider
the following functor on a restricted area. Then

[:A1,A2,A3:] is Subset of [:X1,X2,X3:].

Next we state a proposition

(54) [:A1,A2,A3:] = { hx1,x2,x3i : x1 ∈ A1 & x2 ∈ A2 & x3 ∈ A3 }.

Let us consider X1, X2, X3, X4, A1, A2, A3, A4. Let us note that it makes sense
to consider the following functor on a restricted area. Then

[:A1,A2,A3,A4:] is Subset of [:X1,X2,X3,X4:].

Next we state a number of propositions:

(55) [:A1,A2,A3,A4:]
= { hx1,x2,x3,x4i : x1 ∈ A1 & x2 ∈ A2 & x3 ∈ A3 & x4 ∈ A4 },

(56) ∅X1 = { x1 : contradiction },

(57) A1 c = { x1 : not x1 ∈ A1 },

(58) A1 ∩ B1 = { x1 : x1 ∈ A1 & x1 ∈ B1 },

(59) A1 ∪ B1 = { x1 : x1 ∈ A1 or x1 ∈ B1 },

(60) A1 \ B1 = { x1 : x1 ∈ A1 & not x1 ∈ B1 },

(61) . B1 = { x1 : x1 ∈ A1 & not x1 ∈ B1 or not x1 ∈ A1 & x1 ∈ B1 },


A1 −

(62) . B1 = { x1 : not x1 ∈ A1 iff x1 ∈ B1 },


A1 −

(63) . B1 = { x1 : x1 ∈ A1 iff not x1 ∈ B1 },


A1 −

(64) . B1 = { x1 : not (x1 ∈ A1 iff x1 ∈ B1) }.


A1 −

In the sequel x1, x2, x3, x4, x5, x6, x7, x8 will have the type Element of D. We
now state several propositions:

(65) {x1} is Subset of D,


Domains and Their Cartesian Products 121

(66) {x1,x2} is Subset of D,

(67) {x1,x2,x3} is Subset of D,

(68) {x1,x2,x3,x4} is Subset of D,

(69) {x1,x2,x3,x4,x5} is Subset of D,

(70) {x1,x2,x3,x4,x5,x6} is Subset of D,

(71) {x1,x2,x3,x4,x5,x6,x7} is Subset of D,

(72) {x1,x2,x3,x4,x5,x6,x7,x8} is Subset of D.

Let us consider D. Let x1 have the type Element of D. Let us note that it makes
sense to consider the following functor on a restricted area. Then

{x1} is Subset of D.

Let x2 have the type Element of D. Let us note that it makes sense to consider the
following functor on a restricted area. Then

{x1,x2} is Subset of D.

Let x3 have the type Element of D. Let us note that it makes sense to consider the
following functor on a restricted area. Then

{x1,x2,x3} is Subset of D.

Let x4 have the type Element of D. Let us note that it makes sense to consider the
following functor on a restricted area. Then

{x1,x2,x3,x4} is Subset of D.

Let x5 have the type Element of D. Let us note that it makes sense to consider the
following functor on a restricted area. Then

{x1,x2,x3,x4,x5} is Subset of D.

Let x6 have the type Element of D. Let us note that it makes sense to consider the
following functor on a restricted area. Then

{x1,x2,x3,x4,x5,x6} is Subset of D.

Let x7 have the type Element of D. Let us note that it makes sense to consider the
following functor on a restricted area. Then

{x1,x2,x3,x4,x5,x6,x7} is Subset of D.
122 Andrzej Trybulec

Let x8 have the type Element of D. Let us note that it makes sense to consider the
following functor on a restricted area. Then

{x1,x2,x3,x4,x5,x6,x7,x8} is Subset of D.

Let us consider X1, A1. Let us note that it makes sense to consider the following
functor on a restricted area. Then

A1 c is Subset of X1.

Let us consider B1. Let us note that it makes sense to consider the following functors
on restricted areas. Then

A1 ∪ B1 is Subset of X1,

A1 ∩ B1 is Subset of X1,

A1 \ B1 is Subset of X1,
. B1
A1 − is Subset of X1.

References
[1] Andrzej Trybulec. Enumerated sets. Formalized Mathematics, 1, 1990.

[2] Andrzej Trybulec. Tarski Grothendieck set theory. Formalized Mathematics, 1, 1990.

[3] Andrzej Trybulec. Tuples, projections and Cartesian products. Formalized Mathe-
matics, 1, 1990.

[4] Zinaida Trybulec. Properties of subsets. Formalized Mathematics, 1, 1990.

[5] Zinaida Trybulec and Halina Świe czkowska. Boolean properties of sets. Formalized

Mathematics, 1, 1990.

Received April 3, 1989


FORMALIZED MATHEMATICS
Number 1, January 1990
Université Catholique de Louvain

The Well Ordering Relations

Grzegorz Bancerek1
Warsaw University
Bialystok

Summary. Some theorems about well ordering relations are proved. The goal
of the article is to prove that every two well ordering relations are either isomorphic
or one of them is isomorphic to a segment of the other. The following concepts are
defined: the segment of a relation induced by an element, well founded relations,
well ordering relations, the restriction of a relation to a set, and the isomorphism
of two relations. A number of simple facts is presented.

The terminology and notation used here are introduced in the following papers: [2], [3],
[4], [5], and [1]. For simplicity we adopt the following convention: a, b, c, x denote
objects of the type Any; X, Y , Z denote objects of the type set. The scheme
Extensionality concerns a constant A that has the type set, a constant B that has the
type set and a unary predicate P and states that the following holds

A=B

provided the parameters satisfy the following conditions:

• for a holds a ∈ A iff P[a],

• for a holds a ∈ B iff P[a].

In the sequel R, S, T will have the type Relation. Let us consider R, a. The
functor
R −Seg a,
with values of the type set, is defined by

x ∈ it iff x 6= a & hx, ai ∈ R.

One can prove the following propositions:

(1) for R,Y,a holds Y = R −Seg (a) iff for b holds b ∈ Y iff b 6= a & hb, ai ∈ R,
1
Supported by RPBP III.24 C1.

cf 1990 Fondation Philippe le Hodey


123 ISSN 0777-4028
124 Grzegorz Bancerek

(2) x ∈ field R or R −Seg (x) = ∅.

We now define two new predicates. Let us consider R. The predicate

R is well founded

is defined by

for Y st Y ⊆ field R & Y 6= ∅ ex a st a ∈ Y & R −Seg (a) ∩ Y = ∅.

Let us consider X. The predicate

R is well founded in X

is defined by

for Y st Y ⊆ X & Y 6= ∅ ex a st a ∈ Y & R −Seg (a) ∩ Y = ∅.

One can prove the following three propositions:

(3) for R holds R is well founded


iff for Y st Y ⊆ field R & Y 6= ∅ ex a st a ∈ Y & R −Seg (a) ∩ Y = ∅,

(4) for R,X holds R is well founded in X


iff for Y st Y ⊆ X & Y 6= ∅ ex a st a ∈ Y & R −Seg (a) ∩ Y = ∅,

(5) R is well founded iff R is well founded in field R.

We now define two new predicates. Let us consider R. The predicate

R is well-ordering-relation

is defined by

R is reflexive
& R is transitive & R is antisymmetric & R is connected & R is well founded .

Let us consider X. The predicate

R well orders X

is defined by

R is reflexive in X & R is transitive in X


& R is antisymmetric in X & R is connected in X & R is well founded in X.

The following propositions are true:

(6) for R holds R is well-ordering-relation iff R is reflexive


& R is transitive & R is antisymmetric & R is connected & R is well founded ,
The Well Ordering Relations 125

(7) for R,X holds R well orders X iff R is reflexive in X & R is transitive in X
& R is antisymmetric in X & R is connected in X & R is well founded in X,

(8) R well orders field R iff R is well-ordering-relation ,

(9) R well orders X implies


for Y st Y ⊆ X & Y 6= ∅ ex a st a ∈ Y & for b st b ∈ Y holds ha, bi ∈ R,

(10) R is well-ordering-relation implies


for Y st Y ⊆ field R & Y 6= ∅ ex a st a ∈ Y & for b st b ∈ Y holds ha, bi ∈ R,

(11) for R st R is well-ordering-relation & field R 6= ∅


ex a st a ∈ field R & for b st b ∈ field R holds ha, bi ∈ R,

(12) for R st R is well-ordering-relation & field R 6= ∅ for a st a ∈ field R holds


(for b st b ∈ field R holds hb, ai ∈ R) or ex b st b ∈ field R
& ha, bi ∈ R & for c st c ∈ field R & ha, ci ∈ R holds c = a or hb, ci ∈ R.

In the sequel F , G have the type Function. Next we state a proposition

(13) R −Seg (a) ⊆ field R.

Let us consider R, Y . The functor

R |2 Y,

yields the type Relation and is defined by

it = R ∩ [:Y, Y :].

We now state a number of propositions:

(14) R |2 Y = R ∩ [:Y, Y :],

(15) R |2 X ⊆ R & R |2 X ⊆ [:X, X:],

(16) x ∈ R |2 X iff x ∈ R & x ∈ [:X, X:],

(17) R |2 X = X | R | X,

(18) R |2 X = X | (R | X),

(19) x ∈ field (R |2 X) implies x ∈ field R & x ∈ X,

(20) field (R |2 X) ⊆ field R & field (R |2 X) ⊆ X,

(21) (R |2 X) −Seg (a) ⊆ R −Seg (a),


126 Grzegorz Bancerek

(22) R is reflexive implies R |2 X is reflexive ,

(23) R is connected implies R |2 Y is connected ,

(24) R is transitive implies R |2 Y is transitive ,

(25) R is antisymmetric implies R |2 Y is antisymmetric ,

(26) (R |2 X) |2 Y = R |2 (X ∩ Y ),

(27) (R |2 X) |2 Y = (R |2 Y ) |2 X,

(28) (R |2 Y ) |2 Y = R |2 Y,

(29) Z ⊆ Y implies (R |2 Y ) |2 Z = R |2 Z,

(30) R |2 field R = R,

(31) R is well founded implies R |2 X is well founded ,

(32) R is well-ordering-relation implies R |2 Y is well-ordering-relation ,

(33) R is well-ordering-relation
implies R −Seg (a) ⊆ R −Seg (b) or R −Seg (b) ⊆ R −Seg (a),

(34) R is well-ordering-relation implies R |2 (R −Seg (a)) is well-ordering-relation ,

(35) R is well-ordering-relation & a ∈ field R & b ∈ R −Seg (a)


implies (R |2 (R −Seg (a))) −Seg (b) = R −Seg (b),

(36) R is well-ordering-relation & Y ⊆ field R implies


(Y = field R or (ex a st a ∈ field R & Y = R −Seg (a))
iff for a st a ∈ Y for b st hb, ai ∈ R holds b ∈ Y ),

(37) R is well-ordering-relation & a ∈ field R & b ∈ field R


implies (ha, bi ∈ R iff R −Seg (a) ⊆ R −Seg (b)),

(38) R is well-ordering-relation & a ∈ field R & b ∈ field R


implies (R −Seg (a) ⊆ R −Seg (b) iff a = b or a ∈ R −Seg (b)),

(39) R is well-ordering-relation & X ⊆ field R implies field (R |2 X) = X,

(40) R is well-ordering-relation implies field (R |2 R −Seg (a)) = R −Seg (a),

(41) R is well-ordering-relation implies


for Z st for a st a ∈ field R & R −Seg (a) ⊆ Z holds a ∈ Z holds field R ⊆ Z,
The Well Ordering Relations 127

(42) R is well-ordering-relation &


a ∈ field R & b ∈ field R & (for c st c ∈ R −Seg (a) holds hc, bi ∈ R & c 6= b)
implies ha, bi ∈ R,

(43) R is well-ordering-relation & dom F = field R & rng F ⊆ field R


& (for a,b st ha, bi ∈ R & a 6= b holds hF .a,F .bi ∈ R & F .a 6= F .b)
implies for a st a ∈ field R holds ha, F .ai ∈ R.

Let us consider R, S, F . The predicate

F is isomorphism of R, S

is defined by

dom F = field R & rng F = field S &


F is one-to-one & for a,b holds ha, bi ∈ R iff a ∈ field R & b ∈ field R & hF .a,F .bi ∈ S.

Next we state two propositions:

(44) F is isomorphism of R, S iff dom F = field R & rng F = field S &


F is one-to-one
& for a,b holds ha, bi ∈ R iff a ∈ field R & b ∈ field R & hF .a,F .bi ∈ S,

(45) F is isomorphism of R, S
implies for a,b st ha, bi ∈ R & a 6= b holds hF .a,F .bi ∈ S & F .a 6= F .b.

Let us consider R, S. The predicate

R, S are isomorphic is defined by ex F st F is isomorphism of R, S.

We now state a number of propositions:

(46) R, S are isomorphic iff ex F st F is isomorphism of R, S,

(47) id (field R) is isomorphism of R, R,

(48) R, R are isomorphic ,

(49) F is isomorphism of R, S implies F -1 is isomorphism of S, R,

(50) R, S are isomorphic implies S, R are isomorphic ,

(51) F is isomorphism of R, S & G is isomorphism of S, T


implies G · F is isomorphism of R, T,

(52) R, S are isomorphic & S, T are isomorphic implies R, T are isomorphic ,


128 Grzegorz Bancerek

(53) F is isomorphism of R, S implies (R is reflexive implies S is reflexive) &


(R is transitive implies S is transitive) &
(R is connected implies S is connected) &
(R is antisymmetric implies S is antisymmetric)
& (R is well founded implies S is well founded),

(54) R is well-ordering-relation & F is isomorphism of R, S


implies S is well-ordering-relation ,

(55) R is well-ordering-relation implies for F,G


st F is isomorphism of R, S & G is isomorphism of R, S holds F = G.

Let us consider R, S. Assume that the following holds

R is well-ordering-relation & R, S are isomorphic .

The functor
canonical isomorphism of (R, S),

yields the type Function and is defined by

it is isomorphism of R, S.

The following propositions are true:

(56) R is well-ordering-relation & R, S are isomorphic


implies (F = canonical isomorphism of (R, S) iff F is isomorphism of R, S),

(57) R is well-ordering-relation
implies for a st a ∈ field R holds not R, R |2 (R −Seg (a)) are isomorphic ,

(58) R is well-ordering-relation & a ∈ field R & b ∈ field R & a 6= b


implies not R |2 (R −Seg (a)),R |2 (R −Seg (b)) are isomorphic ,

(59) R is well-ordering-relation & Z ⊆ field R & F is isomorphism of R, S implies


F | Z is isomorphism of R |2 Z,S |2 (F ◦ Z)
& R |2 Z,S |2 (F ◦ Z) are isomorphic ,

(60) R is well-ordering-relation & F is isomorphism of R, S implies


for a st a ∈ field R ex b st b ∈ field S & F ◦ (R −Seg (a)) = S −Seg (b),

(61) R is well-ordering-relation & F is isomorphism of R, S implies for a st


a ∈ field R
ex b st b ∈ field S & R |2 (R −Seg (a)),S |2 (S −Seg (b)) are isomorphic ,
The Well Ordering Relations 129

(62) R is well-ordering-relation & S is well-ordering-relation & a ∈ field R &


b ∈ field S & c ∈ field S & R, S |2 (S −Seg (b)) are isomorphic
& R |2 (R −Seg (a)),S |2 (S −Seg (c)) are isomorphic
implies S −Seg (c) ⊆ S −Seg (b) & hc, bi ∈ S,

(63) R is well-ordering-relation & S is well-ordering-relation implies


R, S are isomorphic or
(ex a st a ∈ field R & R |2 (R −Seg (a)),S are isomorphic)
or ex a st a ∈ field S & R, S |2 (S −Seg (a)) are isomorphic ,

(64) Y ⊆ field R & R is well-ordering-relation implies R, R |2 Y are isomorphic


or ex a st a ∈ field R & R |2 (R −Seg (a)),R |2 Y are isomorphic .

References
[1] Czeslaw Byliński. Functions and their basic properties. Formalized Mathematics, 1,
1990.

[2] Andrzej Trybulec. Tarski Grothendieck set theory. Formalized Mathematics, 1, 1990.

[3] Zinaida Trybulec and Halina Świe czkowska. Boolean properties of sets. Formalized

Mathematics, 1, 1990.

[4] Edmund Woronowicz. Relations and their basic properties. Formalized Mathematics,
1, 1990.

[5] Edmund Woronowicz and Anna Zalewska. Properties of binary relations. Formalized
Mathematics, 1, 1990.

Received April 4, 1989


130
FORMALIZED MATHEMATICS
Number 1, January 1990
Université Catholique de Louvain

A Model of ZF Set Theory Language

Grzegorz Bancerek1
Warsaw University
Bialystok

Summary. The goal of this article is to construct a language of the ZF set the-
ory and to develop a notational and conceptual base which facilitates a convenient
usage of the language.

The articles [5], [6], [3], [4], [1], and [2] provide the terminology and notation for this
paper. For simplicity we adopt the following convention: k, n will have the type Nat;
D will have the type DOMAIN; a will have the type Any; p, q will have the type
FinSequence of NAT. The constant VAR has the type SUBDOMAIN of NAT, and is
defined by
it = { k : 5 ≤ k }.

The following proposition is true

(1) VAR = { k : 5 ≤ k }.

Variable stands for Element of VAR .


One can prove the following proposition
(2) a is Variable iff a is Element of VAR .

Let us consider n. The functor


ξ n,
with values of the type Variable, is defined by

it = 5 + n.

One can prove the following proposition


(3) ξ n = 5 + n.
1
Supported by RPBP III.24 C1.

c f 1990 Fondation Philippe le Hodey


131 ISSN 0777-4028
132 Grzegorz Bancerek

In the sequel x, y, z, t denote objects of the type Variable. Let us consider x. Let
us note that it makes sense to consider the following functor on a restricted area. Then

<x> is FinSequence of NAT .

We now define two new functors. Let us consider x, y. The functor

x - y,

with values of the type FinSequence of NAT, is defined by

it = <0> _ <x> _ <y>.

The functor
x  y,

yields the type FinSequence of NAT and is defined by

it = <1> _ <x> _ <y>.

Next we state four propositions:

(4) x - y = <0> _ <x> _ <y>,

(5) x  y = <1> _ <x> _ <y>,

(6) x - y = z - t implies x = z & y = t,

(7) x  y = z  t implies x = z & y = t.

We now define two new functors. Let us consider p. The functor

¬ p,

with values of the type FinSequence of NAT, is defined by

it = <2> _ p.

Let us consider q. The functor


p ∧ q,

with values of the type FinSequence of NAT, is defined by

it = <3> _ p _ q.

Next we state three propositions:

(8) ¬ p = <2> _ p,

(9) p ∧ q = <3> _ p _ q,

(10) ¬ p = ¬ q implies p = q.
A Model of ZF Set Theory Language 133

Let us consider x, p. The functor

∀ (x, p),

yields the type FinSequence of NAT and is defined by

it = <4> _ <x> _ p.

The following propositions are true:

(11) ∀ (x, p) = <4> _ <x> _ p,

(12) ∀ (x, p) = ∀ (y, q) implies x = y & p = q.

The constant WFF has the type DOMAIN, and is defined by

(for a st a ∈ it holds a is FinSequence of NAT) &


(for x,y holds x - y ∈ it & x  y ∈ it) & (for p st p ∈ it holds ¬ p ∈ it) &
(for p,q st p ∈ it & q ∈ it holds p ∧ q ∈ it) & (for x,p st p ∈ it holds ∀ (x, p) ∈ it) &
for D st
(for a st a ∈ D holds a is FinSequence of NAT) &
(for x,y holds x - y ∈ D & x  y ∈ D) & (for p st p ∈ D holds ¬ p ∈ D)
& (for p,q st p ∈ D & q ∈ D holds p ∧ q ∈ D) & for x,p st p ∈ D holds ∀ (x, p) ∈ D
holds it ⊆ D.

One can prove the following proposition

(13) (for a st a ∈ WFF holds a is FinSequence of NAT) &


(for x,y holds x - y ∈ WFF & x  y ∈ WFF) &
(for p st p ∈ WFF holds ¬ p ∈ WFF) &
(for p,q st p ∈ WFF & q ∈ WFF holds p ∧ q ∈ WFF) &
(for x,p st p ∈ WFF holds ∀ (x, p) ∈ WFF) & for D st
(for a st a ∈ D holds a is FinSequence of NAT) &
(for x,y holds x - y ∈ D & x  y ∈ D) & (for p st p ∈ D holds ¬ p ∈ D) &
(for p,q st p ∈ D & q ∈ D holds p ∧ q ∈ D)
& for x,p st p ∈ D holds ∀ (x, p) ∈ D
holds WFF ⊆ D.

The mode
ZF-formula ,

which widens to the type FinSequence of NAT, is defined by

it is Element of WFF .
134 Grzegorz Bancerek

We now state two propositions:


(14) a is ZF-formula iff a ∈ WFF ,

(15) a is ZF-formula iff a is Element of WFF .

In the sequel F , F 1, G, G1, H, H1 denote objects of the type ZF-formula. Let


us consider x, y. Let us note that it makes sense to consider the following functors on
restricted areas. Then
x-y is ZF-formula ,
xy is ZF-formula .
Let us consider H. Let us note that it makes sense to consider the following functor
on a restricted area. Then
¬H is ZF-formula .

Let us consider G. Let us note that it makes sense to consider the following functor on
a restricted area. Then
H ∧G is ZF-formula .
Let us consider x, H. Let us note that it makes sense to consider the following functor
on a restricted area. Then
∀ (x, H) is ZF-formula .

We now define five new predicates. Let us consider H. The predicate


H is a equality is defined by ex x,y st H = x - y.

The predicate
H is a membership is defined by ex x,y st H = x  y.

The predicate
H is negative is defined by ex H1 st H = ¬ H1.

The predicate
H is conjunctive is defined by ex F,G st H = F ∧ G.

The predicate
H is universal is defined by ex x,H1 st H = ∀ (x, H1).

The following proposition is true


(16) (H is a equality iff ex x,y st H = x - y) &
(H is a membership iff ex x,y st H = x  y) &
(H is negative iff ex H1 st H = ¬ H1) &
(H is conjunctive iff ex F,G st H = F ∧ G)
& (H is universal iff ex x,H1 st H = ∀ (x, H1)).
A Model of ZF Set Theory Language 135

Let us consider H. The predicate

H is atomic is defined by H is a equality or H is a membership .

Next we state a proposition

(17) H is atomic iff H is a equality or H is a membership .

We now define two new functors. Let us consider F , G. The functor

F ∨ G,

yields the type ZF-formula and is defined by

it = ¬ (¬ F ∧ ¬ G).

The functor
F ⇒ G,

yields the type ZF-formula and is defined by

it = ¬ (F ∧ ¬ G).

The following two propositions are true:

(18) F ∨ G = ¬ (¬ F ∧ ¬ G),

(19) F ⇒ G = ¬ (F ∧ ¬ G).

Let us consider F , G. The functor

F ⇔ G,

yields the type ZF-formula and is defined by

it = (F ⇒ G) ∧ (G ⇒ F ).

We now state a proposition

(20) F ⇔ G = (F ⇒ G) ∧ (G ⇒ F ).

Let us consider x, H. The functor

∃ (x, H),

yields the type ZF-formula and is defined by

it = ¬ ∀ (x, ¬ H).

The following proposition is true

(21) ∃ (x, H) = ¬ ∀ (x, ¬ H).


136 Grzegorz Bancerek

We now define four new predicates. Let us consider H. The predicate

H is disjunctive is defined by ex F,G st H = F ∨ G.

The predicate

H is conditional is defined by ex F,G st H = F ⇒ G.

The predicate

H is biconditional is defined by ex F,G st H = F ⇔ G.

The predicate

H is existential is defined by ex x,H1 st H = ∃ (x, H1).

The following proposition is true

(22) (H is disjunctive iff ex F,G st H = F ∨ G) &


(H is conditional iff ex F,G st H = F ⇒ G) &
(H is biconditional iff ex F,G st H = F ⇔ G)
& (H is existential iff ex x,H1 st H = ∃ (x, H1)).

We now define two new functors. Let us consider x, y, H. The functor

∀ (x, y, H),

yields the type ZF-formula and is defined by

it = ∀ (x, ∀ (y, H)).

The functor
∃ (x, y, H),
yields the type ZF-formula and is defined by

it = ∃ (x, ∃ (y, H)).

The following proposition is true

(23) ∀ (x, y, H) = ∀ (x, ∀ (y, H)) & ∃ (x, y, H) = ∃ (x, ∃ (y, H)).

We now define two new functors. Let us consider x, y, z, H. The functor

∀ (x, y, z, H),

with values of the type ZF-formula, is defined by

it = ∀ (x, ∀ (y, z, H)).

The functor
∃ (x, y, z, H),
A Model of ZF Set Theory Language 137

with values of the type ZF-formula, is defined by

it = ∃ (x, ∃ (y, z, H)).

We now state several propositions:

(24) ∀ (x, y, z, H) = ∀ (x, ∀ (y, z, H)) & ∃ (x, y, z, H) = ∃ (x, ∃ (y, z, H)),

(25) H is a equality
or H is a membership or H is negative or H is conjunctive or H is universal ,

(26) H is atomic or H is negative or H is conjunctive or H is universal ,

(27) H is atomic implies len H = 3,

(28) H is atomic or ex H1 st len H1 + 1 ≤ len H,

(29) 3 ≤ len H,

(30) len H = 3 implies H is atomic .

One can prove the following propositions:

(31) for x,y holds (x - y).1 = 0 & (x  y).1 = 1,

(32) for H holds (¬ H).1 = 2,

(33) for F,G holds (F ∧ G).1 = 3,

(34) for x,H holds ∀ (x, H).1 = 4,

(35) H is a equality implies H .1 = 0,

(36) H is a membership implies H .1 = 1,

(37) H is negative implies H .1 = 2,

(38) H is conjunctive implies H .1 = 3,

(39) H is universal implies H .1 = 4,

(40) H is a equality & H .1 = 0 or H is a membership & H .1 = 1 or


H is negative & H .1 = 2
or H is conjunctive & H .1 = 3 or H is universal & H .1 = 4,

(41) H .1 = 0 implies H is a equality ,

(42) H .1 = 1 implies H is a membership ,


138 Grzegorz Bancerek

(43) H .1 = 2 implies H is negative ,

(44) H .1 = 3 implies H is conjunctive ,

(45) H .1 = 4 implies H is universal .

In the sequel sq denotes an object of the type FinSequence. We now state several
propositions:

(46) H =F _
sq implies H = F,

(47) H ∧ G = H1 ∧ G1 implies H = H1 & G = G1,

(48) F ∨ G = F 1 ∨ G1 implies F = F 1 & G = G1,

(49) F ⇒ G = F 1 ⇒ G1 implies F = F 1 & G = G1,

(50) F ⇔ G = F 1 ⇔ G1 implies F = F 1 & G = G1,

(51) ∃ (x, H) = ∃ (y, G) implies x = y & H = G.

We now define two new functors. Let us consider H. Assume that the following
holds

H is atomic .

The functor
Var1 H,

yields the type Variable and is defined by

it = H .2.

The functor
Var2 H,

yields the type Variable and is defined by

it = H .3.

One can prove the following three propositions:

(52) H is atomic implies Var1 H = H .2 & Var2 H = H .3,

(53) H is a equality implies H = (Var1 H) - Var2 H,

(54) H is a membership implies H = (Var1 H)  Var2 H.

Let us consider H. Assume that the following holds

H is negative .
A Model of ZF Set Theory Language 139

The functor
the argument of H,
with values of the type ZF-formula, is defined by

¬ it = H.

We now state a proposition

(55) H is negative implies H = ¬ the argument of H.

We now define two new functors. Let us consider H. Assume that the following
holds

H is conjunctive or H is disjunctive .

The functor
the left argument of H,
with values of the type ZF-formula, is defined by

ex H1 st it ∧ H1 = H, if H is conjunctive ,
ex H1 st it ∨ H1 = H, otherwise.

The functor
the right argument of H,
with values of the type ZF-formula, is defined by

ex H1 st H1 ∧ it = H, if H is conjunctive ,
ex H1 st H1 ∨ it = H, otherwise.

One can prove the following propositions:

(56) H is conjunctive implies (F = the left argument of H iff ex G st F ∧ G = H)


& (F = the right argument of H iff ex G st G ∧ F = H),

(57) H is disjunctive implies (F = the left argument of H iff ex G st F ∨ G = H)


& (F = the right argument of H iff ex G st G ∨ F = H),

(58) H is conjunctive
implies H = (the left argument of H) ∧ the right argument of H,

(59) H is disjunctive
implies H = (the left argument of H) ∨ the right argument of H.

We now define two new functors. Let us consider H. Assume that the following
holds

H is universal or H is existential .
140 Grzegorz Bancerek

The functor
bound in H,
with values of the type Variable, is defined by

ex H1 st ∀ (it ,H1) = H, if H is universal ,


ex H1 st ∃ (it ,H1) = H, otherwise.

The functor
the scope of H,
with values of the type ZF-formula, is defined by

ex x st ∀ (x, it) = H, if H is universal ,


ex x st ∃ (x, it) = H, otherwise.

Next we state four propositions:

(60) H is universal implies (x = bound in H iff ex H1 st ∀ (x, H1) = H)


& (H1 = the scope of H iff ex x st ∀ (x, H1) = H),

(61) H is existential implies (x = bound in H iff ex H1 st ∃ (x, H1) = H)


& (H1 = the scope of H iff ex x st ∃ (x, H1) = H),

(62) H is universal implies H = ∀ (bound in H,the scope of H),

(63) H is existential implies H = ∃ (bound in H,the scope of H).

We now define two new functors. Let us consider H. Assume that the following
holds

H is conditional .

The functor
the antecedent of H,
with values of the type ZF-formula, is defined by

ex H1 st H = it ⇒ H1.

The functor
the consequent of H,
with values of the type ZF-formula, is defined by

ex H1 st H = H1 ⇒ it .

The following propositions are true:

(64) H is conditional implies (F = the antecedent of H iff ex G st H = F ⇒ G)


& (F = the consequent of H iff ex G st H = G ⇒ F ),
A Model of ZF Set Theory Language 141

(65) H is conditional implies H = (the antecedent of H) ⇒ the consequent of H.

We now define two new functors. Let us consider H. Assume that the following
holds

H is biconditional .

The functor
the left side of H,

yields the type ZF-formula and is defined by

ex H1 st H = it ⇔ H1.

The functor
the right side of H,

with values of the type ZF-formula, is defined by

ex H1 st H = H1 ⇔ it .

We now state two propositions:

(66) H is biconditional implies (F = the left side of H iff ex G st H = F ⇔ G)


& (F = the right side of H iff ex G st H = G ⇔ F ),

(67) H is biconditional implies H = (the left side of H) ⇔ the right side of H.

Let us consider H, F . The predicate

H is immediate constituent of F

is defined by

F = ¬ H or (ex H1 st F = H ∧ H1 or F = H1 ∧ H) or ex x st F = ∀ (x, H).

We now state a number of propositions:

(68) H is immediate constituent of F iff


F = ¬ H or (ex H1 st F = H ∧ H1 or F = H1 ∧ H) or ex x st F = ∀ (x, H),

(69) not H is immediate constituent of x - y,

(70) not H is immediate constituent of x  y,

(71) F is immediate constituent of ¬ H iff F = H,

(72) F is immediate constituent of G ∧ H iff F = G or F = H,

(73) F is immediate constituent of ∀ (x, H) iff F = H,


142 Grzegorz Bancerek

(74) H is atomic implies not F is immediate constituent of H,

(75) H is negative
implies (F is immediate constituent of H iff F = the argument of H),

(76) H is conjunctive implies (F is immediate constituent of H


iff F = the left argument of H or F = the right argument of H),

(77) H is universal
implies (F is immediate constituent of H iff F = the scope of H).

In the sequel L will denote an object of the type FinSequence. Let us consider H,
F . The predicate
H is subformula of F
is defined by

ex n,L st 1 ≤ n & len L = n & L.1 = H & L.n = F & for k st 1 ≤ k & k < n
ex H1,F 1 st L.k = H1 & L.(k + 1) = F 1 & H1 is immediate constituent of F 1.

Next we state two propositions:

(78) H is subformula of F iff ex n,L st 1 ≤ n & len L = n & L.1 = H & L.n = F &
for k st 1 ≤ k & k < n ex H1,F 1
st L.k = H1 & L.(k + 1) = F 1 & H1 is immediate constituent of F 1,

(79) H is subformula of H.

Let us consider H, F . The predicate

H is proper subformula of F is defined by H is subformula of F & H 6= F.

We now state several propositions:

(80) H is proper subformula of F iff H is subformula of F & H 6= F,

(81) H is immediate constituent of F implies len H < len F,

(82) H is immediate constituent of F implies H is proper subformula of F,

(83) H is proper subformula of F implies len H < len F,

(84) H is proper subformula of F


implies ex G st G is immediate constituent of F.

The following propositions are true:

(85) F is proper subformula of G & G is proper subformula of H


implies F is proper subformula of H,
A Model of ZF Set Theory Language 143

(86) F is subformula of G & G is subformula of H implies F is subformula of H,

(87) G is subformula of H & H is subformula of G implies G = H,

(88) not F is proper subformula of x - y,

(89) not F is proper subformula of x  y,

(90) F is proper subformula of ¬ H implies F is subformula of H,

(91) F is proper subformula of G ∧ H


implies F is subformula of G or F is subformula of H,

(92) F is proper subformula of ∀ (x, H) implies F is subformula of H,

(93) H is atomic implies not F is proper subformula of H,

(94) H is negative implies the argument of H is proper subformula of H,

(95) H is conjunctive implies the left argument of H is proper subformula of H


& the right argument of H is proper subformula of H,

(96) H is universal implies the scope of H is proper subformula of H,

(97) H is subformula of x - y iff H = x - y,

(98) H is subformula of x  y iff H = x  y.

Let us consider H. The functor

Subformulae H,

yields the type set and is defined by

a ∈ it iff ex F st F = a & F is subformula of H.

We now state a number of propositions:

(99) a ∈ Subformulae H iff ex F st F = a & F is subformula of H,

(100) G ∈ Subformulae H implies G is subformula of H,

(101) F is subformula of H implies Subformulae F ⊆ Subformulae H,

(102) Subformulae x - y = {x - y},

(103) Subformulae x  y = {x  y},

(104) Subformulae ¬ H = Subformulae H ∪ {¬ H},


144 Grzegorz Bancerek

(105) Subformulae (H ∧ F ) = Subformulae H ∪ Subformulae F ∪ {H ∧ F },

(106) Subformulae ∀ (x, H) = Subformulae H ∪ {∀ (x, H)},

(107) H is atomic iff Subformulae H = {H},

(108) H is negative
implies Subformulae H = Subformulae the argument of H ∪ {H},

(109) H is conjunctive implies Subformulae H = Subformulae


the left argument of H ∪ Subformulae the right argument of H ∪ {H},

(110) H is universal implies Subformulae H = Subformulae the scope of H ∪ {H},

(111) (H is immediate constituent of G


or H is proper subformula of G or H is subformula of G)
& G ∈ Subformulae F
implies H ∈ Subformulae F.

In the article we present several logical schemes. The scheme ZF Ind deals with a
unary predicate P states that the following holds

for H holds P[H]

provided the parameter satisfies the following conditions:

• for H st H is atomic holds P[H],

• for H st H is negative & P[the argument of H] holds P[H],

• for H st
H is conjunctive & P[the left argument of H] & P[the right argument of H]
holds P[H],

• for H st H is universal & P[the scope of H] holds P[H].

The scheme ZF CompInd deals with a unary predicate P states that the following
holds

for H holds P[H]

provided the parameter satisfies the following condition:

• for H st for F st F is proper subformula of H holds P[F ] holds P[H].


A Model of ZF Set Theory Language 145

References
[1] Grzegorz Bancerek. The fundamental properties of natural numbers. Formalized
Mathematics, 1, 1990.

[2] Grzegorz Bancerek and Krzysztof Hryniewiecki. Segments of natural numbers and
finite sequences. Formalized Mathematics, 1, 1990.

[3] Czeslaw Byliński. Functions and their basic properties. Formalized Mathematics, 1,
1990.

[4] Krzysztof Hryniewiecki. Basic properties of real numbers. Formalized Mathematics,


1, 1990.

[5] Andrzej Trybulec. Tarski Grothendieck set theory. Formalized Mathematics, 1, 1990.

[6] Zinaida Trybulec and Halina Świe czkowska. Boolean properties of sets. Formalized

Mathematics, 1, 1990.

Received April 4, 1989


146
FORMALIZED MATHEMATICS
Number 1, January 1990
Université Catholique de Louvain

Families of Sets

Beata Padlewska1
Warsaw University
Bialystok

Summary. The article contains definitions of the following concepts: family


of sets, family of subsets of a set, the intersection of a family of sets. Functors ∪, ∩,
and \ are redefined for families of subsets of a set. Some properties of these notions
are presented.

The terminology and notation used in this paper are introduced in the following papers:
[1], [3], and [2]. For simplicity we adopt the following convention: X, Y , Z, Z1, D
will denote objects of the type set; x, y will denote objects of the type Any. Let us
consider X. The functor
\
X,

with values of the type set, is defined by

for x holds x ∈ it iff for Y holds Y ∈ X implies x ∈ Y, if X 6= ∅,


it = ∅, otherwise.

The following propositions are true:


\
(1) X 6= ∅ implies for x holds x ∈ X iff for Y st Y ∈ X holds x ∈ Y,
\
(2) ∅ = ∅,
\ [
(3) X⊆ X,
\
(4) Z ∈ X implies X ⊆ Z,
\
(5) ∅ ∈ X implies X = ∅,
\
(6) X 6= ∅ & (for Z1 st Z1 ∈ X holds Z ⊆ Z1) implies Z ⊆ X,
1
Supported by RPBP.III-24.C1.
f
c 1990 Fondation Philippe le Hodey
147 ISSN 0777-4028
148 Beata Padlewska

\ \
(7) X 6= ∅ & X ⊆ Y implies Y ⊆ X,
\
(8) X ∈ Y & X ⊆ Z implies Y ⊆ Z,
\
(9) X ∈ Y & X ∩ Z = ∅ implies Y ∩ Z = ∅,
\ \ \
(10) X 6= ∅ & Y 6= ∅ implies (X ∪ Y ) = X∩ Y,
\
(11) {x} = x,
\
(12) {X, Y } = X ∩ Y.

Set-Family stands for set .

In the sequel SF X, SF Y , SF Z will have the type Set-Family. One can prove
the following two propositions:

(13) x is Set-Family ,

(14) SF X = SF Y iff for X holds X ∈ SF X iff X ∈ SF Y.

We now define two new predicates. Let us consider SF X, SF Y . The predicate

SF X is finer than SF Y

is defined by

for X st X ∈ SF X ex Y st Y ∈ SF Y & X ⊆ Y.

The predicate
SF X is coarser than SF Y

is defined by

for Y st Y ∈ SF Y ex X st X ∈ SF X & X ⊆ Y.

Next we state several propositions:

(15) SF X is finer than SF Y iff for X st X ∈ SF X ex Y st Y ∈ SF Y & X ⊆ Y,

(16) SF X is coarser than SF Y


iff for Y st Y ∈ SF Y ex X st X ∈ SF X & X ⊆ Y,

(17) SF X ⊆ SF Y implies SF X is finer than SF Y,


[ [
(18) SF X is finer than SF Y implies SF X ⊆ SF Y,
\ \
(19) SF Y 6= ∅ & SF X is coarser than SF Y implies SF X ⊆ SF Y.
Families of Sets 149

Let us note that it makes sense to consider the following constant. Then ∅ is
Set-Family . Let us consider x. Let us note that it makes sense to consider the following
functor on a restricted area. Then

{x} is Set-Family .

Let us consider y. Let us note that it makes sense to consider the following functor on a
restricted area. Then
{x, y} is Set-Family .
One can prove the following propositions:

(20) ∅ is finer than SF X,

(21) SF X is finer than ∅ implies SF X = ∅,

(22) SF X is finer than SF X,

(23) SF X is finer than SF Y & SF Y is finer than SF Z


implies SF X is finer than SF Z,

(24) SF X is finer than {Y } implies for X st X ∈ SF X holds X ⊆ Y,

(25) SF X is finer than {X, Y }


implies for Z st Z ∈ SF X holds Z ⊆ X or Z ⊆ Y.

We now define three new functors. Let us consider SF X, SF Y . The functor

UNION (SF X,SF Y ),

yields the type Set-Family and is defined by

Z ∈ it iff ex X,Y st X ∈ SF X & Y ∈ SF Y & Z = X ∪ Y.

The functor
INTERSECTION (SF X,SF Y ),
with values of the type Set-Family, is defined by

Z ∈ it iff ex X,Y st X ∈ SF X & Y ∈ SF Y & Z = X ∩ Y.

The functor
DIFFERENCE (SF X,SF Y ),
with values of the type Set-Family, is defined by

Z ∈ it iff ex X,Y st X ∈ SF X & Y ∈ SF Y & Z = X \ Y.

One can prove the following propositions:

(26) Z ∈ UNION (SF X,SF Y ) iff ex X,Y st X ∈ SF X & Y ∈ SF Y & Z = X ∪ Y,


150 Beata Padlewska

(27) Z ∈ INTERSECTION (SF X,SF Y )


iff ex X,Y st X ∈ SF X & Y ∈ SF Y & Z = X ∩ Y,

(28) Z ∈ DIFFERENCE (SF X,SF Y )


iff ex X,Y st X ∈ SF X & Y ∈ SF Y & Z = X \ Y,

(29) SF X is finer than UNION (SF X,SF X),

(30) INTERSECTION (SF X,SF X) is finer than SF X,

(31) DIFFERENCE (SF X,SF X) is finer than SF X,

(32) UNION (SF X,SF Y ) = UNION (SF Y,SF X),

(33) INTERSECTION (SF X,SF Y ) = INTERSECTION (SF Y,SF X),

(34) SF X ∩ SF Y 6= ∅
\ \ \
implies SF X ∩ SF Y = INTERSECTION (SF X,SF Y ),
\ \
(35) SF Y 6= ∅ implies X ∪ SF Y = UNION ({X},SF Y ),
[ [
(36) X∩ SF Y = INTERSECTION ({X},SF Y ),
[ \
(37) SF Y 6= ∅ implies X \ SF Y = DIFFERENCE ({X},SF Y ),
\ [
(38) SF Y 6= ∅ implies X \ SF Y = DIFFERENCE ({X},SF Y ),
[ [ [
(39) INTERSECTION (SF X,SF Y ) ⊆ SF X ∩ SF Y,
\ \ \
(40) SF X 6= ∅ & SF Y 6= ∅ implies SF X ∪ SF Y ⊆ UNION (SF X,SF Y ),

(41) SF X 6= ∅ & SF Y 6= ∅
\ \ \
implies DIFFERENCE (SF X,SF Y ) ⊆ SF X \ SF Y.

Let D have the type set.

Subset-Family of D stands for Subset of bool D.

We now state a proposition

(42) for F being Subset of bool D holds F is Subset-Family of D.

In the sequel F , G have the type Subset-Family of D; P has the type Subset of
D. Let us consider D, F , G. Let us note that it makes sense to consider the following
functors on restricted areas. Then

F ∪G is Subset-Family of D,
Families of Sets 151

F ∩G is Subset-Family of D,

F \G is Subset-Family of D.

Next we state a proposition

(43) X ∈ F implies X is Subset of D.

Let us consider D, F . Let us note that it makes sense to consider the following functor
on a restricted area. Then
[
F is Subset of D.

Let us consider D, F . Let us note that it makes sense to consider the following functor
on a restricted area. Then
\
F is Subset of D.

The following proposition is true

(44) F = G iff for P holds P ∈ F iff P ∈ G.

The scheme SubFamEx deals with a constant A that has the type set and a unary
predicate P and states that the following holds

ex F being Subset-Family of A st for B being Subset of A holds B ∈ F iff P[B]

for all values of the parameters.


Let us consider D, F . The functor

F c,

yields the type Subset-Family of D and is defined by

for P being Subset of D holds P ∈ it iff P c ∈ F.

Next we state four propositions:

(45) for P holds P ∈ F c iff P c ∈ F,

(46) F 6= ∅ implies F c =
6 ∅,
[ \
(47) F 6= ∅ implies Ω D \ F = (F c ),

[ \
(48) F 6= ∅ implies F c = ΩD \ F.
152 Beata Padlewska

References
[1] Andrzej Trybulec. Tarski Grothendieck set theory. Formalized Mathematics, 1, 1990.

[2] Zinaida Trybulec. Properties of subsets. Formalized Mathematics, 1, 1990.

[3] Zinaida Trybulec and Halina Świe czkowska. Boolean properties of sets. Formalized

Mathematics, 1, 1990.

Received April 5, 1989


FORMALIZED MATHEMATICS
Number 1, January 1990
Université Catholique de Louvain

Functions from a Set to a Set

Czeslaw Byliński1
Warsaw University
Bialystok

Summary. The article is a continuation of [1]. We define the following con-


cepts: a function from a set X into a set Y , denoted by “Function of X,Y ”, the
set of all functions from a set X into a set Y , denoted by Funcs(X,Y ), and the
permutation of a set (mode Permutation of X, where X is a set). Theorems and
schemes included in the article are reformulations of the theorems of [1] in the new
terminology. Also some basic facts about functions of two variables are proved.

The notation and terminology used in this paper are introduced in the following articles:
[2], [3], and [1]. For simplicity we adopt the following convention: P , Q, X, Y , Y 1,
Y 2, Z will denote objects of the type set; x, x1, x2, y, y1, y2, z, z1, z2 will denote
objects of the type Any. Let us consider X, Y . Assume that the following holds

Y = ∅ implies X = ∅.

The mode
Function of X, Y,

which widens to the type Function, is defined by

X = dom it & rng it ⊆ Y.

Next we state several propositions:

(1) (Y = ∅ implies X = ∅) implies for f being Function


holds f is Function of X, Y iff X = dom f & rng f ⊆ Y,

(2) for f being Function of X, Y


st Y = ∅ implies X = ∅ holds X = dom f & rng f ⊆ Y,

(3) for f being Function holds f is Function of dom f,rng f,


1
Supported by RPBP.III-24.C1.

cf 1990 Fondation Philippe le Hodey


153 ISSN 0777-4028
154 Czeslaw Byliński

(4) for f being Function st rng f ⊆ Y holds f is Function of dom f,Y,

(5) for f being Function


st dom f = X & for x st x ∈ X holds f .x ∈ Y holds f is Function of X, Y,

(6) for f being Function of X, Y st Y 6= ∅ & x ∈ X holds f .x ∈ rng f,

(7) for f being Function of X, Y st Y 6= ∅ & x ∈ X holds f .x ∈ Y,

(8) for f being Function of X, Y


st (Y = ∅ implies X = ∅) & rng f ⊆ Z holds f is Function of X, Z,

(9) for f being Function of X, Y


st (Y = ∅ implies X = ∅) & Y ⊆ Z holds f is Function of X, Z.

In the article we present several logical schemes. The scheme FuncEx1 deals with
a constant A that has the type set, a constant B that has the type set and a binary
predicate P and states that the following holds

ex f being Function of A,B st for x st x ∈ A holds P[x, f .x]

provided the parameters satisfy the following conditions:

• for x st x ∈ A ex y st y ∈ B & P[x, y],

• for x,y1,y2 st x ∈ A & P[x, y1] & P[x, y2] holds y1 = y2.

The scheme Lambda1 concerns a constant A that has the type set, a constant B that
has the type set and a unary functor F and states that the following holds

ex f being Function of A,B st for x st x ∈ A holds f .x = F(x)

provided the parameters satisfy the following condition:

• for x st x ∈ A holds F(x) ∈ B.

Let us consider X, Y . The functor

Funcs (X, Y ),

yields the type set and is defined by

x ∈ it iff ex f being Function st x = f & dom f = X & rng f ⊆ Y.

We now state a number of propositions:

(10) for F being set holds F = Funcs (X, Y ) iff for x


holds x ∈ F iff ex f being Function st x = f & dom f = X & rng f ⊆ Y,
Functions from a Set to a Set 155

(11) for f being Function of X, Y


st Y = ∅ implies X = ∅ holds f ∈ Funcs (X, Y ),

(12) for f being Function of X, X holds f ∈ Funcs (X, X),

(13) for f being Function of ∅,X holds f ∈ Funcs (∅,X),

(14) X 6= ∅ implies Funcs (X, ∅) = ∅,

(15) Funcs (X, Y ) = ∅ implies X 6= ∅ & Y = ∅,

(16) for f being Function of X, Y


st Y 6= ∅ & for y st y ∈ Y ex x st x ∈ X & y = f .x holds rng f = Y,

(17) for f being Function of X, Y st y ∈ Y & rng f = Y ex x st x ∈ X & f .x = y,

(18) for f 1,f 2 being Function of X, Y


st Y 6= ∅ & for x st x ∈ X holds f 1.x = f 2.x holds f 1 = f 2,

(19) for f being Function of X, Y for g being Function of Y, Z st


(Z = ∅ implies Y = ∅) & (Y = ∅ implies X = ∅)
holds g · f is Function of X, Z,

(20) for f being Function of X, Y for g being Function of Y, Z


st Y 6= ∅ & Z 6= ∅ & rng f = Y & rng g = Z holds rng (g · f ) = Z,

(21) for f being Function of X, Y for g being Function of Y, Z


st Y 6= ∅ & Z 6= ∅ & x ∈ X holds (g · f ).x = g .(f .x),

(22) for f being Function of X, Y st Y 6= ∅ holds rng f = Y


iff for Z st Z 6= ∅ for g,h being Function of Y, Z st g · f = h · f holds g = h,

(23) for f being Function of X, Y


st Y = ∅ implies X = ∅ holds f · (id X) = f & (id Y ) · f = f,

(24) for f being Function of X, Y


for g being Function of Y, X st Y 6= ∅ & f · g = id Y holds rng f = Y,

(25) for f being Function of X, Y st Y = ∅ implies X = ∅ holds f is one-to-one


iff for x1,x2 st x1 ∈ X & x2 ∈ X & f .x1 = f .x2 holds x1 = x2,

(26) for f being Function of X, Y for g being Function of Y, Z st


(Z = ∅ implies Y = ∅) & (Y = ∅ implies X = ∅) & g · f is one-to-one
holds f is one-to-one ,
156 Czeslaw Byliński

(27) for f being Function of X, Y st X 6= ∅ & Y 6= ∅ holds f is one-to-one


iff for Z for g,h being Function of Z, X st f · g = f · h holds g = h,

(28) for f being Function of X, Y for g being Function of Y, Z


st Z 6= ∅ & Y 6= ∅ & rng (g · f ) = Z & g is one-to-one holds rng f = Y,

(29) for f being Function of X, Y for g being Function of Y, X


st X 6= ∅ & Y 6= ∅ & g · f = id X holds f is one-to-one & rng g = X,

(30) for f being Function of X, Y for g being Function of Y, Z st


(Z = ∅ implies Y = ∅) & g · f is one-to-one & rng f = Y
holds f is one-to-one & g is one-to-one ,

(31) for f being Function of X, Y st


f is one-to-one & (X = ∅ iff Y = ∅) & rng f = Y
holds f -1 is Function of Y, X,

(32) for f being Function of X, Y


st Y 6= ∅ & f is one-to-one & x ∈ X holds (f -1 ).(f .x) = x,

(33) for f being Function of X, Y


st rng f = Y & f is one-to-one & y ∈ Y holds f .((f -1 ).y) = y,

(34) for f being Function of X, Y for g being Function of Y, X st


X 6= ∅ & Y 6= ∅ & rng f = Y
& f is one-to-one & for y,x holds y ∈ Y & g .y = x iff x ∈ X & f .x = y
holds g = f -1 ,

(35) for f being Function of X, Y


6 ∅ & rng f = Y & f is one-to-one holds f -1 · f = id X & f · f -1 = id Y,
st Y =

(36) for f being Function of X, Y for g being Function of Y, X st


X 6= ∅ & Y 6= ∅ & rng f = Y & g · f = id X & f is one-to-one holds g = f -1 ,

(37) for f being Function of X, Y st


Y 6= ∅ & ex g being Function of Y, X st g · f = id X holds f is one-to-one ,

(38) for f being Function of X, Y


st (Y = ∅ implies X = ∅) & Z ⊆ X holds f | Z is Function of Z, Y,

(39) for f being Function of X, Y


st Y 6= ∅ & x ∈ X & x ∈ Z holds (f | Z).x = f .x,
Functions from a Set to a Set 157

(40) for f being Function of X, Y


st (Y = ∅ implies X = ∅) & X ⊆ Z holds f | Z = f,

(41) for f being Function of X, Y


st Y 6= ∅ & x ∈ X & f .x ∈ Z holds (Z | f ).x = f .x,

(42) for f being Function of X, Y


st (Y = ∅ implies X = ∅) & Y ⊆ Z holds Z | f = f,

(43) for f being Function of X, Y


6 ∅ for y holds y ∈ f ◦ P iff ex x st x ∈ X & x ∈ P & y = f .x,
st Y =

(44) for f being Function of X, Y st Y = ∅ implies X = ∅ holds f ◦ P ⊆ Y,

(45) for f being Function of X, Y st Y = ∅ implies X = ∅ holds f ◦ X = rng f,

(46) for f being Function of X, Y


6 ∅ for x holds x ∈ f -1 Q iff x ∈ X & f .x ∈ Q,
st Y =

(47) for f being Function of X, Y st Y = ∅ implies X = ∅ holds f -1 Q ⊆ X,

(48) for f being Function of X, Y st Y = ∅ implies X = ∅ holds f -1 Y = X,

(49) for f being Function of X, Y


6 ∅ holds (for y st y ∈ Y holds f -1 {y} 6= ∅) iff rng f = Y,
st Y =

(50) for f being Function of X, Y


st (Y = ∅ implies X = ∅) & P ⊆ X holds P ⊆ f -1 (f ◦ P ),

(51) for f being Function of X, Y


st Y = ∅ implies X = ∅ holds f -1 (f ◦ X) = X,

(52) for f being Function of X, Y


st (Y = ∅ implies X = ∅) & rng f = Y holds f ◦ (f -1 Y ) = Y,

(53) for f being Function of X, Y for g being Function of Y, Z st


(Z = ∅ implies Y = ∅) & (Y = ∅ implies X = ∅)
holds f -1 Q ⊆ (g · f ) -1 (g ◦ Q),

(54) for f being Function of ∅,Y holds dom f = ∅ & rng f = ∅,

(55) for f being Function st dom f = ∅ holds f is Function of ∅,Y,

(56) for f 1 being Function of ∅,Y 1 for f 2 being Function of ∅,Y 2 holds f 1 = f 2,
158 Czeslaw Byliński

(57) for f being Function of ∅,Y for g being Function of Y, Z


st Z = ∅ implies Y = ∅ holds g · f is Function of ∅,Z,

(58) for f being Function of ∅,Y holds f is one-to-one ,

(59) for f being Function of ∅,Y holds f ◦ P = ∅,

(60) for f being Function of ∅,Y holds f -1 Q = ∅,

(61) for f being Function of {x},Y st Y 6= ∅ holds f .x ∈ Y,

(62) for f being Function of {x},Y st Y 6= ∅ holds rng f = {f .x},

(63) for f being Function of {x},Y st Y 6= ∅ holds f is one-to-one ,

(64) for f being Function of {x},Y st Y 6= ∅ holds f ◦ P ⊆ {f .x},

(65) for f being Function of X, {y} st x ∈ X holds f .x = y,

(66) for f 1,f 2 being Function of X, {y} holds f 1 = f 2.

The arguments of the notions defined below are the following: X which is an object
of the type reserved above; f , g which are objects of the type Function of X, X. Let
us note that it makes sense to consider the following functor on a restricted area. Then

g·f is Function of X, X.

Let us consider X. Let us note that it makes sense to consider the following functor
on a restricted area. Then

id X is Function of X, X.

The following propositions are true:

(67) for f being Function of X, X holds dom f = X & rng f ⊆ X,

(68) for f being Function


st dom f = X & rng f ⊆ X holds f is Function of X, X,

(69) for f being Function of X, X st x ∈ X holds f .x ∈ X,

(70) for f,g being Function of X, X st x ∈ X holds (g · f ).x = g .(f .x),

(71) for f being Function of X, X


for g being Function of X, Y st Y 6= ∅ & x ∈ X holds (g · f ).x = g .(f .x),

(72) for f being Function of X, Y


for g being Function of Y, Y st Y 6= ∅ & x ∈ X holds (g · f ).x = g .(f .x),
Functions from a Set to a Set 159

(73) for f,g being Function of X, X


st rng f = X & rng g = X holds rng (g · f ) = X,

(74) for f being Function of X, X holds f · (id X) = f & (id X) · f = f,

(75) for f,g being Function of X, X st g · f = f & rng f = X holds g = id X,

(76) for f,g being Function of X, X st f · g = f & f is one-to-one holds g = id X,

(77) for f being Function of X, X holds f is one-to-one


iff for x1,x2 st x1 ∈ X & x2 ∈ X & f .x1 = f .x2 holds x1 = x2,

(78) for f being Function of X, X holds f ◦ P ⊆ X.

The arguments of the notions defined below are the following: X which is an object
of the type reserved above; f which is an object of the type Function of X, X; P which
is an object of the type reserved above. Let us note that it makes sense to consider the
following functor on a restricted area. Then

f◦P is Subset of X.

One can prove the following propositions:

(79) for f being Function of X, X holds f ◦ X = rng f,

(80) for f being Function of X, X holds f -1 Q ⊆ X.

The arguments of the notions defined below are the following: X which is an object
of the type reserved above; f which is an object of the type Function of X, X; Q which
is an object of the type reserved above. Let us note that it makes sense to consider the
following functor on a restricted area. Then

f -1 Q is Subset of X.

Next we state two propositions:

(81) for f being Function of X, X st rng f = X holds f ◦ (f -1 X) = X,

(82) for f being Function of X, X holds f -1 (f ◦ X) = X.

Let us consider X. The mode

Permutation of X,

which widens to the type Function of X, X, is defined by

it is one-to-one & rng it = X.


160 Czeslaw Byliński

Next we state three propositions:

(83) for f being Function of X, X


holds f is Permutation of X iff f is one-to-one & rng f = X,

(84) for f being Permutation of X holds f is one-to-one & rng f = X,

(85) for f being Permutation of X


for x1,x2 st x1 ∈ X & x2 ∈ X & f .x1 = f .x2 holds x1 = x2.

The arguments of the notions defined below are the following: X which is an object
of the type reserved above; f , g which are objects of the type Permutation of X. Let
us note that it makes sense to consider the following functor on a restricted area. Then

g·f is Permutation of X.

Let us consider X. Let us note that it makes sense to consider the following functor
on a restricted area. Then

id X is Permutation of X.

The arguments of the notions defined below are the following: X which is an object
of the type reserved above; f which is an object of the type Permutation of X. Let us
note that it makes sense to consider the following functor on a restricted area. Then

f -1 is Permutation of X.

The following propositions are true:

(86) for f,g being Permutation of X st g · f = g holds f = id X,

(87) for f,g being Permutation of X st g · f = id X holds g = f -1 ,

(88) for f being Permutation of X holds (f -1 ) · f = id X & f · (f -1 ) = id X,

(89) for f being Permutation of X holds (f -1 ) -1 = f,

(90) for f,g being Permutation of X holds (g · f ) -1 = f -1 · g -1 ,

(91) for f being Permutation of X st P ∩ Q = ∅ holds f ◦ P ∩ f ◦ Q = ∅,

(92) for f being Permutation of X


st P ⊆ X holds f ◦ (f -1 P ) = P & f -1 (f ◦ P ) = P,

(93) for f being Permutation of X holds f ◦ P = (f -1 ) -1 P & f -1 P = (f -1 ) ◦ P.

In the sequel C, D, E denote objects of the type DOMAIN. The arguments of


the notions defined below are the following: X, D, E which are objects of the type
Functions from a Set to a Set 161

reserved above; f which is an object of the type Function of X, D; g which is an object


of the type Function of D, E. Let us note that it makes sense to consider the following
functor on a restricted area. Then

g·f is Function of X, E.

Let us consider X, D. Let us note that one can characterize the mode

Function of X, D

by the following (equivalent) condition:

X = dom it & rng it ⊆ D.

We now state a number of propositions:

(94) for f being Function of X, D holds dom f = X & rng f ⊆ D,

(95) for f being Function


st dom f = X & rng f ⊆ D holds f is Function of X, D,

(96) for f being Function of X, D st x ∈ X holds f .x ∈ D,

(97) for f being Function of {x},D holds f .x ∈ D,

(98) for f 1,f 2 being Function of X, D


st for x st x ∈ X holds f 1.x = f 2.x holds f 1 = f 2,

(99) for f being Function of X, D


for g being Function of D, E st x ∈ X holds (g · f ).x = g .(f .x),

(100) for f being Function of X, D holds f · (id X) = f & (id D) · f = f,

(101) for f being Function of X, D holds f is one-to-one


iff for x1,x2 st x1 ∈ X & x2 ∈ X & f .x1 = f .x2 holds x1 = x2,

(102) for f being Function of X, D


for y holds y ∈ f ◦ P iff ex x st x ∈ X & x ∈ P & y = f .x,

(103) for f being Function of X, D holds f ◦ P ⊆ D.

The arguments of the notions defined below are the following: X, D which are
objects of the type reserved above; f which is an object of the type Function of X,
D; P which is an object of the type reserved above. Let us note that it makes sense to
consider the following functor on a restricted area. Then

f◦P is Subset of D.
162 Czeslaw Byliński

One can prove the following propositions:

(104) for f being Function of X, D holds f ◦ X = rng f,

(105) for f being Function of X, D st f ◦ X = D holds rng (f ) = D,

(106) for f being Function of X, D for x holds x ∈ f -1 Q iff x ∈ X & f .x ∈ Q,

(107) for f being Function of X, D holds f -1 Q ⊆ X.

The arguments of the notions defined below are the following: X, D which are
objects of the type reserved above; f which is an object of the type Function of X,
D; Q which is an object of the type reserved above. Let us note that it makes sense to
consider the following functor on a restricted area. Then

f -1 Q is Subset of X.

One can prove the following propositions:

(108) for f being Function of X, D holds f -1 D = X,

(109) for f being Function of X, D


holds (for y st y ∈ D holds f -1 {y} 6= ∅) iff rng f = D,

(110) for f being Function of X, D holds f -1 (f ◦ X) = X,

(111) for f being Function of X, D st rng f = D holds f ◦ (f -1 D) = D,

(112) for f being Function of X, D


for g being Function of D, E holds f -1 Q ⊆ (g · f ) -1 (g ◦ Q).

In the sequel c denotes an object of the type Element of C; d denotes an object of


the type Element of D. The arguments of the notions defined below are the following:
C, D which are objects of the type reserved above; f which is an object of the type
Function of C, D; c which is an object of the type reserved above. Let us note that it
makes sense to consider the following functor on a restricted area. Then

f .c is Element of D.

Now we present two schemes. The scheme FuncExD concerns a constant A that has
the type DOMAIN, a constant B that has the type DOMAIN and a binary predicate P
and states that the following holds

ex f being Function of A,B st for x being Element of A holds P[x, f .x]

provided the parameters satisfy the following conditions:

• for x being Element of A ex y being Element of B st P[x, y],


Functions from a Set to a Set 163

• for x being Element of A, y1,y2 being Element of B


st P[x, y1] & P[x, y2] holds y1 = y2.

The scheme LambdaD concerns a constant A that has the type DOMAIN, a constant
B that has the type DOMAIN and a unary functor F yielding values of the type Element
of B and states that the following holds

ex f being Function of A,B st for x being Element of A holds f .x = F(x)

for all values of the parameters.


One can prove the following propositions:

(113) for f 1,f 2 being Function of C, D st for c holds f 1.c = f 2.c holds f 1 = f 2,

(114) (id C).c = c,

(115) for f being Function of C, D


for g being Function of D, E holds (g · f ).c = g .(f .c),

(116) for f being Function of C, D


for d holds d ∈ f ◦ P iff ex c st c ∈ P & d = f .c,

(117) for f being Function of C, D for c holds c ∈ f -1 Q iff f .c ∈ Q,

(118) for f 1,f 2 being Function of [:X, Y :],Z st


Z 6= ∅ & for x,y st x ∈ X & y ∈ Y holds f 1.hx, yi = f 2.hx, yi holds f 1 = f 2,

(119) for f being Function of [:X, Y :],Z


st x ∈ X & y ∈ Y & Z 6= ∅ holds f .hx, yi ∈ Z.

Now we present two schemes. The scheme FuncEx2 concerns a constant A that has
the type set, a constant B that has the type set, a constant C that has the type set and
a ternary predicate P and states that the following holds

ex f being Function of [:A,B:],C st for x,y st x ∈ A & y ∈ B holds P[x, y, f .hx, yi]

provided the parameters satisfy the following conditions:

• for x,y st x ∈ A & y ∈ B ex z st z ∈ C & P[x, y, z],

• for x,y,z1,z2 st x ∈ A & y ∈ B & P[x, y, z1] & P[x, y, z2] holds z1 = z2.

The scheme Lambda2 concerns a constant A that has the type set, a constant B that
has the type set, a constant C that has the type set and a binary functor F and states
that the following holds

ex f being Function of [:A,B:],C st for x,y st x ∈ A & y ∈ B holds f .hx, yi = F(x, y)


164 Czeslaw Byliński

provided the parameters satisfy the following condition:

• for x,y st x ∈ A & y ∈ B holds F(x, y) ∈ C.

We now state a proposition

(120) for f 1,f 2 being Function of [:C, D:],E


st for c,d holds f 1.hc, di = f 2.hc, di holds f 1 = f 2.

Now we present two schemes. The scheme FuncEx2D deals with a constant A that
has the type DOMAIN, a constant B that has the type DOMAIN, a constant C that has
the type DOMAIN and a ternary predicate P and states that the following holds

ex f being Function of [:A,B:],C


st for x being Element of A for y being Element of B holds P[x, y, f .hx, yi]

provided the parameters satisfy the following conditions:

• for x being Element of A


for y being Element of B ex z being Element of C st P[x, y, z],

• for x being Element of A for y being Element of B


for z1,z2 being Element of C st P[x, y, z1] & P[x, y, z2] holds z1 = z2.

The scheme Lambda2D concerns a constant A that has the type DOMAIN, a constant
B that has the type DOMAIN, a constant C that has the type DOMAIN and a binary
functor F yielding values of the type Element of C and states that the following holds

ex f being Function of [:A,B:],C


st for x being Element of A for y being Element of B holds f .hx, yi = F(x, y)

for all values of the parameters.

References
[1] Czeslaw Byliński. Functions and their basic properties. Formalized Mathematics, 1,
1990.

[2] Andrzej Trybulec. Tarski Grothendieck set theory. Formalized Mathematics, 1, 1990.

[3] Zinaida Trybulec and Halina Świe czkowska. Boolean properties of sets. Formalized

Mathematics, 1, 1990.

Received April 6, 1989


FORMALIZED MATHEMATICS
Number 1, January 1990
Université Catholique de Louvain

Finite Sets

Agata Darmochwal1
Warsaw University
Bialystok

Summary. The article contains the definition of a finite set based on the
notion of finite sequence. Some theorems about properties of finite sets and finite
families of sets are proved.

The terminology and notation used here are introduced in the following papers: [5], [6],
[4], [2], [1], and [3]. Let A have the type set. The predicate

A is finite is defined by ex p being FinSequence st rng p = A.

For simplicity we adopt the following convention: A, B, C, D, X, Y have the type


set; x, y, z, x1, x2, x3, x4, x5, x6, x7, x8 have the type Any; f has the type Function;
n has the type Nat. The following propositions are true:

(1) A is finite iff ex p being FinSequence st rng p = A,

(2) for p being FinSequence holds rng p is finite ,

(3) Seg n is finite ,

(4) ∅ is finite ,

(5) {x} is finite ,

(6) {x, y} is finite ,

(7) {x, y, z} is finite ,

(8) {x1,x2,x3,x4} is finite ,

(9) {x1,x2,x3,x4,x5} is finite ,


1
Supported by RPBP.III-24.C1.

cf 1990 Fondation Philippe le Hodey


165 ISSN 0777-4028
166 Agata Darmochwal

(10) {x1,x2,x3,x4,x5,x6} is finite ,

(11) {x1,x2,x3,x4,x5,x6,x7} is finite ,

(12) {x1,x2,x3,x4,x5,x6,x7,x8} is finite ,

(13) A ⊆ B & B is finite implies A is finite ,

(14) A is finite & B is finite implies A ∪ B is finite ,

(15) A is finite implies A ∩ B is finite & B ∩ A is finite ,

(16) A is finite implies A \ B is finite ,

(17) A is finite implies f ◦ A is finite ,

(18) A is finite implies for X being Subset-Family of A st X 6= ∅ ex x being set


st x ∈ X & for B being set st B ∈ X holds x ⊆ B implies B = x.

The scheme Finite deals with a constant A that has the type set and a unary predicate
P and states that the following holds

P[A]

provided the parameters satisfy the following conditions:

• A is finite ,

• P[∅],

• for x,B being set st x ∈ A & B ⊆ A & P[B] holds P[B ∪ {x}].

We now state several propositions:

(19) A is finite & B is finite implies [:A, B:] is finite ,

(20) A is finite & B is finite & C is finite implies [:A, B, C:] is finite ,

(21) A is finite & B is finite & C is finite & D is finite


implies [:A, B, C, D:] is finite ,

(22) B 6= ∅ & [:A, B:] is finite implies A is finite ,

(23) A 6= ∅ & [:A, B:] is finite implies B is finite ,

(24) A is finite iff bool A is finite ,


[
(25) A is finite & (for X st X ∈ A holds X is finite) iff A is finite ,

(26) dom f is finite implies rng f is finite ,

(27) Y ⊆ rng f & f -1 Y is finite implies Y is finite .


Finite Sets 167

References
[1] Grzegorz Bancerek and Krzysztof Hryniewiecki. Segments of natural numbers and
finite sequences. Formalized Mathematics, 1, 1990.

[2] Czeslaw Byliński. Functions and their basic properties. Formalized Mathematics, 1,
1990.

[3] Beata Padlewska. Families of sets. Formalized Mathematics, 1, 1990.

[4] Andrzej Trybulec. Enumerated sets. Formalized Mathematics, 1, 1990.

[5] Andrzej Trybulec. Tarski Grothendieck set theory. Formalized Mathematics, 1, 1990.

[6] Zinaida Trybulec and Halina Świe czkowska. Boolean properties of sets. Formalized

Mathematics, 1, 1990.

Received April 6, 1989


168
FORMALIZED MATHEMATICS
Number 1, January 1990
Université Catholique de Louvain

Graphs of Functions.

Czeslaw Byliński1
Warsaw University
Bialystok

Summary. The graph of a function is defined in [1]. In this paper the graph of
a function is redefined as a Relation. Operations on functions are interpreted as the
corresponding operations on relations. Some theorems about graphs of functions
are proved.

The terminology and notation used in this paper have been introduced in the following
papers: [2], [3], [1], and [4]. For simplicity we adopt the following convention: X, X1,
X2, Y , Y 1, Y 2 denote objects of the type set; x, x1, x2, y, y1, y2, z denote objects of
the type Any; f , f 1, f 2, g, g1, g2, h, h1 denote objects of the type Function. Let
us consider f . Let us note that it makes sense to consider the following functor on a
restricted area. Then
graph f is Relation .

Next we state a number of propositions:

(1) for R being Relation st


for x,y1,y2 st hx, y1i ∈ R & hx, y2i ∈ R holds y1 = y2 ex f st graph f = R,

(2) y ∈ rng f iff ex x st hx, yi ∈ graph f,

(3) dom graph f = dom f & rng graph f = rng f,

(4) graph f ⊆ [:dom f,rng f :],

(5) (for x,y holds hx, yi ∈ graph f 1 iff hx, yi ∈ graph f 2) implies f 1 = f 2,

(6) for G being set st G ⊆ graph f ex g st graph g = G,

(7) graph f ⊆ graph g implies dom f ⊆ dom g & rng f ⊆ rng g,


1
Supported by RPBP.III-24.C1.
f
c 1990 Fondation Philippe le Hodey
169 ISSN 0777-4028
170 Czeslaw Byliński

(8) graph f ⊆ graph g iff dom f ⊆ dom g & for x st x ∈ dom f holds f .x = g .x,

(9) dom f = dom g & graph f ⊆ graph g implies f = g,

(10) hx, zi ∈ graph (g · f ) iff ex y st hx, yi ∈ graph f & hy, zi ∈ graph g,

(11) (graph f ) · (graph g) = graph (g · f ),

(12) hx, zi ∈ graph (g · f ) implies hx, f .xi ∈ graph f & hf .x,zi ∈ graph g,

(13) graph h ⊆ graph f


implies graph (g · h) ⊆ graph (g · f ) & graph (h · g) ⊆ graph (f · g),

(14) graph g2 ⊆ graph g1 & graph f 2 ⊆ graph f 1


implies graph (g2 · f 2) ⊆ graph (g1 · f 1),

(15) ex f st graph f = {hx, yi},

(16) graph f = {hx, yi} implies f .x = y,

(17) graph f = {hx, yi} implies dom f = {x} & rng f = {y},

(18) dom f = {x} implies graph f = {hx, f .xi},

(19) (ex f st graph f = {hx1,y1i,hx2,y2i}) iff (x1 = x2 implies y1 = y2),

(20) ex f st graph f = ∅,

(21) graph f = ∅ implies dom f = ∅ & rng f = ∅,

(22) rng f = ∅ or dom f = ∅ implies graph f = ∅,

(23) rng f ∩ dom g = ∅ implies graph (g · f ) = ∅,

(24) graph g = ∅ implies graph (g · f ) = ∅ & graph (f · g) = ∅,

(25) f is one-to-one
iff for x1,x2,y st hx1,yi ∈ graph f & hx2,yi ∈ graph f holds x1 = x2,

(26) graph g ⊆ graph f & f is one-to-one implies g is one-to-one ,

(27) (ex g st graph g = graph f ∩ X) & ex g st graph g = X ∩ graph f,

(28) graph h = graph f ∩ graph g


implies dom h ⊆ dom f ∩ dom g & rng h ⊆ rng f ∩ rng g,

(29) graph h = graph f ∩ graph g & x ∈ dom h implies h.x = f .x & h.x = g .x,
Graphs of Functions. 171

(30) (f is one-to-one or g is one-to-one) & graph h = graph f ∩ graph g


implies h is one-to-one ,

(31) dom f ∩ dom g = ∅ implies ex h st graph h = graph f ∪ graph g,

(32) graph f ⊆ graph h & graph g ⊆ graph h


implies ex h1 st graph h1 = graph f ∪ graph g,

(33) graph h = graph (f ) ∪ graph (g)


implies dom h = dom f ∪ dom g & rng h = rng f ∪ rng g,

(34) x ∈ dom f & graph h = graph f ∪ graph g implies h.x = f .x,

(35) x ∈ dom g & graph h = graph f ∪ graph g implies h.x = g .x,

(36) x ∈ dom h & graph h = graph f ∪ graph g implies h.x = f .x or h.x = g .x,

(37) f is one-to-one
& g is one-to-one & graph h = graph f ∪ graph g & rng f ∩ rng g = ∅
implies h is one-to-one ,

(38) ex g st graph g = graph (f ) \ X,

(39) hx, yi ∈ graph id (X) iff x ∈ X & x = y,

(40) graph id X = 4 X,

(41) x ∈ X iff hx, xi ∈ graph id (X),

(42) hx, yi ∈ graph (f · id (X)) iff x ∈ X & hx, yi ∈ graph f,

(43) hx, yi ∈ graph (id (Y ) · f ) iff hx, yi ∈ graph f & y ∈ Y,

(44) graph (f · id (X)) ⊆ graph f & graph (id (X) · f ) ⊆ graph (f ),

(45) graph id ∅ = ∅,

(46) graph f = ∅ implies f is one-to-one ,

(47) f is one-to-one implies for x,y holds hy, xi ∈ graph (f -1 ) iff hx, yi ∈ graph f,

(48) f is one-to-one implies graph (f -1 ) = (graph f )˜,

(49) graph f = ∅ implies graph (f -1 ) = ∅,

(50) hx, yi ∈ graph (f | X) iff x ∈ X & hx, yi ∈ graph f,


172 Czeslaw Byliński

(51) graph (f | X) = (graph f ) | X,

(52) x ∈ dom f & x ∈ X iff hx, f .xi ∈ graph (f | X),

(53) graph (f | X) ⊆ graph f,

(54) graph ((f | X) · h) ⊆ graph (f · h) & graph (g · (f | X)) ⊆ graph (g · f ),

(55) graph (f | X) = graph (f ) ∩ [:X, rng f :],

(56) X ⊆ Y implies graph (f | X) ⊆ graph (f | Y ),

(57) graph f 1 ⊆ graph f 2 implies graph (f 1 | X) ⊆ graph (f 2 | X),

(58) graph f 1 ⊆ graph f 2 & X1 ⊆ X2 implies graph (f 1 | X1) ⊆ graph (f 2 | X2),

(59) graph (f | (X ∪ Y )) = graph (f | X) ∪ graph (f | Y ),

(60) graph (f | (X ∩ Y )) = graph (f | X) ∩ graph (f | Y ),

(61) graph (f | (X \ Y )) = graph (f | X) \ graph (f | Y ),

(62) graph (f | ∅) = ∅,

(63) graph f = ∅ implies graph (f | X) = ∅,

(64) graph g ⊆ graph f implies f | dom g = g,

(65) hx, yi ∈ graph (Y | f ) iff y ∈ Y & hx, yi ∈ graph f,

(66) graph (Y | f ) = Y | (graph f ),

(67) x ∈ dom f & f .x ∈ Y iff hx, f .xi ∈ graph (Y | f ),

(68) graph (Y | f ) ⊆ graph (f ),

(69) graph ((Y | f ) · h) ⊆ graph (f · h) & graph (g · (Y | f )) ⊆ graph (g · f ),

(70) graph (Y | f ) = graph (f ) ∩ [:dom f,Y :],

(71) X ⊆ Y implies graph (X | f ) ⊆ graph (Y | f ),

(72) graph f 1 ⊆ graph f 2 implies graph (Y | f 1) ⊆ graph (Y | f 2),

(73) graph f 1 ⊆ graph f 2 & Y 1 ⊆ Y 2 implies graph (Y 1 | f 1) ⊆ graph (Y 2 | f 2),

(74) graph ((X ∪ Y ) | f ) = graph (X | f ) ∪ graph (Y | f ),

(75) graph ((X ∩ Y ) | f ) = graph (X | f ) ∩ graph (Y | f ),


Graphs of Functions. 173

(76) graph ((X \ Y ) | f ) = graph (X | f ) \ graph (Y | f ),

(77) graph (∅ | f ) = ∅,

(78) graph f = ∅ implies graph (Y | f ) = ∅,

(79) graph g ⊆ graph f & f is one-to-one implies rng g | f = g,

(80) y ∈ f ◦ X iff ex x st hx, yi ∈ graph f & x ∈ X,

(81) f ◦ X = (graph f ) ◦ X,

(82) graph f = ∅ implies f ◦ X = ∅,

(83) graph f 1 ⊆ graph f 2 implies f 1 ◦ X ⊆ f 2 ◦ X,

(84) graph f 1 ⊆ graph f 2 & X1 ⊆ X2 implies f 1 ◦ X1 ⊆ f 2 ◦ X2,

(85) x ∈ f -1 Y iff ex y st hx, yi ∈ graph f & y ∈ Y,

(86) f -1 Y = (graph f ) -1 Y,

(87) x ∈ f -1 Y iff hx, f .xi ∈ graph f & f .x ∈ Y,

(88) graph f = ∅ implies f -1 Y = ∅,

(89) graph f 1 ⊆ graph f 2 implies f 1 -1 Y ⊆ f 2 -1 Y,

(90) graph f 1 ⊆ graph f 2 & Y 1 ⊆ Y 2 implies f 1 -1 Y 1 ⊆ f 2 -1 Y 2.

References
[1] Czeslaw Byliński. Functions and their basic properties. Formalized Mathematics, 1,
1990.

[2] Andrzej Trybulec. Tarski Grothendieck set theory. Formalized Mathematics, 1, 1990.

[3] Zinaida Trybulec and Halina Świe czkowska. Boolean properties of sets. Formalized

Mathematics, 1, 1990.

[4] Edmund Woronowicz. Relations and their basic properties. Formalized Mathematics,
1, 1990.

Received April 14, 1989


174
FORMALIZED MATHEMATICS
Number 1, January 1990
Université Catholique de Louvain

Binary Operations

Czeslaw Byliński1
Warsaw University
Bialystok

Summary. In this paper we define binary and unary operations on domains.


We also define the following predicates concerning the operations: . . . is commu-
tative, . . . is associative, . . . is the unity of . . ., and . . . is distributive wrt . . .. A
number of schemes useful in justifying the existence of the operations are proved.

The articles [3], [1], and [2] provide the notation and terminology for this paper. The
arguments of the notions defined below are the following: f which is an object of the
type Function; a, b which are objects of the type Any. The functor

f .(a, b),

with values of the type Any, is defined by

it = f .ha, bi.

One can prove the following proposition

(1) for f being Function for a,b being Any holds f .(a, b) = f .ha, bi.

In the sequel A, B, C will denote objects of the type DOMAIN. The arguments
of the notions defined below are the following: A, B, C which are objects of the type
reserved above; f which is an object of the type Function of [:A, B:], C; a which is an
object of the type Element of A; b which is an object of the type Element of B. Let
us note that it makes sense to consider the following functor on a restricted area. Then

f .(a, b) is Element of C.

The following proposition is true

(2) for f 1,f 2 being Function of [:A, B:],C st


for a being Element of A
1
Supported by RPBP.III-24.C1.
f
c 1990 Fondation Philippe le Hodey
175 ISSN 0777-4028
176 Czeslaw Byliński

for b being Element of B holds f 1.(a, b) = f 2.(a, b)


holds f 1 = f 2.

We now define two new modes. Let us consider A.

Unary Operation of A stands for Function of A, A.

Binary Operation of A stands for Function of [:A, A:],A.

We now state a proposition

(3) for f being Function of A, A holds f is Unary Operation of A.

In the sequel u denotes an object of the type Unary Operation of A. Next we


state a proposition

(4) for f being Function of [:A, A:],A holds f is Binary Operation of A.

In the article we present several logical schemes. The scheme UnOpEx concerns a
constant A that has the type DOMAIN and a binary predicate P and states that the
following holds

ex u being Unary Operation of A st for x being Element of A holds P[x, u.x]

provided the parameters satisfy the following conditions:

• for x being Element of A ex y being Element of A st P[x, y],

• for x,y1,y2 being Element of A st P[x, y1] & P[x, y2] holds y1 = y2.

The scheme UnOpLambda concerns a constant A that has the type DOMAIN and a
unary functor F yielding values of the type Element of A and states that the following
holds

ex u being Unary Operation of A st for x being Element of A holds u.x = F(x)

for all values of the parameters.


For simplicity we adopt the following convention: o, o0 will have the type Binary Operation
of A; a, b, c, e, e1, e2 will have the type Element of A. Let us consider A, o, a, b. Let
us note that it makes sense to consider the following functor on a restricted area. Then

o.(a, b) is Element of A.

Now we present two schemes. The scheme BinOpEx concerns a constant A that has
the type DOMAIN and a ternary predicate P and states that the following holds

ex o being Binary Operation of A


st for a,b being Element of A holds P[a, b, o.(a, b)]
Binary Operations 177

provided the parameters satisfy the following conditions:

• for x,y being Element of A ex z being Element of A st P[x, y, z],

• for x,y being Element of A


for z1,z2 being Element of A st P[x, y, z1] & P[x, y, z2] holds z1 = z2.

The scheme BinOpLambda concerns a constant A that has the type DOMAIN and a
binary functor F yielding values of the type Element of A and states that the following
holds

ex o being Binary Operation of A


st for a,b being Element of A holds o.(a, b) = F(a, b)

for all values of the parameters.


We now define three new predicates. Let us consider A, o. The predicate

o is commutative is defined by for a,b holds o.(a, b) = o.(b, a).

The predicate

o is associative is defined by for a,b,c holds o.(a, o.(b, c)) = o.(o.(a, b),c).

The predicate

o is an idempotentOp is defined by for a holds o.(a, a) = a.

Next we state three propositions:

(5) o is commutative iff for a,b holds o.(a, b) = o.(b, a),

(6) o is associative iff for a,b,c holds o.(a, o.(b, c)) = o.(o.(a, b),c),

(7) o is an idempotentOp iff for a holds o.(a, a) = a.

We now define two new predicates. Let us consider A, e, o. The predicate

e is a left unity wrt o is defined by for a holds o.(e, a) = a.

The predicate

e is a right unity wrt o is defined by for a holds o.(a, e) = a.

Let us consider A, e, o. The predicate

e is a unity wrt o is defined by e is a left unity wrt o & e is a right unity wrt o.

We now state a number of propositions:

(8) e is a left unity wrt o iff for a holds o.(e, a) = a,


178 Czeslaw Byliński

(9) e is a right unity wrt o iff for a holds o.(a, e) = a,

(10) e is a unity wrt o iff e is a left unity wrt o & e is a right unity wrt o,

(11) e is a unity wrt o iff for a holds o.(e, a) = a & o.(a, e) = a,

(12) o is commutative implies (e is a unity wrt o iff for a holds o.(e, a) = a),

(13) o is commutative implies (e is a unity wrt o iff for a holds o.(a, e) = a),

(14) o is commutative implies (e is a unity wrt o iff e is a left unity wrt o),

(15) o is commutative implies (e is a unity wrt o iff e is a right unity wrt o),

(16) o is commutative implies (e is a left unity wrt o iff e is a right unity wrt o),

(17) e1 is a left unity wrt o & e2 is a right unity wrt o implies e1 = e2,

(18) e1 is a unity wrt o & e2 is a unity wrt o implies e1 = e2.

Let us consider A, o. Assume that the following holds

ex e st e is a unity wrt o.

The functor
the unity wrt o,

with values of the type Element of A, is defined by

it is a unity wrt o.

One can prove the following proposition

(19) (ex e st e is a unity wrt o)


implies for e holds e = the unity wrt o iff e is a unity wrt o.

We now define two new predicates. Let us consider A, o0 , o. The predicate

o0 is left distributive wrt o

is defined by

for a,b,c holds o0 .(a, o.(b, c)) = o.(o0 .(a, b),o0 .(a, c)).

The predicate
o0 is right distributive wrt o

is defined by

for a,b,c holds o0 .(o.(a, b),c) = o.(o0 .(a, c),o0 .(b, c)).
Binary Operations 179

Let us consider A, o0 , o. The predicate

o0 is distributive wrt o

is defined by

o0 is left distributive wrt o & o0 is right distributive wrt o.

We now state several propositions:

(20) o0 is left distributive wrt o


iff for a,b,c holds o0 .(a, o.(b, c)) = o.(o0 .(a, b),o0 .(a, c)),

(21) o0 is right distributive wrt o


iff for a,b,c holds o0 .(o.(a, b),c) = o.(o0 .(a, c),o0 .(b, c)),

(22) o0 is distributive wrt o


iff o0 is left distributive wrt o & o0 is right distributive wrt o,

(23) o0 is distributive wrt o iff for a,b,c holds


o0 .(a, o.(b, c)) = o.(o0 .(a, b),o0 .(a, c)) & o0 .(o.(a, b),c) = o.(o0 .(a, c),o0 .(b, c)),

(24) o0 is commutative implies (o0 is distributive wrt o


iff for a,b,c holds o0 .(a, o.(b, c)) = o.(o0 .(a, b),o0 .(a, c))),

(25) o0 is commutative implies (o0 is distributive wrt o


iff for a,b,c holds o0 .(o.(a, b),c) = o.(o0 .(a, c),o0 .(b, c))),

(26) o0 is commutative
implies (o0 is distributive wrt o iff o0 is left distributive wrt o),

(27) o0 is commutative
implies (o0 is distributive wrt o iff o0 is right distributive wrt o),

(28) o0 is commutative
implies (o0 is right distributive wrt o iff o0 is left distributive wrt o).

Let us consider A, u, o. The predicate

u is distributive wrt o is defined by for a,b holds u.(o.(a, b)) = o.((u.a),(u.b)).

The following proposition is true

(29) u is distributive wrt o iff for a,b holds u.(o.(a, b)) = o.((u.a),(u.b)).
180 Czeslaw Byliński

References
[1] Czeslaw Byliński. Functions and their basic properties. Formalized Mathematics, 1,
1990.

[2] Czeslaw Byliński. Functions from a set to a set. Formalized Mathematics, 1, 1990.

[3] Andrzej Trybulec. Tarski Grothendieck set theory. Formalized Mathematics, 1, 1990.

Received April 14, 1989


FORMALIZED MATHEMATICS
Number 1, January 1990
Université Catholique de Louvain

Relations Defined on Sets

Edmund Woronowicz1
Warsaw University
Bialystok

Summary. The article includes theorems concerning properties of relations


defined as a subset of the Cartesian product of two sets (mode Relation of X,Y
where X,Y are sets). Some notions, introduced in [3] such as domain, codomain,
field of a relation, composition of relations, image and inverse image of a set under
a relation are redefined.

The articles [1], [2], and [3] provide the terminology and notation for this paper. For
simplicity we adopt the following convention: A, B, X, X1, Y , Y 1, Z will denote
objects of the type set; a, x, y will denote objects of the type Any. Let us consider
X, Y . The mode
Relation of X, Y,

which widens to the type Relation, is defined by

it ⊆ [:X, Y :].

The following proposition is true

(1) for R being Relation holds R ⊆ [:X, Y :] iff R is Relation of X, Y.

In the sequel P , R will denote objects of the type Relation of X, Y . The following
propositions are true:

(2) A ⊆ R implies A ⊆ [:X, Y :],

(3) A ⊆ [:X, Y :] implies A is Relation of X, Y,

(4) A ⊆ R implies A is Relation of X, Y,

(5) [:X, Y :] is Relation of X, Y,


1
Supported by RPBP III.24 C1
f
c 1990 Fondation Philippe le Hodey
181 ISSN 0777-4028
182 Edmund Woronowicz

(6) a ∈ R implies ex x,y st a = hx, yi & x ∈ X & y ∈ Y,

(7) hx, yi ∈ R implies x ∈ X & y ∈ Y,

(8) x ∈ X & y ∈ Y implies {hx, yi} is Relation of X, Y,

(9) for R being Relation st dom R ⊆ X holds R is Relation of X, rng R,

(10) for R being Relation st rng R ⊆ Y holds R is Relation of dom R,Y,

(11) for R being Relation


st dom R ⊆ X & rng R ⊆ Y holds R is Relation of X, Y,

(12) dom R ⊆ X & rng R ⊆ Y,

(13) dom R ⊆ X1 implies R is Relation of X1,Y,

(14) rng R ⊆ Y 1 implies R is Relation of X, Y 1,

(15) X ⊆ X1 implies R is Relation of X1,Y,

(16) Y ⊆ Y 1 implies R is Relation of X, Y 1,

(17) X ⊆ X1 & Y ⊆ Y 1 implies R is Relation of X1,Y 1.

Let us consider X, Y , P , R. Let us note that it makes sense to consider the following
functors on restricted areas. Then

P ∪R is Relation of X, Y,

P ∩R is Relation of X, Y,

P \R is Relation of X, Y.

We now state a proposition

(18) R ∩ [:X, Y :] = R.

Let us consider X, Y , R. Let us note that it makes sense to consider the following
functors on restricted areas. Then

dom R is Subset of X,

rng R is Subset of Y.

Next we state several propositions:

(19) field R ⊆ X ∪ Y,

(20) for R being Relation holds R is Relation of dom R,rng R,


Relations Defined on Sets 183

(21) dom R ⊆ X1 & rng R ⊆ Y 1 implies R is Relation of X1,Y 1,

(22) (for x st x ∈ X ex y st hx, yi ∈ R) iff dom R = X,

(23) (for y st y ∈ Y ex x st hx, yi ∈ R) iff rng R = Y.

Let us consider X, Y , R. Let us note that it makes sense to consider the following
functor on a restricted area. Then

R˜ is Relation of Y, X.

The arguments of the notions defined below are the following: X, Y , Z which are
objects of the type reserved above; P which is an object of the type Relation of X, Y ;
R which is an object of the type Relation of Y , Z. Let us note that it makes sense to
consider the following functor on a restricted area. Then

P ·R is Relation of X, Z.

One can prove the following propositions:

(24) dom (R˜) = rng R & rng (R˜) = dom R,

(25) Ø is Relation of X, Y,

(26) R is Relation of ∅,Y implies R = Ø ,

(27) R is Relation of X, ∅ implies R = Ø ,

(28) 4 X ⊆ [:X, X:],

(29) 4 X is Relation of X, X,

(30) 4 A ⊆ R implies A ⊆ dom R & A ⊆ rng R,

(31) 4 X ⊆ R implies X = dom R & X ⊆ rng R,

(32) 4 Y ⊆ R implies Y ⊆ dom R & Y = rng R.

Let us consider X, Y , R, A. Let us note that it makes sense to consider the following
functor on a restricted area. Then

R|A is Relation of X, Y.

Let us consider X, Y , B, R. Let us note that it makes sense to consider the following
functor on a restricted area. Then

B|R is Relation of X, Y.

The following four propositions are true:

(33) R | X1 is Relation of X1,Y,


184 Edmund Woronowicz

(34) X ⊆ X1 implies R | X1 = R,

(35) Y 1 | R is Relation of X, Y 1,

(36) Y ⊆ Y 1 implies Y 1 | R = R.

Let us consider X, Y , R, A. Let us note that it makes sense to consider the following
functors on restricted areas. Then

R◦A is Subset of Y,

R -1 A is Subset of X.

Next we state three propositions:

(37) R ◦ A ⊆ Y & R -1 A ⊆ X,

(38) R ◦ X = rng R & R -1 Y = dom R,

(39) R ◦ (R -1 Y ) = rng R & R -1 (R ◦ X) = dom R.

The scheme Rel On Set Ex deals with a constant A that has the type set, a constant
B that has the type set and a binary predicate P and states that the following holds

ex R being Relation of A,B st for x,y holds hx, yi ∈ R iff x ∈ A & y ∈ B & P[x, y]

for all values of the parameters.


Let us consider X.

Relation of X stands for Relation of X, X.

We now state three propositions:

(40) for R being Relation of X, X holds R ⊆ [:X, X:] iff R is Relation of X,

(41) [:X, X:] is Relation of X,

(42) for R being Relation of X, X holds R is Relation of X.

In the sequel R denotes an object of the type Relation of X. One can prove the
following propositions:

(43) 4 X is Relation of X,

(44) 4 X ⊆ R implies X = dom R & X = rng R,

(45) R · (4 X) = R & (4 X) · R = R.

For simplicity we adopt the following convention: D, D1, D2, E, F denote objects
of the type DOMAIN; R denotes an object of the type Relation of D, E; x denotes
Relations Defined on Sets 185

an object of the type Element of D; y denotes an object of the type Element of E.


We now state a proposition
(46) 4 D 6= Ø .

Let us consider D, E, R. Let us note that it makes sense to consider the following
functors on restricted areas. Then
dom R is Element of bool D,

rng R is Element of bool E.


Next we state several propositions:
(47) for x being Element of D
holds x ∈ dom R iff ex y being Element of E st hx, yi ∈ R,

(48) for y being Element of E


holds y ∈ rng R iff ex x being Element of D st hx, yi ∈ R,

(49) for x being Element of D


holds x ∈ dom R implies ex y being Element of E st y ∈ rng R,

(50) for y being Element of E


holds y ∈ rng R implies ex x being Element of D st x ∈ dom R,

(51) for P being Relation of D, E, R being Relation of E, F


for x being Element of D, z being Element of F
holds hx, zi ∈ P · R iff ex y being Element of E st hx, yi ∈ P & hy, zi ∈ R.

Let us consider D, E, R, D1. Let us note that it makes sense to consider the following
functors on restricted areas. Then
R ◦ D1 is Element of bool E,

R -1 D1 is Element of bool D.
We now state two propositions:
(52) y ∈ R ◦ D1 iff ex x being Element of D st hx, yi ∈ R & x ∈ D1,

(53) x ∈ R -1 D2 iff ex y being Element of E st hx, yi ∈ R & y ∈ D2.

The scheme Rel On Dom Ex concerns a constant A that has the type DOMAIN, a
constant B that has the type DOMAIN and a binary predicate P and states that the
following holds
ex R being Relation of A,B st for x being Element of A, y being Element of B
holds hx, yi ∈ R iff x ∈ A & y ∈ B & P[x, y]

for all values of the parameters.


186 Edmund Woronowicz

References
[1] Andrzej Trybulec. Tarski Grothendieck set theory. Formalized Mathematics, 1, 1990.

[2] Zinaida Trybulec and Halina Świe czkowska. Boolean properties of sets. Formalized

Mathematics, 1, 1990.

[3] Edmund Woronowicz. Relations and their basic properties. Formalized Mathematics,
1, 1990.

Received April 14, 1989


FORMALIZED MATHEMATICS
Number 1, January 1990
Université Catholique de Louvain

Boolean Domains

Andrzej Trybulec1 Agata Darmochwal2


Warsaw University Warsaw University
Bialystok Bialystok

Summary. BOOLE DOMAIN is a SET DOMAIN that is closed under union


and difference. This condition is equivalent to being closed under symmetric dif-
ference and one of the following operations: union, intersection or difference. We
introduce the set of all finite subsets of a set A, denoted by Fin A. The mode Finite
Subset of a set A is introduced with the mother type: Element of Fin A. In con-
sequence, “Finite Subset of . . . ” is an elementary type, therefore one may use such
types as “set of Finite Subset of A”, “[(Finite Subset of A), Finite Subset of A]”,
and so on. The article begins with some auxiliary theorems that belong really to
[5] or [1] but are missing there. Moreover, bool A is redefined as a SET DOMAIN,
for an arbitrary set A.

The articles [4], [5], [3], and [2] provide the notation and terminology for this paper. In
the sequel X, Y will denote objects of the type set. The following propositions are
true:

(1) X misses Y implies X \ Y = X & Y \ X = Y,

(2) X misses Y implies (X ∪ Y ) \ Y = X & (X ∪ Y ) \ X = Y,

(3) . (Y \ X),
X ∪Y =X −

(4) . Y −
X ∪Y =X − . X ∩ Y,

(5) . (X ∩ Y ),
X \Y =X −

(6) . Y −
X ∩Y =X − . (X ∪ Y ),

(7) (for x being set st x ∈ X holds x ∈ Y ) implies X ⊆ Y.


1
Supported by RPBP.III-24.C1.
2
Supported by RPBP.III-24.C1.
f
c 1990 Fondation Philippe le Hodey
187 ISSN 0777-4028
188 Andrzej Trybulec and Agata Darmochwal

Let us consider X. Let us note that it makes sense to consider the following functor
on a restricted area. Then

bool X is SET DOMAIN .

The following proposition is true

(8) for Y being Element of bool X holds Y ⊆ X.

The mode
BOOLE DOMAIN ,

which widens to the type SET DOMAIN, is defined by

for X,Y being Element of it holds X ∪ Y ∈ it & X \ Y ∈ it .

The following proposition is true

(9) for A being SET DOMAIN holds A is BOOLE DOMAIN


iff for X,Y being Element of A holds X ∪ Y ∈ A & X \ Y ∈ A.

In the sequel A will denote an object of the type BOOLE DOMAIN. One can
prove the following propositions:

(10) X ∈ A & Y ∈ A implies X ∪ Y ∈ A & X \ Y ∈ A,

(11) X is Element of A & Y is Element of A implies X ∪ Y is Element of A,

(12) X is Element of A & Y is Element of A implies X \ Y is Element of A.

The arguments of the notions defined below are the following: A which is an object
of the type reserved above; X, Y which are objects of the type Element of A. Let us
note that it makes sense to consider the following functors on restricted areas. Then

X ∪Y is Element of A,

X \Y is Element of A.

The following propositions are true:

(13) X is Element of A & Y is Element of A implies X ∩ Y is Element of A,

(14) . Y is Element of A,
X is Element of A & Y is Element of A implies X −

(15) for A being SET DOMAIN st


. Y ∈A&X \Y ∈A
for X,Y being Element of A holds X −
holds A is BOOLE DOMAIN ,
Boolean Domains 189

(16) for A being SET DOMAIN st


. Y ∈A& X ∩Y ∈ A
for X,Y being Element of A holds X −
holds A is BOOLE DOMAIN ,

(17) for A being SET DOMAIN st


. Y ∈A& X ∪Y ∈ A
for X,Y being Element of A holds X −
holds A is BOOLE DOMAIN .

The arguments of the notions defined below are the following: A which is an object
of the type reserved above; X, Y which are objects of the type Element of A. Let us
note that it makes sense to consider the following functors on restricted areas. Then

X ∩Y is Element of A,
. Y
X− is Element of A.

We now state four propositions:

(18) ∅ ∈ A,

(19) ∅ is Element of A,

(20) bool A is BOOLE DOMAIN ,

(21) for A,B being BOOLE DOMAIN holds A ∩ B is BOOLE DOMAIN .

In the sequel A, B will denote objects of the type set. Let us consider A. The
functor
Fin A,

with values of the type BOOLE DOMAIN, is defined by

for X being set holds X ∈ it iff X ⊆ A & X is finite .

The following propositions are true:

(22) B ∈ Fin A iff B ⊆ A & B is finite ,

(23) A ⊆ B implies Fin A ⊆ Fin B,

(24) Fin (A ∩ B) = Fin A ∩ Fin B,

(25) Fin A ∪ Fin B ⊆ Fin (A ∪ B),

(26) Fin A ⊆ bool A,

(27) A is finite implies Fin A = bool A,

(28) Fin ∅ = {∅}.


190 Andrzej Trybulec and Agata Darmochwal

Let us consider A.

Finite Subset of A stands for Element of Fin A.

Next we state a proposition

(29) for X being Element of Fin A holds X is Finite Subset of A.

The arguments of the notions defined below are the following: A which is an object
of the type reserved above; X, Y which are objects of the type Finite Subset of A. Let
us note that it makes sense to consider the following functors on restricted areas. Then

X ∪Y is Finite Subset of A,

X ∩Y is Finite Subset of A,

X \Y is Finite Subset of A,
. Y
X− is Finite Subset of A.

One can prove the following propositions:

(30) for X being Finite Subset of A holds X is finite ,

(31) for X being Finite Subset of A holds X ⊆ A,

(32) for X being Finite Subset of A holds X is Subset of A,

(33) ∅ is Finite Subset of A,

(34) A is finite implies for X being Subset of A holds X is Finite Subset of A.

References
[1] Grzegorz Bancerek. The ordinal numbers. Formalized Mathematics, 1, 1990.

[2] Agata Darmochwal. Finite sets. Formalized Mathematics, 1, 1990.

[3] Beata Padlewska. Families of sets. Formalized Mathematics, 1, 1990.

[4] Andrzej Trybulec. Tarski Grothendieck set theory. Formalized Mathematics, 1, 1990.

[5] Zinaida Trybulec and Halina Świe czkowska. Boolean properties of sets. Formalized

Mathematics, 1, 1990.

Received April 14, 1989


FORMALIZED MATHEMATICS
Number 1, January 1990
Université Catholique de Louvain

Models and Satisfiability

Grzegorz Bancerek1
Warsaw University
Bialystok

Summary. The article includes schemes of defining by structural induction,


and definitions and theorems related to: the set of variables which have free occur-
rences in a ZF-formula, the set of all valuations of variables in a model, the set of all
valuations which satisfy a ZF-formula in a model, the satisfiability of a ZF-formula
in a model by a valuation, the validity of a ZF-formula in a model, the axioms of
ZF-language, the model of the ZF set theory.

The articles [6], [7], [3], [1], [4], [5], and [2] provide the notation and terminology for this
paper. For simplicity we adopt the following convention: H, H 0 will have the type
ZF-formula; x, y, z will have the type Variable; a, b, c will have the type Any; A, X
will have the type set. In the article we present several logical schemes. The scheme
ZFsch ex deals with a binary functor F, a binary functor G, a unary functor H, a binary
functor I, a binary functor J and a constant A that has the type ZF-formula, and states
that the following holds

ex a,A st (for x,y holds hx - y,F(x, y)i ∈ A & hx  y,G(x, y)i ∈ A) & hA,ai ∈ A &
for H,a st hH, ai ∈ A holds (H is a equality implies a = F(Var1 H,Var2 H)) &
(H is a membership implies a = G(Var1 H,Var2 H)) &
(H is negative implies ex b st a = H(b) & hthe argument of H,bi ∈ A) &
(H is conjunctive implies ex b,c
st a = I(b, c) & hthe left argument of H,bi ∈ A & hthe right argument of H,ci ∈ A)
& (H is universal
implies ex b,x st x = bound in H & a = J (x, b) & hthe scope of H,bi ∈ A)

for all values of the parameters.


1
Supported by RPBP.III-24.C1.
f
c 1990 Fondation Philippe le Hodey
191 ISSN 0777-4028
192 Grzegorz Bancerek

The scheme ZFsch uniq deals with a binary functor F, a binary functor G, a unary
functor H, a binary functor I, a binary functor J , a constant A that has the type
ZF-formula, a constant B and a constant C and states that the following holds

B=C

provided the parameters satisfy the following conditions:

• ex A st (for x,y holds hx - y,F(x, y)i ∈ A & hx  y,G(x, y)i ∈ A) & hA,Bi ∈ A
& for H,a st hH, ai ∈ A holds
(H is a equality implies a = F(Var1 H,Var2 H)) &
(H is a membership implies a = G(Var1 H,Var2 H)) &
(H is negative implies ex b st a = H(b) & hthe argument of H,bi ∈ A) &
(H is conjunctive implies ex b,c st a = I(b, c)
& hthe left argument of H,bi ∈ A & hthe right argument of H,ci ∈ A)
& (H is universal
implies ex b,x st x = bound in H & a = J (x, b) & hthe scope of H,bi ∈ A),

• ex A st (for x,y holds hx - y,F(x, y)i ∈ A & hx  y,G(x, y)i ∈ A) & hA,Ci ∈ A
& for H,a st hH, ai ∈ A holds
(H is a equality implies a = F(Var1 H,Var2 H)) &
(H is a membership implies a = G(Var1 H,Var2 H)) &
(H is negative implies ex b st a = H(b) & hthe argument of H,bi ∈ A) &
(H is conjunctive implies ex b,c st a = I(b, c)
& hthe left argument of H,bi ∈ A & hthe right argument of H,ci ∈ A)
& (H is universal
implies ex b,x st x = bound in H & a = J (x, b) & hthe scope of H,bi ∈ A).

The scheme ZFsch result deals with a binary functor F, a binary functor G, a unary
functor H, a binary functor I, a binary functor J , a constant A that has the type
ZF-formula and a unary functor K and states that the following holds

(A is a equality implies K(A) = F(Var1 A,Var2 A)) &


(A is a membership implies K(A) = G(Var1 A,Var2 A)) &
(A is negative implies K(A) = H(K(the argument of A))) &
(A is conjunctive implies for a,b st
a = K(the left argument of A) & b = K(the right argument of A)
holds K(A) = I(a, b))
& (A is universal implies K(A) = J (bound in A,K(the scope of A)))
Models and Satisfiability 193

provided the parameters satisfy the following condition:

• for H 0 ,a holds a = K(H 0 ) iff ex A st


(for x,y holds hx - y,F(x, y)i ∈ A & hx  y,G(x, y)i ∈ A) & hH 0 ,ai ∈ A &
for H,a st hH, ai ∈ A holds (H is a equality implies a = F(Var1 H,Var2 H))
& (H is a membership implies a = G(Var1 H,Var2 H)) &
(H is negative implies ex b st a = H(b) & hthe argument of H,bi ∈ A) &
(H is conjunctive implies ex b,c st a = I(b, c)
& hthe left argument of H,bi ∈ A & hthe right argument of H,ci ∈ A)
& (H is universal
implies ex b,x st x = bound in H & a = J (x, b) & hthe scope of H,bi ∈ A).

The scheme ZFsch property concerns a binary functor F, a binary functor G, a unary
functor H, a binary functor I, a binary functor J , a unary functor K, a constant A that
has the type ZF-formula and a unary predicate P and states that the following holds

P[K(A)]

provided the parameters satisfy the following conditions:

• for H 0 ,a holds a = K(H 0 ) iff ex A st


(for x,y holds hx - y,F(x, y)i ∈ A & hx  y,G(x, y)i ∈ A) & hH 0 ,ai ∈ A &
for H,a st hH, ai ∈ A holds (H is a equality implies a = F(Var1 H,Var2 H))
& (H is a membership implies a = G(Var1 H,Var2 H)) &
(H is negative implies ex b st a = H(b) & hthe argument of H,bi ∈ A) &
(H is conjunctive implies ex b,c st a = I(b, c)
& hthe left argument of H,bi ∈ A & hthe right argument of H,ci ∈ A)
& (H is universal
implies ex b,x st x = bound in H & a = J (x, b) & hthe scope of H,bi ∈ A),

• for x,y holds P[F(x, y)] & P[G(x, y)],

• for a st P[a] holds P[H(a)],

• for a,b st P[a] & P[b] holds P[I(a, b)],

• for a,x st P[a] holds P[J (x, a)].

Let us consider H. The functor


Free H,
194 Grzegorz Bancerek

yields the type Any and is defined by

ex A st (for x,y holds hx - y,{x, y}i ∈ A & hx  y,{x, y}i ∈ A) & hH, iti ∈ A &
for H 0 ,a st hH 0 ,ai ∈ A holds (H 0 is a equality implies a = {Var1 H 0 ,Var2 H 0 }) &
(H 0 is a membership implies a = {Var1 H 0 ,Var2 H 0 }) &
(H 0 is negative implies ex b st a = b & hthe argument of H 0 ,bi ∈ A) &
(H 0 is conjunctive implies ex b,c
[
st a = {b, c} & hthe left argument of H 0 ,bi ∈ A & hthe right argument of H 0 ,ci ∈ A)
& (H 0 is universal
[
implies ex b,x st x = bound in H 0 & a = ( {b}) \ {x} & hthe scope of H 0 ,bi ∈ A).

Let us consider H. Let us note that it makes sense to consider the following functor
on a restricted area. Then

Free H is set of Variable .

One can prove the following proposition

(1) for H holds (H is a equality implies Free H = {Var1 H,Var2 H}) &
(H is a membership implies Free H = {Var1 H,Var2 H}) &
(H is negative implies Free H = Free the argument of H) &
(H is conjunctive implies
Free H = Free the left argument of H ∪ Free the right argument of H)
& (H is universal implies Free H = (Free the scope of H) \ {bound in H}).

Let D have the type SET DOMAIN. The functor

VAL D,

with values of the type DOMAIN, is defined by

a ∈ it iff a is Function of VAR ,D.

The arguments of the notions defined below are the following: D1 which is an object
of the type SET DOMAIN; f which is an object of the type Function of VAR, D1;
x which is an object of the type reserved above. Let us note that it makes sense to
consider the following functor on a restricted area. Then

f .x is Element of D1.

For simplicity we adopt the following convention: E will denote an object of the
type SET DOMAIN; f , g will denote objects of the type Function of VAR, E; v1,
v2, v3, v4, v5 will denote objects of the type Element of VAL E. Let us consider H,
E. The functor
St (H, E),
Models and Satisfiability 195

yields the type Any and is defined by

ex A st
(for x,y holds hx - y,{ v1 : for f st f = v1 holds f .x = f .y }i ∈ A
& hx  y,{ v2 : for f st f = v2 holds f .x ∈ f .y }i ∈ A)
& hH, iti ∈ A & for H 0 ,a st hH 0 ,ai ∈ A holds
(H 0 is a equality
implies a = { v3 : for f st f = v3 holds f .(Var1 H 0 ) = f .(Var2 H 0 ) })
&
0
(H is a membership
implies a = { v4 : for f st f = v4 holds f .(Var1 H 0 ) ∈ f .(Var2 H 0 ) })
[
& (H 0 is negative implies ex b st a = (VAL E) \ {b} & hthe argument of H 0 ,bi ∈ A)
&
[ [
0
(H is conjunctive implies ex b,c st a = ( {b}) ∩ {c}
& hthe left argument of H 0 ,bi ∈ A & hthe right argument of H 0 ,ci ∈ A)
& (H 0 is universal implies ex b,x st x = bound in H 0 &
a = { v5 :
for X,f st X = b & f = v5
holds f ∈ X & for g st for y st g .y 6= f .y holds x = y holds g ∈ X }
& hthe scope of H 0 ,bi ∈ A).

Let us consider H, E. Let us note that it makes sense to consider the following
functor on a restricted area. Then

St (H, E) is Subset of VAL E.

We now state a number of propositions:

(2) for x,y,f holds f .x = f .y iff f ∈ St (x - y,E),

(3) for x,y,f holds f .x ∈ f .y iff f ∈ St (x  y,E),

(4) for H,f holds not f ∈ St (H, E) iff f ∈ St (¬ H,E),

(5) for H,H 0 ,f holds f ∈ St (H, E) & f ∈ St (H 0 ,E) iff f ∈ St (H ∧ H 0 ,E),

(6) for x,H,f holds


f ∈ St (H, E) & (for g st for y st g .y 6= f .y holds x = y holds g ∈ St (H, E))
iff f ∈ St (∀ (x, H),E),

(7) H is a equality
implies for f holds f .(Var1 H) = f .(Var2 H) iff f ∈ St (H, E),
196 Grzegorz Bancerek

(8) H is a membership
implies for f holds f .(Var1 H) ∈ f .(Var2 H) iff f ∈ St (H, E),

(9) H is negative
implies for f holds not f ∈ St (the argument of H,E) iff f ∈ St (H, E),

(10) H is conjunctive implies for f holds


f ∈ St (the left argument of H,E) & f ∈ St (the right argument of H,E)
iff f ∈ St (H, E),

(11) H is universal implies for f holds


f ∈ St (the scope of H,E) & (for g
st for y st g .y 6= f .y holds bound in H = y holds g ∈ St (the scope of H,E))
iff f ∈ St (H, E).

The arguments of the notions defined below are the following: D which is an object
of the type SET DOMAIN; f which is an object of the type Function of VAR, D; H
which is an object of the type reserved above. The predicate

D, f |= H is defined by f ∈ St (H, D).

Next we state a number of propositions:

(12) for E,f,x,y holds E, f |= x - y iff f .x = f .y,

(13) for E,f,x,y holds E, f |= x  y iff f .x ∈ f .y,

(14) for E,f,H holds E, f |= H iff not E, f |= ¬ H,

(15) for E,f,H,H 0 holds E, f |= H ∧ H 0 iff E, f |= H & E, f |= H 0 ,

(16) for E,f,H,x holds


E, f |= ∀ (x, H) iff for g st for y st g .y 6= f .y holds x = y holds E, g |= H,

(17) for E,f,H,H 0 holds E, f |= H ∨ H 0 iff E, f |= H or E, f |= H 0 ,

(18) for E,f,H,H 0 holds E, f |= H ⇒ H 0 iff (E, f |= H implies E, f |= H 0 ),

(19) for E,f,H,H 0 holds E, f |= H ⇔ H 0 iff (E, f |= H iff E, f |= H 0 ),

(20) for E,f,H,x holds


E, f |= ∃ (x, H) iff ex g st (for y st g .y 6= f .y holds x = y) & E, g |= H,

(21) for E,f,x


for e being Element of E ex g st g .x = e & for z st z 6= x holds g .z = f .z,
Models and Satisfiability 197

(22) E, f |= ∀ (x, y, H)
iff for g st for z st g .z 6= f .z holds x = z or y = z holds E, g |= H,

(23) E, f |= ∃ (x, y, H)
iff ex g st (for z st g .z 6= f .z holds x = z or y = z) & E, g |= H.

Let us consider E, H. The predicate

E |= H is defined by for f holds E, f |= H.

One can prove the following propositions:

(24) E |= H iff for f holds E, f |= H,

(25) E |= ∀ (x, H) iff E |= H.

We now define five new functors. The constant the axiom of extensionality has the
type ZF-formula, and is defined by

it = ∀ (ξ 0,ξ 1,∀ (ξ 2,ξ 2  ξ 0 ⇔ ξ 2  ξ 1) ⇒ ξ 0 - ξ 1).

The constant the axiom of pairs has the type ZF-formula, and is defined by

it = ∀ (ξ 0,ξ 1,∃ (ξ 2,∀ (ξ 3,ξ 3  ξ 2 ⇔ (ξ 3 - ξ 0 ∨ ξ 3 - ξ 1)))).

The constant the axiom of unions has the type ZF-formula, and is defined by

it = ∀ (ξ 0,∃ (ξ 1,∀ (ξ 2,ξ 2  ξ 1 ⇔ ∃ (ξ 3,ξ 2  ξ 3 ∧ ξ 3  ξ 0)))).

The constant the axiom of infinity has the type ZF-formula, and is defined by

it = ∃ (ξ 0,
ξ 1, ξ 1  ξ 0 ∧ ∀ (ξ 2,ξ 2  ξ 0 ⇒ ∃ (ξ 3,ξ 3  ξ 0 ∧ ¬ ξ 3 - ξ 2 ∧ ∀ (ξ 4,ξ 4  ξ 2 ⇒ ξ 4  ξ 3)))).

The constant the axiom of power sets has the type ZF-formula, and is defined by

it = ∀ (ξ 0,∃ (ξ 1,∀ (ξ 2,ξ 2  ξ 1 ⇔ ∀ (ξ 3,ξ 3  ξ 2 ⇒ ξ 3  ξ 0)))).

Let H have the type ZF-formula. Assume that the following holds

{ξ 0,ξ 1,ξ 2} misses Free H.

The functor
the axiom of substitution for H,

with values of the type ZF-formula, is defined by

it =
∀ (ξ 3,∃ (ξ 0,∀ (ξ 4,H ⇔ ξ 4 - ξ 0))) ⇒ ∀ (ξ 1,∃ (ξ 2,∀ (ξ 4,ξ 4  ξ 2 ⇔ ∃ (ξ 3,ξ 3  ξ 1 ∧ H)))).
198 Grzegorz Bancerek

We now state several propositions:

(26) the axiom of extensionality = ∀ (ξ 0,ξ 1,∀ (ξ 2,ξ 2  ξ 0 ⇔ ξ 2  ξ 1) ⇒ ξ 0 - ξ 1),

(27) the axiom of pairs = ∀ (ξ 0,ξ 1,∃ (ξ 2,∀ (ξ 3,ξ 3  ξ 2 ⇔ (ξ 3 - ξ 0 ∨ ξ 3 - ξ 1)))),

(28) the axiom of unions


= ∀ (ξ 0,∃ (ξ 1,∀ (ξ 2,ξ 2  ξ 1 ⇔ ∃ (ξ 3,ξ 2  ξ 3 ∧ ξ 3  ξ 0)))),

(29) the axiom of infinity = ∃ (ξ 0, ξ 1, ξ 1  ξ 0 ∧ ∀ (ξ 2,


ξ 2  ξ 0 ⇒ ∃ (ξ 3, ξ 3  ξ 0 ∧ ¬ ξ 3 - ξ 2 ∧ ∀ (ξ 4,ξ 4  ξ 2 ⇒ ξ 4  ξ 3)))),

(30) the axiom of power sets


= ∀ (ξ 0,∃ (ξ 1,∀ (ξ 2,ξ 2  ξ 1 ⇔ ∀ (ξ 3,ξ 3  ξ 2 ⇒ ξ 3  ξ 0)))),

(31) {ξ 0,ξ 1,ξ 2} misses Free H implies the axiom of substitution for H =
∀ (ξ 3, ∃ (ξ 0,
∀ (ξ 4, H ⇔ ξ 4 - ξ 0))) ⇒ ∀ (ξ 1,∃ (ξ 2,∀ (ξ 4,ξ 4  ξ 2 ⇔ ∃ (ξ 3,ξ 3  ξ 1 ∧ H)))).

Let us consider E. The predicate

E is a model of ZF

is defined by

E is ∈-transitive & E |= the axiom of pairs & E |= the axiom of unions &
E |= the axiom of infinity & E |= the axiom of power sets
& for H st {ξ 0,ξ 1,ξ 2} misses Free H holds E |= the axiom of substitution for H.

The following proposition is true

(32) E is a model of ZF iff E is ∈-transitive & E |= the axiom of pairs &


E |= the axiom of unions & E |= the axiom of infinity &
E |= the axiom of power sets & for H
st {ξ 0,ξ 1,ξ 2} misses Free H holds E |= the axiom of substitution for H.

References
[1] Grzegorz Bancerek. A model of ZF set theory language. Formalized Mathematics, 1,
1990.

[2] Grzegorz Bancerek. The ordinal numbers. Formalized Mathematics, 1, 1990.


Models and Satisfiability 199

[3] Czeslaw Byliński. Functions and their basic properties. Formalized Mathematics, 1,
1990.

[4] Czeslaw Byliński. Functions from a set to a set. Formalized Mathematics, 1, 1990.

[5] Andrzej Trybulec. Enumerated sets. Formalized Mathematics, 1, 1990.

[6] Andrzej Trybulec. Tarski Grothendieck set theory. Formalized Mathematics, 1, 1990.

[7] Zinaida Trybulec and Halina Świe czkowska. Boolean properties of sets. Formalized

Mathematics, 1, 1990.

Received April 14, 1989


200
FORMALIZED MATHEMATICS
Number 1, January 1990
Université Catholique de Louvain

The Contraction Lemma

Grzegorz Bancerek1
Warsaw University
Bialystok

Summary. The article includes the proof of the contraction lemma which
claims that every class in which the axiom of extensionality is valid is isomorphic
with a transitive class. In this article the isomorphism (wrt membership relation)
of two sets is defined. It is based on [6].

The articles [7], [8], [4], [1], [5], [3], and [2] provide the terminology and notation for this
paper. For simplicity we adopt the following convention: X, Y , Z denote objects of
the type set; x, y denote objects of the type Any; E denotes an object of the type
SET DOMAIN; A, B, C denote objects of the type Ordinal; L denotes an object of
the type Transfinite-Sequence; f denotes an object of the type Function; d, d1, d0
denote objects of the type Element of E. Let us consider E, A. The functor

Mµ (E, A),

with values of the type set, is defined by


[
ex L st it = { d : for d1 st d1 ∈ d ex B st B ∈ dom L & d1 ∈ {L.B} } & dom L = A
& for B st B ∈ A
[
holds L.B = { d1 : for d st d ∈ d1 ex C st C ∈ dom (L | B) & d ∈ {L | B .C} }.

One can prove the following propositions:

(1) Mµ (E, A) = { d : for d1 st d1 ∈ d ex B st B ∈ A & d1 ∈ Mµ (E, B) },

(2) not (ex d1 st d1 ∈ d) iff d ∈ Mµ (E, 0),

(3) d ∩ E ⊆ Mµ (E, A) iff d ∈ Mµ (E, succ A),

(4) A ⊆ B implies Mµ (E, A) ⊆ Mµ (E, B),


1
Supported by RPBP.III-24.C1.
f
c 1990 Fondation Philippe le Hodey
201 ISSN 0777-4028
202 Grzegorz Bancerek

(5) ex A st d ∈ Mµ (E, A),

(6) d0 ∈ d & d ∈ Mµ (E, A)


implies d0 ∈ Mµ (E, A) & ex B st B ∈ A & d0 ∈ Mµ (E, B),

(7) Mµ (E, A) ⊆ E,

(8) ex A st E = Mµ (E, A),

(9) ex f st dom f = E & for d holds f .d = f ◦ d.

Let us consider f , X, Y . The predicate

f is ∈-isomorphism of X, Y

is defined by

dom f = X & rng f = Y & f is one-to-one & for x,y


st x ∈ X & y ∈ X holds (ex Z st Z = y & x ∈ Z) iff ex Z st f .y = Z & f .x ∈ Z.

Next we state a proposition

(10) f is ∈-isomorphism of X, Y iff dom f = X & rng f = Y & f is one-to-one &


for x,y st x ∈ X & y ∈ X
holds (ex Z st Z = y & x ∈ Z) iff ex Z st f .y = Z & f .x ∈ Z.

Let us consider X, Y . The predicate

X, Y are ∈-isomorphic is defined by ex f st f is ∈-isomorphism of X, Y.

Next we state two propositions:

(11) X, Y are ∈-isomorphic iff ex f st f is ∈-isomorphism of X, Y,

(12) dom f = E & (for d holds f .d = f ◦ d) implies rng f is ∈-transitive .

In the sequel u, v, w will denote objects of the type Element of E. Next we state
two propositions:

(13) E |= the axiom of extensionality


implies for u,v st for w holds w ∈ u iff w ∈ v holds u = v,

(14) E |= the axiom of extensionality


implies ex X st X is ∈-transitive & E, X are ∈-isomorphic .
The Contraction Lemma 203

References
[1] Grzegorz Bancerek. A model of ZF set theory language. Formalized Mathematics, 1,
1990.

[2] Grzegorz Bancerek. Models and satisfiability. Formalized Mathematics, 1, 1990.

[3] Grzegorz Bancerek. The ordinal numbers. Formalized Mathematics, 1, 1990.

[4] Czeslaw Byliński. Functions and their basic properties. Formalized Mathematics, 1,
1990.

[5] Czeslaw Byliński. Functions from a set to a set. Formalized Mathematics, 1, 1990.

[6] Andrzej Mostowski. Constructible Sets. North Holland, 1970.

[7] Andrzej Trybulec. Tarski Grothendieck set theory. Formalized Mathematics, 1, 1990.

[8] Zinaida Trybulec and Halina Świe czkowska. Boolean properties of sets. Formalized

Mathematics, 1, 1990.

Received April 14, 1989


204
FORMALIZED MATHEMATICS
Number 1, January 1990
Université Catholique de Louvain

Axioms of Incidence

Wojciech A. Trybulec1
Warsaw University

Summary. This article is based on “Foundations of Geometry” by Karol


Borsuk and Wanda Szmielew ([1]). The fourth axiom of incidence is weakened.
In [1] it has the form for any plane there exist three non-collinear points in the
plane and in the article for any plane there exists one point in the plane. The
original axiom is proved. The article includes: theorems concerning collinearity
of points and coplanarity of points and lines, basic theorems concerning lines and
planes, fundamental existence theorems, theorems concerning intersection of lines
and planes.

The articles [3], [2], and [4] provide the terminology and notation for this paper. We
consider structures IncStruct, which are systems

hhPoints , Lines , Planes , Inc1 , Inc2 , Inc3 ii

where Points, Lines, Planes have the type DOMAIN, Inc1 has the type Relation of
the Points, the Lines, Inc2 has the type Relation of the Points, the Planes, and Inc3
has the type Relation of the Lines, the Planes. We now define three new modes. Let
S have the type IncStruct.

POINT of S stands for Element of the Points of S.

LINE of S stands for Element of the Lines of S.

PLANE of S stands for Element of the Planes of S.

In the sequel S will have the type IncStruct; A will have the type Element of
the Points of S; L will have the type Element of the Lines of S; P will have the type
Element of the Planes of S. The following propositions are true:

(1) A is POINT of S,

(2) L is LINE of S,
1
Supported by RPBP.III-24.C1.
f
c 1990 Fondation Philippe le Hodey
205 ISSN 0777-4028
206 Wojciech A. Trybulec

(3) P is PLANE of S.

For simplicity we adopt the following convention: A, B, C, D will denote objects of


the type POINT of S; L will denote an object of the type LINE of S; P will denote
an object of the type PLANE of S; F , G will denote objects of the type Subset of
the Points of S. The arguments of the notions defined below are the following: S which
is an object of the type reserved above; A which is an object of the type POINT of S;
L which is an object of the type LINE of S. The predicate

A on L is defined by hA, Li ∈ the Inc1 of S.

The arguments of the notions defined below are the following: S which is an object
of the type reserved above; A which is an object of the type POINT of S; P which is
an object of the type PLANE of S. The predicate

A on P is defined by hA, P i ∈ the Inc2 of S.

The arguments of the notions defined below are the following: S which is an object
of the type reserved above; L which is an object of the type LINE of S; P which is an
object of the type PLANE of S. The predicate

L on P is defined by hL, P i ∈ the Inc3 of S.

The arguments of the notions defined below are the following: S which is an object
of the type reserved above; F which is an object of the type set of POINT of S; L
which is an object of the type LINE of S. The predicate

F on L is defined by for A being POINT of S st A ∈ F holds A on L.

The arguments of the notions defined below are the following: S which is an object
of the type reserved above; F which is an object of the type set of POINT of S; P
which is an object of the type PLANE of S. The predicate

F on P is defined by for A st A ∈ F holds A on P.

The arguments of the notions defined below are the following: S which is an object
of the type reserved above; F which is an object of the type set of POINT of S. The
predicate
F is linear is defined by ex L st F on L.

The arguments of the notions defined below are the following: S which is an object
of the type reserved above; F which is an object of the type set of POINT of S. The
predicate
F is planar is defined by ex P st F on P.

Next we state a number of propositions:

(4) A on L iff hA, Li ∈ the Inc1 of S,


Axioms of Incidence 207

(5) A on P iff hA, P i ∈ the Inc2 of S,

(6) L on P iff hL, P i ∈ the Inc3 of S,

(7) F on L iff for A st A ∈ F holds A on L,

(8) F on P iff for A st A ∈ F holds A on P,

(9) F is linear iff ex L st F on L,

(10) F is planar iff ex P st F on P,

(11) {A, B} on L iff A on L & B on L,

(12) {A, B, C} on L iff A on L & B on L & C on L,

(13) {A, B} on P iff A on P & B on P,

(14) {A, B, C} on P iff A on P & B on P & C on P,

(15) {A, B, C, D} on P iff A on P & B on P & C on P & D on P,

(16) G ⊆ F & F on L implies G on L,

(17) G ⊆ F & F on P implies G on P,

(18) F on L & A on L iff F ∪ {A} on L,

(19) F on P & A on P iff F ∪ {A} on P,

(20) F ∪ G on L iff F on L & G on L,

(21) F ∪ G on P iff F on P & G on P,

(22) G ⊆ F & F is linear implies G is linear ,

(23) G ⊆ F & F is planar implies G is planar .

The mode
IncSpace ,

which widens to the type IncStruct, is defined by

(for L being LINE of it ex A,B being POINT of it st A 6= B & {A, B} on L) &


(for A,B being POINT of it ex L being LINE of it st {A, B} on L) &
(for A,B being POINT of it, K,L being LINE of it
st A 6= B & {A, B} on K & {A, B} on L holds K = L)
& (for P being PLANE of it ex A being POINT of it st A on P ) &
208 Wojciech A. Trybulec

(for A,B,C being POINT of it ex P being PLANE of it st {A, B, C} on P ) &


(for A,B,C being POINT of it, P,Q being PLANE of it
st not {A, B, C} is linear & {A, B, C} on P & {A, B, C} on Q holds P = Q)
&
(for L being LINE of it, P being PLANE of it
st ex A,B being POINT of it st A 6= B & {A, B} on L & {A, B} on P holds L on P )
&
(for A being POINT of it, P,Q being PLANE of it
st A on P & A on Q ex B being POINT of it st A 6= B & B on P & B on Q)
& (ex A,B,C,D being POINT of it st not {A, B, C, D} is planar) &
for A being POINT of it, L being LINE of it, P being PLANE of it
st A on L & L on P holds A on P.

The following proposition is true

(24) (for L being LINE of S ex A,B being POINT of S st A 6= B & {A, B} on L)


& (for A,B being POINT of S ex L being LINE of S st {A, B} on L) &
(for A,B being POINT of S, K,L being LINE of S
st A 6= B & {A, B} on K & {A, B} on L holds K = L)
& (for P being PLANE of S ex A being POINT of S st A on P ) &
(for A,B,C being POINT of S ex P being PLANE of S st {A, B, C} on P )
&
(for A,B,C being POINT of S, P,Q being PLANE of S
st not {A, B, C} is linear & {A, B, C} on P & {A, B, C} on Q holds P = Q)
&
(for L being LINE of S, P being PLANE of S st
ex A,B being POINT of S st A 6= B & {A, B} on L & {A, B} on P
holds L on P )
&
(for A being POINT of S, P,Q being PLANE of S
st A on P & A on Q ex B being POINT of S st A 6= B & B on P & B on Q)
& (ex A,B,C,D being POINT of S st not {A, B, C, D} is planar) & (
for A being POINT of S, L being LINE of S, P being PLANE of S
st A on L & L on P holds A on P )
implies S is IncSpace .
Axioms of Incidence 209

For simplicity we adopt the following convention: S will denote an object of the type
IncSpace; A, B, C, D will denote objects of the type POINT of S; K, L, L1, L2 will
denote objects of the type LINE of S; P , Q will denote objects of the type PLANE
of S; F will denote an object of the type Subset of the Points of S. The following
propositions are true:

(25) ex A,B st A 6= B & {A, B} on L,

(26) ex L st {A, B} on L,

(27) A 6= B & {A, B} on K & {A, B} on L implies K = L,

(28) ex A st A on P,

(29) ex P st {A, B, C} on P,

(30) not {A, B, C} is linear & {A, B, C} on P & {A, B, C} on Q implies P = Q,

(31) (ex A,B st A 6= B & {A, B} on L & {A, B} on P ) implies L on P,

(32) A on P & A on Q implies ex B st A 6= B & B on P & B on Q,

(33) ex A,B,C,D st not {A, B, C, D} is planar ,

(34) A on L & L on P implies A on P,

(35) F on L & L on P implies F on P,

(36) {A, A, B} is linear ,

(37) {A, A, B, C} is planar ,

(38) {A, B, C} is linear implies {A, B, C, D} is planar ,

(39) A 6= B & {A, B} on L & not C on L implies not {A, B, C} is linear ,

(40) not {A, B, C} is linear & {A, B, C} on P & not D on P


implies not {A, B, C, D} is planar ,

(41) not (ex P st K on P & L on P ) implies K 6= L,

(42) not (ex P st L on P & L1 on P & L2 on P )


& (ex A st A on L & A on L1 & A on L2)
implies L 6= L1,

(43) L1 on P & L2 on P & not L on P & L1 6= L2


implies not ex Q st L on Q & L1 on Q & L2 on Q,
210 Wojciech A. Trybulec

(44) ex P st A on P & L on P,

(45) (ex A st A on K & A on L) implies ex P st K on P & L on P,

(46) A 6= B implies ex L st for K holds {A, B} on K iff K = L,

(47) not {A, B, C} is linear


implies ex P st for Q holds {A, B, C} on Q iff P = Q,

(48) not A on L implies ex P st for Q holds A on Q & L on Q iff P = Q,

(49) K 6= L & (ex A st A on K & A on L)


implies ex P st for Q holds K on Q & L on Q iff P = Q.

Let us consider S, A, B. Assume that the following holds

A 6= B.

The functor
Line (A, B),

with values of the type LINE of S, is defined by

{A, B} on it .

Let us consider S, A, B, C. Assume that the following holds

not {A, B, C} is linear .

The functor
Plane (A, B, C),

yields the type PLANE of S and is defined by

{A, B, C} on it .

Let us consider S, A, L. Assume that the following holds

not A on L.

The functor
Plane (A, L),

with values of the type PLANE of S, is defined by

A on it & L on it .

Let us consider S, K, L. Assume that the following holds

K 6= L.
Axioms of Incidence 211

Moreover we assume that

ex A st A on K & A on L.

The functor
Plane (K, L),

with values of the type PLANE of S, is defined by

K on it & L on it .

Next we state a number of propositions:

(50) A 6= B implies {A, B} on Line (A, B),

(51) A 6= B & {A, B} on K implies K = Line (A, B),

(52) not {A, B, C} is linear implies {A, B, C} on Plane (A, B, C),

(53) not {A, B, C} is linear & {A, B, C} on Q implies Q = Plane (A, B, C),

(54) not A on L implies A on Plane (A, L) & L on Plane (A, L),

(55) not A on L & A on Q & L on Q implies Q = Plane (A, L),

(56) K 6= L & (ex A st A on K & A on L)


implies K on Plane (K, L) & L on Plane (K, L),

(57) A 6= B implies Line (A, B) = Line (B, A),

(58) not {A, B, C} is linear implies Plane (A, B, C) = Plane (A, C, B),

(59) not {A, B, C} is linear implies Plane (A, B, C) = Plane (B, A, C),

(60) not {A, B, C} is linear implies Plane (A, B, C) = Plane (B, C, A),

(61) not {A, B, C} is linear implies Plane (A, B, C) = Plane (C, A, B),

(62) not {A, B, C} is linear implies Plane (A, B, C) = Plane (C, B, A),

(63) K 6= L & (ex A st A on K & A on L) & K on Q & L on Q


implies Q = Plane (K, L),

(64) K 6= L & (ex A st A on K & A on L) implies Plane (K, L) = Plane (L, K),

(65) A 6= B & C on Line (A, B) implies {A, B, C} is linear ,

(66) A 6= B & A 6= C & {A, B, C} is linear implies Line (A, B) = Line (A, C),

(67) not {A, B, C} is linear implies Plane (A, B, C) = Plane (C, Line (A, B)),
212 Wojciech A. Trybulec

(68) not {A, B, C} is linear & D on Plane (A, B, C)


implies {A, B, C, D} is planar ,

(69) not C on L & {A, B} on L & A 6= B implies Plane (C, L) = Plane (A, B, C),

(70) not {A, B, C} is linear


implies Plane (A, B, C) = Plane (Line (A, B),Line (A, C)),

(71) ex A,B,C st {A, B, C} on P & not {A, B, C} is linear ,

(72) ex A,B,C,D st A on P & not {A, B, C, D} is planar ,

(73) ex B st A 6= B & B on L,

(74) A 6= B implies ex C st C on P & not {A, B, C} is linear ,

(75) not {A, B, C} is linear implies ex D st not {A, B, C, D} is planar ,

(76) ex B,C st {B, C} on P & not {A, B, C} is linear ,

(77) A 6= B implies ex C,D st not {A, B, C, D} is planar ,

(78) ex B,C,D st not {A, B, C, D} is planar ,

(79) ex L st not A on L & L on P,

(80) A on P implies ex L,L1,L2 st L1 6= L2


& L1 on P & L2 on P & not L on P & A on L & A on L1 & A on L2,

(81) ex L,L1,L2
st A on L & A on L1 & A on L2 & not ex P st L on P & L1 on P & L2 on P,

(82) ex P st A on P & not L on P,

(83) ex A st A on P & not A on L,

(84) ex K st not ex P st L on P & K on P,

(85) ex P,Q st P 6= Q & L on P & L on Q,

(86) K 6= L & {A, B} on K & {A, B} on L implies A = B,

(87) not L on P & {A, B} on L & {A, B} on P implies A = B,

(88) P 6= Q implies not (ex A st A on P & A on Q)


or ex L st for B holds B on P & B on Q iff B on L.
Axioms of Incidence 213

References
[1] Karol Borsuk and Wanda Szmielew. Foundations of Geometry. North Holland, 1960.

[2] Andrzej Trybulec. Domains and their Cartesian products. Formalized Mathematics,
1, 1990.

[3] Andrzej Trybulec. Tarski Grothendieck set theory. Formalized Mathematics, 1, 1990.

[4] Edmund Woronowicz. Relations defined on sets. Formalized Mathematics, 1, 1990.

Received April 14, 1989


214
FORMALIZED MATHEMATICS
Number 1, January 1990
Université Catholique de Louvain

Introduction to Lattice Theory

Stanislaw Żukowski1
Warsaw University
Bialystok

Summary. A lattice is defined as an algebra on a nonempty set with binary


operations join and meet which are commutative and associative, and satisfy the
absorption identities. The following kinds of lattices are considered: distributive,
modular, bounded (with zero and unit elements), complemented, and Boolean (with
complement). The article includes also theorems which immediately follow from
definitions.

The terminology and notation used in this paper are introduced in the papers [1] and
[2]. The scheme BooleDomBinOpLam deals with a constant A that has the type
BOOLE DOMAIN and a binary functor F yielding values of the type Element of A
and states that the following holds

ex o being Binary Operation of A


st for a,b being Element of A holds o.(a, b) = F(a, b)

for all values of the parameters.


We consider structures LattStr, which are systems

hhcarrier , join , meetii

where carrier has the type DOMAIN, and join, meet have the type Binary Operation
of the carrier. In the sequel G has the type LattStr; p, q, r have the type Element
of the carrier of G. We now define two new functors. Let us consider G, p, q. The
functor
p t q,

yields the type Element of the carrier of G and is defined by

it = (the join of G).(p, q).


1
Supported by RPBP.III-24.C1.

cf 1990 Fondation Philippe le Hodey


215 ISSN 0777-4028
216 Stanislaw Żukowski

The functor
p u q,

with values of the type Element of the carrier of G, is defined by

it = (the meet of G).(p, q).

The following propositions are true:

(1) p t q = (the join of G).(p, q),

(2) p u q = (the meet of G).(p, q).

Let us consider G, p, q. The predicate

pvq is defined by p t q = q.

We now state a proposition

(3) p v q iff p t q = q.

The mode
Lattice ,

which widens to the type LattStr, is defined by

(for a,b being Element of the carrier of it holds a t b = b t a) &


(for a,b,c being Element of the carrier of it holds a t (b t c) = (a t b) t c) &
(for a,b being Element of the carrier of it holds (a u b) t b = b) &
(for a,b being Element of the carrier of it holds a u b = b u a) &
(for a,b,c being Element of the carrier of it holds a u (b u c) = (a u b) u c)
& for a,b being Element of the carrier of it holds a u (a t b) = a.

One can prove the following proposition

(4) (for p,q holds p t q = q t p) & (for p,q,r holds p t (q t r) = (p t q) t r) &


(for p,q holds (p u q) t q = q) & (for p,q holds p u q = q u p)
& (for p,q,r holds p u (q u r) = (p u q) u r) & (for p,q holds p u (p t q) = p)
implies G is Lattice .

In the sequel L has the type Lattice; a, b, c have the type Element of the carrier of L.
One can prove the following propositions:

(5) a t b = b t a,

(6) a u b = b u a,

(7) a t (b t c) = (a t b) t c,
Introduction to Lattice Theory 217

(8) a u (b u c) = (a u b) u c,

(9) (a u b) t b = b & b t (a u b) = b & b t (b u a) = b & (b u a) t b = b,

(10) a u (a t b) = a & (a t b) u a = a & (b t a) u a = a & a u (b t a) = a.

The mode
Distributive Lattice ,

which widens to the type Lattice, is defined by

for a,b,c being Element of the carrier of it holds a u (b t c) = (a u b) t (a u c).

Next we state a proposition

(11) (for a,b,c holds a u (b t c) = (a u b) t (a u c))


implies L is Distributive Lattice .

The mode
Modular Lattice ,

which widens to the type Lattice, is defined by

for a,b,c being Element of the carrier of it st a v c holds a t (b u c) = (a t b) u c.

One can prove the following proposition

(12) (for a,b,c st a v c holds a t (b u c) = (a t b) u c)


implies L is Modular Lattice .

The mode
Lower Bound Lattice ,

which widens to the type Lattice, is defined by

ex c being Element of the carrier of it


st for a being Element of the carrier of it holds c u a = c.

Next we state a proposition

(13) (ex c st for a holds c u a = c) implies L is Lower Bound Lattice .

The mode
Upper Bound Lattice ,

which widens to the type Lattice, is defined by

ex c being Element of the carrier of it


st for a being Element of the carrier of it holds c t a = c.
218 Stanislaw Żukowski

One can prove the following proposition

(14) (ex c st for a holds c t a = c) implies L is Upper Bound Lattice .

The mode
Bound Lattice ,

which widens to the type Lattice, is defined by

it is Lower Bound Lattice & it is Upper Bound Lattice .

Next we state a proposition

(15) L is Lower Bound Lattice & L is Upper Bound Lattice


implies L is Bound Lattice .

Let us consider L. Assume that the following holds

ex c st for a holds c u a = c.

The functor
⊥ L,

yields the type Element of the carrier of L and is defined by

it u a = it .

Let L have the type Lower Bound Lattice. Let us note that it makes sense to consider
the following functor on a restricted area. Then

⊥L is Element of the carrier of L.

Let us consider L. Assume that the following holds

ex c st for a holds c t a = c.

The functor
> L,

with values of the type Element of the carrier of L, is defined by

it t a = it .

Let L have the type Upper Bound Lattice. Let us note that it makes sense to consider
the following functor on a restricted area. Then

>L is Element of the carrier of L.

Let L have the type Bound Lattice. Let us note that it makes sense to consider the
following functors on restricted areas. Then

⊥L is Element of the carrier of L,


Introduction to Lattice Theory 219

>L is Element of the carrier of L.

Let us consider L, a, b. Assume that the following holds

L is Bound Lattice .

The predicate

a is a complement of b is defined by a t b = > L & a u b = ⊥ L.

The mode
Lattice with Complement ,

which widens to the type Bound Lattice, is defined by

for b being Element of the carrier of it


ex a being Element of the carrier of it st a is a complement of b.

The mode
Boolean Lattice ,
which widens to the type Lattice with Complement, is defined by

it is Distributive Lattice .

The following propositions are true:

(16) a t b = b iff a u b = a,

(17) a t a = a,

(18) a u a = a,

(19) for L holds (for a,b,c holds a u (b t c) = (a u b) t (a u c))


iff for a,b,c holds a t (b u c) = (a t b) u (a t c),

(20) a v b iff a t b = b,

(21) a v b iff a u b = a,

(22) a v a t b,

(23) a u b v a,

(24) a v a,

(25) a v b & b v c implies a v c,

(26) a v b & b v a implies a = b,

(27) a v b implies a u c v b u c,
220 Stanislaw Żukowski

(28) a v b implies c u a v c u b,

(29) (for a,b,c holds (a u b) t (b u c) t (c u a) = (a t b) u (b t c) u (c t a))


implies L is Distributive Lattice .

In the sequel L denotes an object of the type Distributive Lattice; a, b, c de-


note objects of the type Element of the carrier of L. One can prove the following
propositions:

(30) for L holds (for a,b,c holds a u (b t c) = (a u b) t (a u c))


& for a,b,c holds (b t c) u a = (b u a) t (c u a),

(31) for L holds (for a,b,c holds a t (b u c) = (a t b) u (a t c))


& for a,b,c holds (b u c) t a = (b t a) u (c t a),

(32) c u a = c u b & c t a = c t b implies a = b,

(33) a u c = b u c & a t c = b t c implies a = b,

(34) (a t b) u (b t c) u (c t a) = (a u b) t (b u c) t (c u a),

(35) L is Modular Lattice .

In the sequel L has the type Modular Lattice; a, b, c have the type Element of
the carrier of L. One can prove the following two propositions:

(36) a v c implies a t (b u c) = (a t b) u c,

(37) c v a implies a u (b t c) = (a u b) t c.

In the sequel L has the type Lower Bound Lattice; a, c have the type Element of
the carrier of L. We now state four propositions:

(38) ex c st for a holds c u a = c,

(39) ⊥ L t a = a & a t ⊥ L = a,

(40) ⊥ L u a = ⊥ L & a u ⊥ L = ⊥ L,

(41) ⊥ L v a.

In the sequel L denotes an object of the type Upper Bound Lattice; a, c denote
objects of the type Element of the carrier of L. The following four propositions are
true:

(42) ex c st for a holds c t a = c,

(43) > L u a = a & a u > L = a,


Introduction to Lattice Theory 221

(44) > L t a = > L & a t > L = > L,

(45) a v > L.

In the sequel L has the type Lattice with Complement; a, b have the type Element
of the carrier of L. One can prove the following proposition

(46) ex a st a is a complement of b.

In the sequel L has the type Lattice. The arguments of the notions defined below
are the following: L which is an object of the type reserved above; x which is an object
of the type Element of the carrier of L. Assume that the following holds

L is Boolean Lattice .

The functor
xc ,

yields the type Element of the carrier of L and is defined by

it is a complement of x.

The arguments of the notions defined below are the following: L which is an object of
the type Boolean Lattice; x which is an object of the type Element of the carrier of L.
Let us note that it makes sense to consider the following functor on a restricted area.
Then
xc is Element of the carrier of L.

In the sequel L will denote an object of the type Boolean Lattice; a, b will denote
objects of the type Element of the carrier of L. We now state several propositions:

(47) a c u a = ⊥ L & a u a c = ⊥ L,

(48) a c t a = > L & a t a c = > L,

(49) a c c = a,

(50) (a u b) c = a c t b c ,

(51) (a t b) c = a c u b c ,

(52) b u a = ⊥ L iff b v a c ,

(53) a v b implies b c v a c .

In the sequel L will have the type Bound Lattice; a, b will have the type Element
of the carrier of L. We now state three propositions:

(54) L is Lower Bound Lattice & L is Upper Bound Lattice ,


222 Stanislaw Żukowski

(55) a is a complement of b iff a t b = > L & a u b = ⊥ L,

(56) (for b ex a st a is a complement of b) implies L is Lattice with Complement .

In the sequel L has the type Lattice with Complement. One can prove the
following proposition

(57) L is Distributive Lattice implies L is Boolean Lattice .

In the sequel L has the type Boolean Lattice. The following two propositions are
true:

(58) L is Lattice with Complement ,

(59) L is Distributive Lattice .

References
[1] Czeslaw Byliński. Binary operations. Formalized Mathematics, 1, 1990.

[2] Andrzej Trybulec and Agata Darmochwal. Boolean domains. Formalized Mathemat-
ics, 1, 1990.

Received April 14, 1989


FORMALIZED MATHEMATICS
Number 1, January 1990
Université Catholique de Louvain

Topological Spaces and Continuous


Functions

Beata Padlewska1 Agata Darmochwal2


Warsaw University Warsaw University
Bialystok Bialystok

Summary. The paper contains a definition of topological space. The following


notions are defined: point of topological space, subset of topological space, subspace
of topological space, and continuous function.

The articles [5], [7], [6], [1], [4], [2], and [3] provide the terminology and notation for this
paper. We consider structures TopStruct, which are systems

hhcarrier , topologyii

where carrier has the type DOMAIN, and topology has the type Subset-Family of
the carrier. In the sequel T has the type TopStruct. The mode

TopSpace ,

which widens to the type TopStruct, is defined by

the carrier of it ∈ the topology of it &


(for a being Subset-Family of the carrier of it
[
st a ⊆ the topology of it holds a ∈ the topology of it)
& for a,b being Subset of the carrier of it
st a ∈ the topology of it & b ∈ the topology of it holds a ∩ b ∈ the topology of it .

We now state a proposition

(1) the carrier of T ∈ the topology of T &


(for a being Subset-Family of the carrier of T
1
Supported by RPBP.III-24.C1.
2
Supported by RPBP.III-24.C1.
f
c 1990 Fondation Philippe le Hodey
223 ISSN 0777-4028
224 Beata Padlewska and Agata Darmochwal

[
st a ⊆ the topology of T holds a ∈ the topology of T )
& (for p,q being Subset of the carrier of T st
p ∈ the topology of T & q ∈ the topology of T
holds p ∩ q ∈ the topology of T )
implies T is TopSpace .

In the sequel T , S, GX will have the type TopSpace. Let us consider T .

Point of T stands for Element of the carrier of T.

The following proposition is true

(2) for x being Element of the carrier of T holds x is Point of T.

Let us consider T .

Subset of T stands for set of Point of T.

We now state a proposition

(3) for P being Subset of the carrier of T holds P is Subset of T.

In the sequel P , Q will have the type Subset of T ; p will have the type Point of
T . Let us consider T .

Subset-Family of T stands for Subset-Family of the carrier of T.

Next we state a proposition

(4) for F being Subset-Family of the carrier of T


holds F is Subset-Family of T.

In the sequel F will denote an object of the type Subset-Family of T . The scheme
SubFamEx1 concerns a constant A that has the type TopSpace and a unary predicate
P and states that the following holds

ex F being Subset-Family of A st for B being Subset of A holds B ∈ F iff P[B]

for all values of the parameters.


One can prove the following propositions:

(5) ∅ ∈ the topology of T,

(6) the carrier of T ∈ the topology of T,

(7) for a being Subset-Family of T


[
st a ⊆ the topology of T holds a ∈ the topology of T,
Topological Spaces and Continuous . . . 225

(8) P ∈ the topology of T & Q ∈ the topology of T


implies P ∩ Q ∈ the topology of T.

We now define two new functors. Let us consider T . The functor

∅T,

with values of the type Subset of T , is defined by

it = ∅ the carrier of T.

The functor
Ω T,

with values of the type Subset of T , is defined by

it = Ω the carrier of T.

One can prove the following four propositions:

(9) ∅T = ∅ the carrier of T,

(10) Ω T = Ω the carrier of T,

(11) ∅(T ) = ∅,

(12) Ω (T ) = the carrier of T.

Let us consider T , P . The functor

P c,

yields the type Subset of T and is defined by

it = P c .

Let us consider T , P , Q. Let us note that it makes sense to consider the following
functors on restricted areas. Then

P ∪Q is Subset of T,

P ∩Q is Subset of T,

P \Q is Subset of T,
. Q
P− is Subset of T.

The following propositions are true:

(13) p ∈ Ω (T ),

(14) P ⊆ Ω (T ),
226 Beata Padlewska and Agata Darmochwal

(15) P ∩ Ω (T ) = P,

(16) for A being set holds A ⊆ Ω (T ) implies A is Subset of T,

(17) P c = Ω (T ) \ P,

(18) P ∪ P c = Ω (T ),

(19) P ⊆ Q iff Q c ⊆ P c ,

cc
(20) P =P ,

(21) P ⊆ Q c iff P ∩ Q = ∅,

(22) Ω (T ) \ (Ω (T ) \ P ) = P,

(23) P 6= Ω (T ) iff Ω (T ) \ P 6= ∅,

(24) Ω (T ) \ P = Q implies Ω (T ) = P ∪ Q,

(25) Ω (T ) = P ∪ Q & P ∩ Q = ∅ implies Q = Ω (T ) \ P,

(26) P ∩ P c = ∅(T ),

(27) Ω (T ) = (∅T ) c ,

(28) P \Q = P ∩Qc,

(29) P = Q implies Ω (T ) \ P = Ω (T ) \ Q.

Let us consider T , P . The predicate

P is open is defined by P ∈ the topology of T.

One can prove the following proposition

(30) P is open iff P ∈ the topology of T.

Let us consider T , P . The predicate

P is closed is defined by Ω (T ) \ P is open .

One can prove the following proposition

(31) P is closed iff Ω (T ) \ P is open .

Let us consider T , P . The predicate

P is open closed is defined by P is open & P is closed .


Topological Spaces and Continuous . . . 227

We now state a proposition

(32) P is open closed iff P is open & P is closed .

Let us consider T , F . Let us note that it makes sense to consider the following functor
on a restricted area. Then
[
F is Subset of T.

Let us consider T , F . Let us note that it makes sense to consider the following functor
on a restricted area. Then
\
F is Subset of T.

Let us consider T , F . The predicate


[
F is a cover of T is defined by Ω (T ) = F.

The following proposition is true


[
(33) F is a cover of T iff Ω (T ) = F.

Let us consider T . The mode

SubSpace of T,

which widens to the type TopSpace, is defined by

Ω (it) ⊆ Ω (T ) & for P being Subset of it holds P ∈ the topology of it


iff ex Q being Subset of T st Q ∈ the topology of T & P = Q ∩ Ω (it).

Next we state two propositions:

(34) Ω (S) ⊆ Ω (T ) & (for P being Subset of S holds P ∈ the topology of S


iff ex Q being Subset of T st Q ∈ the topology of T & P = Q ∩ Ω (S))
implies S is SubSpace of T,

(35) for V being SubSpace of T holds Ω (V ) ⊆ Ω (T ) & for P being Subset of V


holds P ∈ the topology of V
iff ex Q being Subset of T st Q ∈ the topology of T & P = Q ∩ Ω (V ).

Let us consider T , P . Assume that the following holds

P 6= ∅(T ).

The functor
T | P,
with values of the type SubSpace of T , is defined by

Ω (it) = P.
228 Beata Padlewska and Agata Darmochwal

One can prove the following proposition

(36) P 6= ∅(T ) implies for S being SubSpace of T holds S = T | P iff Ω (S) = P.

Let us consider T , S.

map of T, S stands for Function of (the carrier of T ),(the carrier of S).

Next we state a proposition

(37) for f being Function of the carrier of T,the carrier of S


holds f is map of T, S.

In the sequel f has the type map of T , S; P 1 has the type Subset of S. Let us
consider T , S, f , P . Let us note that it makes sense to consider the following functor on
a restricted area. Then
f◦P is Subset of S.
Let us consider T , S, f , P 1. Let us note that it makes sense to consider the following
functor on a restricted area. Then

f -1 P 1 is Subset of T.

Let us consider T , S, f . The predicate

f is continuous

is defined by

for P 1 holds P 1 is closed implies f -1 P 1 is closed .

The following proposition is true

(38) f is continuous iff for P 1 holds P 1 is closed implies f -1 P 1 is closed .

The scheme TopAbstr concerns a constant A that has the type TopSpace and a unary
predicate P and states that the following holds

ex P being Subset of A st for x being Point of A holds x ∈ P iff P[x]

for all values of the parameters.


One can prove the following propositions:

(39) for X 0 being SubSpace of GX


for A being Subset of X 0 holds A is Subset of GX,

(40) for A being Subset of GX, x being Any st x ∈ A holds x is Point of GX,

(41) for A being Subset of GX st A 6= ∅(GX) ex x being Point of GX st x ∈ A,

(42) Ω (GX) is closed ,


Topological Spaces and Continuous . . . 229

(43) for X 0 being SubSpace of GX, B being Subset of X 0 holds


B is closed iff ex C being Subset of GX st C is closed & C ∩ (Ω (X 0 )) = B,

(44) for F being Subset-Family of GX st


F 6= ∅ & for A being Subset of GX st A ∈ F holds A is closed
\
holds F is closed .

The arguments of the notions defined below are the following: GX which is an object
of the type TopSpace; A which is an object of the type Subset of GX. The functor

Cl A,

yields the type Subset of GX and is defined by

for p being Point of GX holds p ∈ it


iff for G being Subset of GX st G is open holds p ∈ G implies A ∩ G 6= ∅(GX).

We now state a number of propositions:

(45) for A being Subset of GX, p being Point of GX holds p ∈ Cl A


iff for C being Subset of GX st C is closed holds A ⊆ C implies p ∈ C,

(46) for A being Subset of GX ex F being Subset-Family of GX st


(for C being Subset of GX holds C ∈ F iff C is closed & A ⊆ C)
\
& Cl A = F,

(47) for
X being SubSpace of GX, A being Subset of GX, A1 being Subset of X 0
0

st A = A1 holds Cl A1 = (Cl A) ∩ (Ω (X 0 )),

(48) for A being Subset of GX holds A ⊆ Cl A,

(49) for A,B being Subset of GX st A ⊆ B holds Cl A ⊆ Cl B,

(50) for A,B being Subset of GX holds Cl (A ∪ B) = Cl A ∪ Cl B,

(51) for A,B being Subset of GX holds Cl (A ∩ B) ⊆ (Cl A) ∩ Cl B,

(52) for A being Subset of GX holds A is closed iff Cl A = A,

(53) for A being Subset of GX


holds A is open iff Cl (Ω (GX) \ A) = Ω (GX) \ A,

(54) for A being Subset of GX, p being Point of GX holds p ∈ Cl A iff


for G being Subset of GX
st G is open holds p ∈ G implies A ∩ G 6= ∅(GX).
230 Beata Padlewska and Agata Darmochwal

References
[1] Czeslaw Byliński. Functions and their basic properties. Formalized Mathematics, 1,
1990.

[2] Czeslaw Byliński. Functions from a set to a set. Formalized Mathematics, 1, 1990.

[3] Beata Padlewska. Families of sets. Formalized Mathematics, 1, 1990.

[4] Andrzej Trybulec. Domains and their Cartesian products. Formalized Mathematics,
1, 1990.

[5] Andrzej Trybulec. Tarski Grothendieck set theory. Formalized Mathematics, 1, 1990.

[6] Zinaida Trybulec. Properties of subsets. Formalized Mathematics, 1, 1990.

[7] Zinaida Trybulec and Halina Świe czkowska. Boolean properties of sets. Formalized

Mathematics, 1, 1990.

Received April 14, 1989


FORMALIZED MATHEMATICS
Number 1, January 1990
Université Catholique de Louvain

Subsets of Topological Spaces

Miroslaw Wysocki Agata Darmochwal1


Warsaw Uniwersity Warsaw University
Bialystok Bialystok

Summary. The article contains some theorems about open and closed sets.
The following topological operations on sets are defined: closure, interior and fron-
tier. The following notions are introduced: dense set, boundary set, nowheredense
set and set being domain (closed domain and open domain), and some basic facts
concerning them are proved.

The papers [4], [5], [3], [1], and [2] provide the notation and terminology for this paper.
For simplicity we adopt the following convention: T S denotes an object of the type
TopSpace; x denotes an object of the type Any; P , Q, G denote objects of the type
Subset of T S; p denotes an object of the type Point of T S. One can prove the
following propositions:

(1) x ∈ P implies x is Point of T S,

(2) P ∪ Ω T S = Ω T S & Ω T S ∪ P = Ω T S,

(3) P ∩ Ω T S = P & Ω T S ∩ P = P,

(4) P ∩ ∅T S = ∅T S & ∅T S ∩ P = ∅T S,

(5) P c = Ω T S \ P,

(6) P c = (P qua Subset of the carrier of T S) c ,

(7) p ∈ P c iff not p ∈ P,

(8) (Ω T S) c = ∅T S,

(9) Ω T S = (∅T S) c ,

(10) (P c ) c = P,
1
Supported by RPBP.III-24.C1.
f
c 1990 Fondation Philippe le Hodey
231 ISSN 0777-4028
232 Miroslaw Wysocki and Agata Darmochwal

(11) P ∪ P c = Ω T S & P c ∪ P = Ω T S,

(12) P ∩ P c = ∅T S & P c ∩ P = ∅T S,

(13) (P ∪ Q) c = (P c ) ∩ (Q c ),

(14) (P ∩ Q) c = (P c ) ∪ (Q c ),

(15) P ⊆ Q iff Q c ⊆ P c ,

(16) P \Q = P ∩Qc,

(17) (P \ Q) c = P c ∪ Q,

(18) P ⊆ Q c implies Q ⊆ P c ,

(19) P c ⊆ Q implies Q c ⊆ P,

(20) P ⊆ Q iff P ∩ Q c = ∅,

(21) P c = Q c implies P = Q,

(22) ∅T S is closed ,

(23) Cl (∅T S) = ∅T S,

(24) P ⊆ Cl P,

(25) P ⊆ Q implies Cl P ⊆ Cl Q,

(26) Cl (Cl P ) = Cl P,

(27) Cl (Ω T S) = Ω T S,

(28) Ω T S is closed ,

(29) P is closed iff P c is open ,

(30) P is open iff P c is closed ,

(31) Q is closed & P ⊆ Q implies Cl P ⊆ Q,

(32) Cl P \ Cl Q ⊆ Cl (P \ Q),

(33) Cl (P ∩ Q) ⊆ Cl P ∩ Cl Q,

(34) P is closed & Q is closed implies Cl (P ∩ Q) = Cl P ∩ Cl Q,

(35) P is closed & Q is closed implies P ∩ Q is closed ,


Subsets of Topological Spaces 233

(36) P is closed & Q is closed implies P ∪ Q is closed ,

(37) P is open & Q is open implies P ∪ Q is open ,

(38) P is open & Q is open implies P ∩ Q is open ,

(39) p ∈ Cl P iff for G st G is open holds p ∈ G implies P ∩ G 6= ∅,

(40) Q is open implies Q ∩ Cl P ⊆ Cl (Q ∩ P ),

(41) Q is open implies Cl (Q ∩ Cl P ) = Cl (Q ∩ P ).

Let us consider T S, P . The functor

Int P,

yields the type Subset of T S and is defined by

it = (Cl (P c )) c .

One can prove the following propositions:

(42) Int P = (Cl P c ) c ,

(43) Int (Ω T S) = Ω T S,

(44) Int P ⊆ P,

(45) Int (Int P ) = Int P,

(46) Int P ∩ Int Q = Int (P ∩ Q),

(47) Int (∅T S) = ∅T S,

(48) P ⊆ Q implies Int P ⊆ Int Q,

(49) Int P ∪ Int Q ⊆ Int (P ∪ Q),

(50) Int (P \ Q) ⊆ Int P \ Int Q,

(51) Int P is open ,

(52) ∅T S is open ,

(53) Ω T S is open ,

(54) x ∈ Int P iff ex Q st Q is open & Q ⊆ P & x ∈ Q,

(55) P is open iff Int P = P,

(56) Q is open & Q ⊆ P implies Q ⊆ Int P,


234 Miroslaw Wysocki and Agata Darmochwal

(57) P is open iff for x holds x ∈ P iff ex Q st Q is open & Q ⊆ P & x ∈ Q,

(58) Cl (Int P ) = Cl (Int (Cl (Int P ))),

(59) P is open implies Cl (Int (Cl P )) = Cl P.

Let us consider T S, P . The functor

Fr P,

yields the type Subset of T S and is defined by

it = Cl P ∩ Cl (P c ).

We now state a number of propositions:

(60) Fr P = Cl P ∩ Cl (P c ),

(61) p ∈ Fr P iff for Q st Q is open & p ∈ Q holds P ∩ Q 6= ∅ & P c ∩ Q 6= ∅,

(62) Fr P = Fr (P c ),

(63) Fr P ⊆ Cl P,

(64) Fr P = Cl (P c ) ∩ P ∪ (Cl P \ P ),

(65) Cl P = P ∪ Fr P,

(66) Fr (P ∩ Q) ⊆ Fr P ∪ Fr Q,

(67) Fr (P ∪ Q) ⊆ Fr P ∪ Fr Q,

(68) Fr (Fr P ) ⊆ Fr P,

(69) P is closed implies Fr P ⊆ P,

(70) Fr P ∪ Fr Q = Fr (P ∪ Q) ∪ Fr (P ∩ Q) ∪ (Fr P ∩ Fr Q),

(71) Fr (Int P ) ⊆ Fr P,

(72) Fr (Cl P ) ⊆ Fr P,

(73) Int P ∩ Fr P = ∅,

(74) Int P = P \ Fr P,

(75) Fr (Fr (Fr P )) = Fr (Fr P ),

(76) P is open iff Fr P = Cl P \ P,

(77) P is closed iff Fr P = P \ Int P.


Subsets of Topological Spaces 235

Let us consider T S, P . The predicate

P is dense is defined by Cl P = Ω T S.

We now state several propositions:

(78) P is dense iff Cl P = Ω T S,

(79) P is dense & P ⊆ Q implies Q is dense ,

(80) P is dense iff for Q st Q 6= ∅ & Q is open holds P ∩ Q 6= ∅,

(81) P is dense implies for Q holds Q is open implies Cl Q = Cl (Q ∩ P ),

(82) P is dense & Q is dense & Q is open implies P ∩ Q is dense .

Let us consider T S, P . The predicate

P is boundary is defined by P c is dense .

Next we state several propositions:

(83) P is boundary iff P c is dense ,

(84) P is boundary iff Int P = ∅,

(85) P is boundary & Q is boundary & Q is closed implies P ∪ Q is boundary ,

(86) P is boundary iff for Q st Q ⊆ P & Q is open holds Q = ∅,

(87) P is closed implies (P is boundary iff for Q


st Q 6= ∅ & Q is open ex G st G ⊆ Q & G 6= ∅ & G is open & P ∩ G = ∅),

(88) P is boundary iff P ⊆ Fr P.

Let us consider T S, P . The predicate

P is nowheredense is defined by Cl P is boundary .

One can prove the following propositions:

(89) P is nowheredense iff Cl P is boundary ,

(90) P is nowheredense & Q is nowheredense implies P ∪ Q is nowheredense ,

(91) P is nowheredense implies P c is dense ,

(92) P is nowheredense implies P is boundary ,

(93) Q is boundary & Q is closed implies Q is nowheredense ,


236 Miroslaw Wysocki and Agata Darmochwal

(94) P is closed implies (P is nowheredense iff P = Fr P ),

(95) P is open implies Fr P is nowheredense ,

(96) P is closed implies Fr P is nowheredense ,

(97) P is open & P is nowheredense implies P = ∅.

We now define three new predicates. Let us consider T S, P . The predicate

P is domain is defined by Int (Cl P ) ⊆ P & P ⊆ Cl (Int P ).

The predicate

P is closed domain is defined by P = Cl (Int P ).

The predicate

P is open domain is defined by P = Int (Cl P ).

The following propositions are true:

(98) P is domain iff Int (Cl P ) ⊆ P & P ⊆ Cl (Int P ),

(99) P is closed domain iff P = Cl (Int P ),

(100) P is open domain iff P = Int (Cl P ),

(101) P is open domain iff P c is closed domain ,

(102) P is closed domain implies Fr (Int P ) = Fr P,

(103) P is closed domain implies Fr P ⊆ Cl (Int P ),

(104) P is open domain implies Fr P = Fr (Cl P ) & Fr (Cl P ) = Cl P \ P,

(105) P is open & P is closed implies (P is closed domain iff P is open domain),

(106) P is closed & P is domain iff P is closed domain ,

(107) P is open & P is domain iff P is open domain ,

(108) P is closed domain & Q is closed domain implies P ∪ Q is closed domain ,

(109) P is open domain & Q is open domain implies P ∩ Q is open domain ,

(110) P is domain implies Int (Fr P ) = ∅,

(111) P is domain implies Int P is domain & Cl P is domain .


Subsets of Topological Spaces 237

References
[1] Beata Padlewska. Families of sets. Formalized Mathematics, 1, 1990.

[2] Beata Padlewska and Agata Darmochwal. Topological spaces and continuous func-
tions. Formalized Mathematics, 1, 1990.

[3] Andrzej Trybulec. Domains and their Cartesian products. Formalized Mathematics,
1, 1990.

[4] Andrzej Trybulec. Tarski Grothendieck set theory. Formalized Mathematics, 1, 1990.

[5] Zinaida Trybulec and Halina Świe czkowska. Boolean properties of sets. Formalized

Mathematics, 1, 1990.

Received April 28, 1989


238
FORMALIZED MATHEMATICS
Number 1, January 1990
Université Catholique de Louvain

Connected Spaces

Beata Padlewska1
Warsaw University
Bialystok

Summary. The following notions are defined: separated sets, connected


spaces, connected sets, components of a topological space, the component of a
point. The definition of the boundary of a set is also included. The singleton of a
point of a topological space is redefined as a subset of the space. Some theorems
about these notions are proved.

The articles [3], [4], [1], [2], and [5] provide the notation and terminology for this paper.
For simplicity we adopt the following convention: GX, GY will have the type TopSpace;
A, A1, B, B1, C will have the type Subset of GX. The arguments of the notions defined
below are the following: GX which is an object of the type TopSpace; A, B which are
objects of the type Subset of GX. The predicate

A, B are separated is defined by Cl A ∩ B = ∅(GX) & A ∩ Cl B = ∅(GX).

The following propositions are true:

(1) A, B are separated implies B, A are separated ,

(2) A, B are separated implies A ∩ B = ∅(GX),

(3) Ω (GX) = A ∪ B & A is closed & B is closed & A ∩ B = ∅(GX)


implies A, B are separated ,

(4) Ω (GX) = A ∪ B & A is open & B is open & A ∩ B = ∅(GX)


implies A, B are separated ,

(5) Ω (GX) = A ∪ B & A, B are separated


implies A is open closed & B is open closed ,
1
Supported by RPBP.III-24.C1.
f
c 1990 Fondation Philippe le Hodey
239 ISSN 0777-4028
240 Beata Padlewska

(6) for X 0
being SubSpace of GX, P 1,Q1 being Subset of GX, P,Q being Subset of X 0
st P = P 1 & Q = Q1 holds P, Q are separated implies P 1,Q1 are separated ,

(7) for X 0
being SubSpace of GX, P,Q being Subset of GX, P 1,Q1 being Subset of X 0
st P = P 1 & Q = Q1 & P ∪ Q ⊆ Ω (X 0 )
holds P, Q are separated implies P 1,Q1 are separated ,

(8) A, B are separated & A1 ⊆ A & B1 ⊆ B implies A1,B1 are separated ,

(9) A, B are separated & A, C are separated implies A, B ∪ C are separated ,

(10) A is closed & B is closed or A is open & B is open


implies A \ B,B \ A are separated .

Let GX have the type TopSpace. The predicate

GX is connected

is defined by

for A,B being Subset of GX


st Ω (GX) = A ∪ B & A, B are separated holds A = ∅(GX) or B = ∅(GX).

One can prove the following propositions:

(11) GX is connected iff for A,B being Subset of GX st


Ω (GX) = A ∪ B & A 6= ∅(GX) & B 6= ∅(GX) & A is closed & B is closed
holds A ∩ B 6= ∅(GX),

(12) GX is connected iff for A,B being Subset of GX st


Ω (GX) = A ∪ B & A 6= ∅(GX) & B 6= ∅(GX) & A is open & B is open
holds A ∩ B 6= ∅(GX),

(13) GX is connected iff for A being Subset of GX


st A 6= ∅(GX) & A 6= Ω (GX) holds (Cl A) ∩ Cl (Ω (GX) \ A) 6= ∅(GX),

(14) GX is connected iff for A being Subset of GX


st A is open closed holds A = ∅(GX) or A = Ω (GX),

(15) for F being map of GX,GY st


F is continuous & F ◦ (Ω (GX)) = Ω (GY ) & GX is connected
holds GY is connected .
Connected Spaces 241

The arguments of the notions defined below are the following: GX which is an object
of the type TopSpace; A which is an object of the type Subset of GX. The predicate
A is connected is defined by GX | A is connected .

One can prove the following propositions:


(16) A 6= ∅(GX) implies (A is connected iff for P,Q being Subset of GX
st A = P ∪ Q & P, Q are separated holds P = ∅(GX) or Q = ∅(GX)),

(17) A is connected & A ⊆ B ∪ C & B, C are separated implies A ⊆ B or A ⊆ C,

(18) A is connected & B is connected & not A, B are separated


implies A ∪ B is connected ,

(19) C 6= ∅(GX) & C is connected & C ⊆ A & A ⊆ Cl C implies A is connected ,

(20) A 6= ∅(GX) & A is connected implies Cl A is connected ,

(21) GX is connected
& A 6= ∅(GX) & A is connected & Ω (GX) \ A = B ∪ C & B, C are separated
implies A ∪ B is connected & A ∪ C is connected ,

(22) Ω (GX) \ A = B ∪ C & B, C are separated & A is closed


implies A ∪ B is closed & A ∪ C is closed ,

(23) C is connected & C ∩ A 6= ∅(GX) & C \ A 6= ∅(GX)


implies C ∩ Fr A 6= ∅(GX),

(24) for X 0 being SubSpace of GX, A being Subset of GX, B being Subset of X 0
st A 6= ∅(GX) & A = B holds A is connected iff B is connected ,

(25) A ∩ B 6= ∅(GX) & A is closed & B is closed implies


(A ∪ B is connected & A ∩ B is connected
implies A is connected & B is connected),

(26) for F being Subset-Family of GX st


(for A being Subset of GX st A ∈ F holds A is connected) &
ex A being Subset of GX st A 6= ∅(GX) & A ∈ F &
for B being Subset of GX st B ∈ F & B 6= A holds not A, B are separated
[
holds F is connected ,

(27) for F being Subset-Family of GX st


\
(for A being Subset of GX st A ∈ F holds A is connected) & F 6= ∅(GX)
[
holds F is connected ,
242 Beata Padlewska

(28) Ω (GX) is connected iff GX is connected .

The arguments of the notions defined below are the following: GX which is an object
of the type TopSpace; x which is an object of the type Point of GX. Let us note that
it makes sense to consider the following functor on a restricted area. Then

{x} is Subset of GX.

We now state a proposition

(29) for x being Point of GX holds {x} is connected .

The arguments of the notions defined below are the following: GX which is an object
of the type TopSpace; x, y which are objects of the type Point of GX. The predicate

x, y are joined

is defined by

ex C being Subset of GX st C is connected & x ∈ C & y ∈ C.

We now state four propositions:

(30) (ex x being Point of GX st for y being Point of GX holds x, y are joined)
implies GX is connected ,

(31) (ex x being Point of GX st for y being Point of GX holds x, y are joined)
iff for x,y being Point of GX holds x, y are joined ,

(32) (for x,y being Point of GX holds x, y are joined) implies GX is connected ,

(33) for x being Point of GX, F being Subset-Family of GX st


for A being Subset of GX holds A ∈ F iff A is connected & x ∈ A
holds F 6= ∅.

The arguments of the notions defined below are the following: GX which is an object
of the type TopSpace; A which is an object of the type Subset of GX. The predicate

A is a component of GX

is defined by

A is connected
& for B being Subset of GX st B is connected holds A ⊆ B implies A = B.

The following propositions are true:

(34) A is a component of GX implies A 6= ∅(GX),


Connected Spaces 243

(35) A is a component of GX implies A is closed ,

(36) A is a component of GX & B is a component of GX


implies A = B or (A 6= B implies A, B are separated),

(37) A is a component of GX & B is a component of GX


implies A = B or (A 6= B implies A ∩ B = ∅(GX)),

(38) C is connected implies for S being Subset of GX


st S is a component of GX holds C ∩ S = ∅(GX) or C ⊆ S.

The arguments of the notions defined below are the following: GX which is an object
of the type TopSpace; A, B which are objects of the type Subset of GX. The
predicate
B is a component of A

is defined by

ex B1 being Subset of GX | A st B1 = B & B1 is a component of (GX | A).

We now state a proposition

(39) GX is connected & A 6= Ω (GX)


& A 6= ∅(GX) & A is connected & C is a component of (Ω (GX) \ A)
implies (Ω (GX) \ C) is connected .

The arguments of the notions defined below are the following: GX which is an object
of the type TopSpace; x which is an object of the type Point of GX. The functor

skl x,

with values of the type Subset of GX, is defined by

ex F being Subset-Family of GX
[
st (for A being Subset of GX holds A ∈ F iff A is connected & x ∈ A) & F = it .

In the sequel x has the type Point of GX. One can prove the following propositions:

(40) x ∈ skl x,

(41) skl x is connected ,

(42) C is connected implies (skl x ⊆ C implies C = skl x),

(43) A is a component of GX iff ex x being Point of GX st A = skl x,

(44) A is a component of GX & x ∈ A implies A = skl x,


244 Beata Padlewska

(45) for S being Subset of GX


st S = skl x for p being Point of GX st p 6= x & p ∈ S holds skl p = S,

(46) for F being Subset-Family of GX st


for A being Subset of GX holds A ∈ F iff A is a component of GX
holds F is a cover of GX,

(47) A, B are separated iff Cl A ∩ B = ∅(GX) & A ∩ Cl B = ∅(GX),

(48) GX is connected iff for A,B being Subset of GX


st Ω (GX) = A ∪ B & A, B are separated holds A = ∅(GX) or B = ∅(GX),

(49) A is connected iff GX | A is connected ,

(50) A is a component of GX iff A is connected


& for B being Subset of GX st B is connected holds A ⊆ B implies A = B,

(51) B is a component of A iff


ex B1 being Subset of GX | A st B1 = B & B1 is a component of (GX | A),

(52) B = skl x iff ex F being Subset-Family of GX st


(for A being Subset of GX holds A ∈ F iff A is connected & x ∈ A)
[
& F = B.

References
[1] Beata Padlewska. Families of sets. Formalized Mathematics, 1, 1990.

[2] Beata Padlewska and Agata Darmochwal. Topological spaces and continuous func-
tions. Formalized Mathematics, 1, 1990.

[3] Andrzej Trybulec. Tarski Grothendieck set theory. Formalized Mathematics, 1, 1990.

[4] Zinaida Trybulec and Halina Świe czkowska. Boolean properties of sets. Formalized

Mathematics, 1, 1990.

[5] Miroslaw Wysocki and Agata Darmochwal. Subsets of topological spaces. Formalized
Mathematics, 1, 1990.

Received May 6, 1989


FORMALIZED MATHEMATICS
Number 1, January 1990
Université Catholique de Louvain

Basic Functions and Operations on


Functions

Czeslaw Byliński1
Warsaw University
Bialystok

Summary. We define the following mappings: the characteristic function of a


subset of a set, the inclusion function (injection or embedding), the projections from
a Cartesian product onto its arguments and diagonal function (inclusion of a set into
its Cartesian square). Some operations on functions are also defined: the products
of two functions (the complex function and the more general product-function),
the function induced on power sets by the image and inverse-image. Some simple
propositions related to the introduced notions are proved.

The terminology and notation used in this paper are introduced in the following papers:
[3], [4], [1], and [2]. For simplicity we adopt the following convention: x, y, z, z1, z2
denote objects of the type Any; A, B, V , X, X1, X2, Y , Y 1, Y 2, Z denote objects of
the type set; C, C1, C2, D, D1, D2 denote objects of the type DOMAIN. We now
state several propositions:

(1) A ⊆ Y implies id A = (id Y ) | A,

(2) for f,g being Function st X ⊆ dom (g · f ) holds f ◦ X ⊆ dom g,

(3) for f,g being Function


st X ⊆ dom f & f ◦ X ⊆ dom g holds X ⊆ dom (g · f ),

(4) for f,g being Function


st Y ⊆ rng (g · f ) & g is one-to-one holds g -1 Y ⊆ rng f,

(5) for f,g being Function st Y ⊆ rng g & g -1 Y ⊆ rng f holds Y ⊆ rng (g · f ).
1
Supported by RPBP.III-24.C1.
f
c 1990 Fondation Philippe le Hodey
245 ISSN 0777-4028
246 Czeslaw Byliński

In the article we present several logical schemes. The scheme FuncEx 3 concerns a
constant A that has the type set, a constant B that has the type set and a ternary
predicate P and states that the following holds

ex f being Function
st dom f = [:A,B:] & for x,y st x ∈ A & y ∈ B holds P[x, y, f .hx, yi]

provided the parameters satisfy the following conditions:

• for x,y,z1,z2 st x ∈ A & y ∈ B & P[x, y, z1] & P[x, y, z2] holds z1 = z2,

• for x,y st x ∈ A & y ∈ B ex z st P[x, y, z].

The scheme Lambda 3 concerns a constant A that has the type set, a constant B
that has the type set and a binary functor F and states that the following holds

ex f being Function
st dom f = [:A,B:] & for x,y st x ∈ A & y ∈ B holds f .hx, yi = F(x, y)

for all values of the parameters.


We now state a proposition

(6) for f,g being Function st


dom f = [:X, Y :]
& dom g = [:X, Y :] & for x,y st x ∈ X & y ∈ Y holds f .hx, yi = g .hx, yi
holds f = g.

Let f have the type Function. The functor


◦ f,

yields the type Function and is defined by

dom it = bool dom f & for X st X ∈ bool dom f holds it.X = f ◦ X.

The following propositions are true:

(7) for f,g being Function holds g = ◦ f


iff dom g = bool dom f & for X st X ∈ bool dom f holds g .X = f ◦ X,

(8) for f being Function st X ∈ dom (◦ f ) holds (◦ f ).X = f ◦ X,

(9) for f being Function holds (◦ f ).∅ = ∅,

(10) for f being Function holds rng (◦ f ) ⊆ bool rng f,

(11) for f being Function


holds Y ∈ (◦ f ) ◦ A iff ex X st X ∈ dom (◦ f ) & X ∈ A & Y = (◦ f ).X,
Basic Functions and Operations on . . . 247

(12) for f being Function holds (◦ f ) ◦ A ⊆ bool rng f,

(13) for f being Function holds (◦ f ) -1 B ⊆ bool dom f,

(14) for f being Function of X, D holds (◦ f ) -1 B ⊆ bool X,


[ [
(15) for f being Function holds ((◦ f ) ◦ A) ⊆ f ◦ ( A),
[ [
(16) for f being Function st A ⊆ bool dom f holds f ◦ ( A) = ((◦ f ) ◦ A),
[ [
(17) for f being Function of X, D st A ⊆ bool X holds f ◦ ( A) = ((◦ f ) ◦ A),
[ [
(18) for f being Function holds ((◦ f ) -1 B) ⊆ f -1 ( B),
[ [
(19) for f being Function st B ⊆ bool rng f holds f -1 ( B) = ((◦ f ) -1 B),

(20) for f,g being Function holds ◦ (g · f ) = ◦ g · ◦ f,

(21) for f being Function holds ◦ f is Function of bool dom f,bool rng f,

(22) for f being Function of X, Y


st Y = ∅ implies X = ∅ holds ◦ f is Function of bool X,bool Y.

The arguments of the notions defined below are the following: X, D which are
objects of the type reserved above; f which is an object of the type Function of X, D.
Let us note that it makes sense to consider the following functor on a restricted area.
Then
◦f is Function of bool X,bool D.
Let f have the type Function. The functor
-1 f,

yields the type Function and is defined by

dom it = bool rng f & for Y st Y ∈ bool rng f holds it.Y = f -1 Y.

We now state a number of propositions:

(23) for g,f being Function holds


g = -1 f iff dom g = bool rng f & for Y st Y ∈ bool rng f holds g .Y = f -1 Y,

(24) for f being Function st Y ∈ dom (-1 f ) holds (-1 f ).Y = f -1 Y,

(25) for f being Function holds rng (-1 f ) ⊆ bool dom f,

(26) for f being Function


holds X ∈ (-1 f ) ◦ A iff ex Y st Y ∈ dom (-1 f ) & Y ∈ A & X = (-1 f ).Y,
248 Czeslaw Byliński

(27) for f being Function holds (-1 f ) ◦ B ⊆ bool dom f,

(28) for f being Function holds (-1 f ) -1 A ⊆ bool rng f,


[ [
(29) for f being Function holds ((-1 f ) ◦ B) ⊆ f -1 ( B),
[ [
(30) for f being Function st B ⊆ bool rng f holds ((-1 f ) ◦ B) = f -1 ( B),
[ [
(31) for f being Function holds ((-1 f ) -1 A) ⊆ f ◦ ( A),

(32) for f being Function


[ [
st A ⊆ bool dom f & f is one-to-one holds ((-1 f ) -1 A) = f ◦ ( A),

(33) for f being Function holds (-1 f ) ◦ B ⊆ (◦ f ) -1 B,

(34) for f being Function st f is one-to-one holds (-1 f ) ◦ B = (◦ f ) -1 B,

(35) for f being Function, A being set


st A ⊆ bool dom f holds (-1 f ) -1 A ⊆ (◦ f ) ◦ A,

(36) for f being Function, A being set


st f is one-to-one holds (◦ f ) ◦ A ⊆ (-1 f ) -1 A,

(37) for f being Function, A being set


st f is one-to-one & A ⊆ bool dom f holds (-1 f ) -1 A = (◦ f ) ◦ A,

(38) for f,g being Function st g is one-to-one holds -1 (g · f ) = -1 f · -1 g,

(39) for f being Function holds -1 f is Function of bool rng f,bool dom f.

Let us consider A, X. The functor

χ (A, X),

yields the type Function and is defined by

dom it = X
& for x st x ∈ X holds (x ∈ A implies it.x = 1) & (not x ∈ A implies it.x = 0).

We now state a number of propositions:

(40) for f being Function holds f = χ (A, X) iff dom f = X & for x
st x ∈ X holds (x ∈ A implies f .x = 1) & (not x ∈ A implies f .x = 0),

(41) A ⊆ X & x ∈ A implies χ (A, X).x = 1,

(42) x ∈ X & χ (A, X).x = 1 implies x ∈ A,


Basic Functions and Operations on . . . 249

(43) x ∈ X \ A implies χ (A, X).x = 0,

(44) x ∈ X & χ (A, X).x = 0 implies not x ∈ A,

(45) x ∈ X implies χ (∅,X).x = 0,

(46) x ∈ X implies χ (X, X).x = 1,

(47) A ⊆ X & B ⊆ X & χ (A, X) = χ (B, X) implies A = B,

(48) rng χ (A, X) ⊆ {0,1},

(49) for f being Function of X, {0,1} holds f = χ (f -1 {1},X).

Let us consider A, X. Let us note that it makes sense to consider the following
functor on a restricted area. Then

χ (A, X) is Function of X, {0,1}.

One can prove the following propositions:

(50) for d being Element of D holds χ (A, D).d = 1 iff d ∈ A,

(51) for d being Element of D holds χ (A, D).d = 0 iff not d ∈ A.

The arguments of the notions defined below are the following: Y which is an object
of the type reserved above; A which is an object of the type Subset of Y . The functor

incl A,

yields the type Function of A, Y and is defined by

it = id A.

We now state several propositions:

(52) for A being Subset of Y holds incl A = id A,

(53) for A being Subset of Y holds incl A = (id Y ) | A,

(54) for A being Subset of Y holds dom incl A = A & rng incl A = A,

(55) for A being Subset of Y st x ∈ A holds (incl A).x = x,

(56) for A being Subset of Y st x ∈ A holds incl (A).x ∈ Y.

We now define two new functors. Let us consider X, Y . The functor

π1 (X, Y ),
250 Czeslaw Byliński

with values of the type Function, is defined by

dom it = [:X, Y :] & for x,y st x ∈ X & y ∈ Y holds it.hx, yi = x.

The functor
π2 (X, Y ),

yields the type Function and is defined by

dom it = [:X, Y :] & for x,y st x ∈ X & y ∈ Y holds it.hx, yi = y.

Next we state several propositions:

(57) for f being Function holds f = π1 (X, Y )


iff dom f = [:X, Y :] & for x,y st x ∈ X & y ∈ Y holds f .hx, yi = x,

(58) for f being Function holds f = π2 (X, Y )


iff dom f = [:X, Y :] & for x,y st x ∈ X & y ∈ Y holds f .hx, yi = y,

(59) rng π1 (X, Y ) ⊆ X,

(60) Y 6= ∅ implies rng π1 (X, Y ) = X,

(61) rng π2 (X, Y ) ⊆ Y,

(62) X 6= ∅ implies rng π2 (X, Y ) = Y.

Let us consider X, Y . Let us note that it makes sense to consider the following
functors on restricted areas. Then

π1 (X, Y ) is Function of [:X, Y :],X,

π2 (X, Y ) is Function of [:X, Y :],Y.

We now state two propositions:

(63) for d1 being Element of D1


for d2 being Element of D2 holds π1 (D1,D2).hd1,d2i = d1,

(64) for d1 being Element of D1


for d2 being Element of D2 holds π2 (D1,D2).hd1,d2i = d2.

Let us consider X. The functor


δ X,

with values of the type Function, is defined by

dom it = X & for x st x ∈ X holds it.x = hx, xi.


Basic Functions and Operations on . . . 251

The following two propositions are true:

(65) for f being Function


holds f = δ X iff dom f = X & for x st x ∈ X holds f .x = hx, xi,

(66) rng δ X ⊆ [:X, X:].

Let us consider X. Let us note that it makes sense to consider the following functor
on a restricted area. Then

δX is Function of X, [:X, X:].

Let f , g have the type Function. The functor

[(f, g)],

with values of the type Function, is defined by

dom it = dom f ∩ dom g & for x st x ∈ dom it holds it.x = hf .x,g .xi.

We now state a number of propositions:

(67) for f,g,f g being Function holds f g = [(f, g)]


iff dom f g = dom f ∩ dom g & for x st x ∈ dom f g holds f g .x = hf .x,g .xi,

(68) for f,g being Function st x ∈ dom f ∩ dom g holds [(f, g)].x = hf .x,g .xi,

(69) for f,g being Function


st dom f = X & dom g = X & x ∈ X holds [(f, g)].x = hf .x,g .xi,

(70) for f,g being Function st dom f = X & dom g = X holds dom [(f, g)] = X,

(71) for f,g being Function holds rng [(f, g)] ⊆ [:rng f,rng g:],

(72) for f,g being Function st dom f = dom g & rng f ⊆ Y & rng g ⊆ Z
holds π1 (Y, Z) · [(f, g)] = f & π2 (Y, Z) · [(f, g)] = g,

(73) [(π1 (X, Y ),π2 (X, Y ))] = id [:X, Y :],

(74) for f,g,h,k being Function


st dom f = dom g & dom k = dom h & [(f, g)] = [(k, h)] holds f = k & g = h,

(75) for f,g,h being Function holds [(f · h,g · h)] = [(f, g)] · h,

(76) for f,g being Function holds [(f, g)] ◦ A ⊆ [:f ◦ A,g ◦ A:],

(77) for f,g being Function holds [(f, g)] -1 [:B, C:] = f -1 B ∩ g -1 C,
252 Czeslaw Byliński

(78) for f being Function of X, Y for g being Function of X, Z st


(Y = ∅ implies X = ∅) & (Z = ∅ implies X = ∅)
holds [(f, g)] is Function of X, [:Y, Z:].

The arguments of the notions defined below are the following: X, D1, D2 which are
objects of the type reserved above; f 1 which is an object of the type Function of X,
D1; f 2 which is an object of the type Function of X, D2. Let us note that it makes
sense to consider the following functor on a restricted area. Then

[(f 1,f 2)] is Function of X, [:D1,D2:].

We now state several propositions:

(79) for f 1 being Function of C, D1 for f 2 being Function of C, D2


for c being Element of C holds [(f 1,f 2)].c = hf 1.c,f 2.ci,

(80) for f being Function of X, Y for g being Function of X, Z st


(Y = ∅ implies X = ∅) & (Z = ∅ implies X = ∅) holds rng [(f, g)] ⊆ [:Y, Z:],

(81) for f being Function of X, Y for g being Function of X, Z st


(Y = ∅ implies X = ∅) & (Z = ∅ implies X = ∅)
holds π1 (Y, Z) · [(f, g)] = f & π2 (Y, Z) · [(f, g)] = g,

(82) for f being Function of X, D1 for g being Function of X, D2


holds π1 (D1,D2) · [(f, g)] = f & π2 (D1,D2) · [(f, g)] = g,

(83) for f 1,f 2 being Function of X, Y for g1,g2 being Function of X, Z st


(Y = ∅ implies X = ∅) & (Z = ∅ implies X = ∅) & [(f 1,g1)] = [(f 2,g2)]
holds f 1 = f 2 & g1 = g2,

(84) for f 1,f 2 being Function of X, D1 for g1,g2 being Function of X, D2


st [(f 1,g1)] = [(f 2,g2)] holds f 1 = f 2 & g1 = g2.

Let f , g have the type Function. The functor

[:f, g:],

yields the type Function and is defined by

dom it = [:dom f,dom g:]


& for x,y st x ∈ dom f & y ∈ dom g holds it.hx, yi = hf .x,g .yi.

The following propositions are true:

(85) for f,g,f g being Function holds f g = [:f, g:] iff dom f g = [:dom f,dom g:]
& for x,y st x ∈ dom f & y ∈ dom g holds f g .hx, yi = hf .x,g .yi,
Basic Functions and Operations on . . . 253

(86) for f,g being Function, x,y


st hx, yi ∈ [:dom f,dom g:] holds [:f, g:].hx, yi = hf .x,g .yi,

(87) for f,g being Function


holds [:f, g:] = [(f · π1 (dom f,dom g),g · π2 (dom f,dom g))],

(88) for f,g being Function holds rng [:f, g:] = [:rng f,rng g:],

(89) for f,g being Function


st dom f = X & dom g = X holds [(f, g)] = [:f, g:] · (δ X),

(90) [:id X,id Y :] = id [:X, Y :],

(91) for f,g,h,k being Function holds [:f, h:] · [(g, k)] = [(f · g,h · k)],

(92) for f,g,h,k being Function holds [:f, h:] · [:g, k:] = [:f · g,h · k:],

(93) for f,g being Function holds [:f, g:] ◦ [:B, C:] = [:f ◦ B,g ◦ C:],

(94) for f,g being Function holds [:f, g:] -1 [:B, C:] = [:f -1 B,g -1 C:],

(95) for f being Function of X, Y for g being Function of V, Z st


(Y = ∅ implies X = ∅) & (Z = ∅ implies V = ∅)
holds [:f, g:] is Function of [:X, V :],[:Y, Z:].

The arguments of the notions defined below are the following: X1, X2, D1, D2 which
are objects of the type reserved above; f 1 which is an object of the type Function of
X1, D1; f 2 which is an object of the type Function of X2, D2. Let us note that it
makes sense to consider the following functor on a restricted area. Then

[:f 1,f 2:] is Function of [:X1,X2:],[:D1,D2:].

One can prove the following propositions:

(96) for f 1 being Function of C1,D1 for f 2 being Function of C2,D2


for c1 being Element of C1
for c2 being Element of C2 holds [:f 1,f 2:].hc1,c2i = hf 1.c1,f 2.c2i,

(97) for f 1 being Function of X1,Y 1 for f 2 being Function of X2,Y 2 st


(Y 1 = ∅ implies X1 = ∅) & (Y 2 = ∅ implies X2 = ∅)
holds [:f 1,f 2:] = [(f 1 · π1 (X1,X2),f 2 · π2 (X1,X2))],

(98) for f 1 being Function of X1,D1 for f 2 being Function of X2,D2


holds [:f 1,f 2:] = [(f 1 · π1 (X1,X2),f 2 · π2 (X1,X2))],
254 Czeslaw Byliński

(99) for f 1 being Function of X, Y 1 for f 2 being Function of X, Y 2 st


(Y 1 = ∅ implies X = ∅) & (Y 2 = ∅ implies X = ∅)
holds [(f 1,f 2)] = [:f 1,f 2:] · (δ X),

(100) for f 1 being Function of X, D1


for f 2 being Function of X, D2 holds [(f 1,f 2)] = [:f 1,f 2:] · (δ X).

References
[1] Czeslaw Byliński. Functions and their basic properties. Formalized Mathematics, 1,
1990.

[2] Czeslaw Byliński. Functions from a set to a set. Formalized Mathematics, 1, 1990.

[3] Andrzej Trybulec. Tarski Grothendieck set theory. Formalized Mathematics, 1, 1990.

[4] Zinaida Trybulec and Halina Świe czkowska. Boolean properties of sets. Formalized

Mathematics, 1, 1990.

Received May 9, 1989

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy