|
Theorem 2. Given h : A → C and f : A → B such that B → C = ∅,
|
|
|
||
|
(∃g : B
→ C . h = g
◦ f ) ⇔
|
ker
h
⊇ ker f
|
♦
|
|
|
|
Proof. From left to right, suppose that
h = g ◦ f . Then
|
|
|
||
|
(a, a′) ∈ ker h
|
|
]]
|
|
|
|
⇔ [[ definition of kernel
|
|
|
||
|
ha = ha′
|
]]
|
|
|
|
|
⇔ [[ h
= g ◦ f
|
|
|
|
|
|
g (f a) = g (f a′)
|
]]
|
|
|
|
|
⇐ [[ Leibniz
|
|
|
|
|
|
f a = f a′
|
|
]]
|
|
|
|
⇔ [[ definition of kernel
|
|
|
||
|
(a, a′) ∈ ker f
|
|
|
|
|
|
923
|
|
Definition 5. The kernel ker f ⊆ A × A of a partial function f : A →0 B is the set of pairs
|
|
|
|
ker
f
= {(a, a′) |
a, a′
∈ dom f ∧ f a = f a′}
|
♦
|
|
|
∪ {(a, a′) | a, a′ ∈ A − dom f }
|
|
|
( g
|
:
|
B
|
→0
|
C . h
|
=
|
g
|
◦
|
f )
|
⇔
|
ker h
|
⊇
|
ker f
|
∧
|
dom h
|
⊆
|
dom f
|
♦
|
|
|
∃
|
|
|
|
|
|
|
|
|
|
|
|
As for the kernel inclusion,
suppose (a, a′)
|
∈
|
ker
f
, so either (i)
a, a′
|
∈
|
dom
f
and
f a
|
=
|
f a′, or (ii) a, a′
|
/ dom f . In case (i),
either
|
|
|||||||||||||
|
f a, f a′
|
|
|
dom
g, when
a, a′
|
|
dom h and h a
|
|
g (f a)
|
|
g (f a′)
|
|
|
|
|
|
|
∈
|
|
||||
|
∈
|
∈
|
=
|
=
|
=
|
h a′, so (a, a′)
|
∈
|
ker h;
or f a, f a′
/
dom g, when
a, a′
/
dom h, so
|
|
|||||||||||||
|
(a, a′)
|
|
|
|
|
|
|
|
ker h .
|
|
|
∈
|
∈
|
|
||||||||
|
∈
|
ker
h. Finally, in case (ii), again
a, a′
|
/ dom h and so (a, a′)
|
∈
|
|
|
|
|
|
|
||||||||||||
|
|
|
|
|
|
|
∈
|
|
|
|
|
|
|
|
|
|
|
|
|
|||
|
From right to left, suppose that ker h ⊇ ker f
|
and dom h ⊆ dom f ; we construct g
with dom g
= {f a | a ∈ dom h} as follows.
|
|
|||||||||||||||||||
|
R injective:
|
R◦ ◦ R ⊆ id
|
R simple:
|
R ◦ R◦ ⊆ id
|
|
R entire:
|
R◦ ◦ R ⊇ id
|
R surjective:
|
R ◦ R◦ ⊇ id
|
|
dom R ⊆ S ⇔ R ⊆ R ◦ S
|
— for coreflexive S
|
|
|
|
Lemma 7. R ◦ dom R = R
|
♦
|
|
|
|
Proof. We have:
|
|
|
|
|
R ◦ dom R
|
]]
|
|
|
|
⊆
|
[[ dom R is coreflexive
|
|
|
|
R
|
[[ instantiate S = dom R in universal property of domain ]]
|
|
|
|
⊆
|
|
||
|
R ◦ dom R
|
✷
|
|
|
|
|
|
|
|
|
T ⊆ R/S
|
⇔
|
T ◦ S ⊆ R
|
⇔ S ⊆ R/T
|
|
|
T ⊆ S\R
|
⇔
|
S ◦ T ⊆ R
|
|
|
Definition
8. The kernel ker R of a relation R is given by
|
|
|
|
ker
R
=
(R\R)
∩ (R\R)◦
|
♦
|
|
|
= (R\R) ∩ (R◦/R◦)
|
|
|
|
In
terms of concrete sets of pairs, the quotients reduce to the following
constructions:
|
|
|
|
(a, b) ∈ R/S ⇔ (∀c . (a, c) ∈ R ⇐ (b, c) ∈ S)
|
|
|
|
(a, c) ∈ S\R⇔ (∀b .
(b, c) ∈ R ⇐ (b, a) ∈ S)
|
|
|
|
and
therefore
|
|
|
|
ker
R
= {(a, a′) |
∀b . (a, b) ∈
R
⇔ (a′, b) ∈ R}
|
|
|
|
925
|
|
(R\R ⊇ S) ∧ (R\R ⊇ S◦)
|
]]
|
|
|
⇔ [[ universal property of division
|
|
|
|
R ⊇ R ◦ S ∧ R ⊇ R ◦ S◦
|
✷
|
|
|
Lemma 10. R◦ ◦ R ⊆ ker R for simple R.
|
|
|
|
♦
|
|
|
|
Proof. We have
|
|
|
|
ker R ⊇ R◦ ◦ R
|
]]
|
|
|
⇔ [[ universal property of kernel
|
|
|
|
R ⊇ R ◦ R◦ ◦ R ∧ R ⊇ R ◦ (R◦ ◦ R)◦
|
|
|
|
id ⊇ R ◦ R◦
|
✷
|
|
Lemma 11. R ◦ ker R ⊆ R
|
♦
|
|
Proof. We have:
|
|
|
ker R ⊆ ker T
|
]]
|
|
|
|
⇔ [[
|
assumption
|
|
|
|
ker R ⊆ ker (S ◦ R)
|
|
|
|
|
⇔ [[
|
universal property of
kernel ]]
|
|
|
|
S ◦ R ⊇ S ◦ R ◦ ker R ∧ S ◦ R ⊇ S ◦ R ◦ (ker R)◦
|
|
||
|
⇔ [[
|
ker R is symmetric, so the two conjuncts are equivalent ]]
|
|
|
|
S ◦ R ⊇ S ◦ R ◦ ker R
|
|
|
|
|
⇐ [[
|
monotonicity ]]
|
|
|
|
R ⊇ R ◦ ker R
|
]]
|
|
|
|
⇔ [[
|
|
||
|
true
|
|
|
|
|
and
|
|
|
|
|
dom
R
⊇ dom T
|
]]
|
|
|
|
⇔ [[
|
assumption
|
|
|
|
dom
R
⊇ dom (S ◦ R)
|
|
||
|
⇔ [[
|
universal
property of domain (dom R is coreflexive)
]]
|
|
|
|
S ◦ R ◦ dom R ⊇ S ◦ R
|
|
||
|
⇔ [[
|
|
|
|
|
⊆
|
[[
|
definition of domain ]]
|
|
T
◦ R◦ ◦ R— which
is S ◦ R
|
||
|
⊆
|
[[
|
|
|
S ◦ S◦
|
||
|
=
|
[[
|
definition of S ]]
|
|
S ◦ R ◦
T◦
|
||
|
=
|
[[
|
by the above, S ◦ R = T ]]
|
|
q0
|
A
|
|
|
f
|
|
|
|
|
|
|
|
|
p0
|
|
|
r : Y →
X such that q0 = p0 ◦ r and q1 = p1 ◦ r.
|
♦
|
|
Such
pullbacks do not always exist. They always do in Set, when the object X is just the set of pairs ker f
|
|
|
f0
|
|
g
|
|
|
|
|
A
|
B
|
|
C
|
|
|
|
|
|
|
|
|
|||
|
|
f1
|
|
|
r
|
|
|
|
|
|
h
|
|
|
|
|
|
|
|
|
|
♦
|
|
|
|
|
|
|
|
D
|
|
|
X
|
p0
|
|
A
|
|
|
|||
|
|
|
|
|
|||||
|
p1
|
|
|
|
|
|
g
|
|
|
|
|
|
|
|
|
|
|
|
|
|
A
|
|
|
|
B
|
|
|
||
|
|
f
|
|
|
|
||||
|
|
|
|
|
|
|
|
|
|
|
The category Set is regular.
|
♦
|
|
||||||
|
is, one with products), R is modelled as a monomorphism R
|
|
A × B into the product:
|
|
|||||
|
|
|
|||||||
|
|
|
R
|
|
|
|
|||
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
A
|
|
A × B
|
|
B
|
|
|
|
|
|
fst
|
snd
|
|
|
|
||||
|
ker f
|
A
|
f
|
B
|
|
|
|
|
|||
|
|
e
|
|
m
|
|
|
|
|
img f
|
|
|
|
|
i
|
p0
|
p1
|
|
|
|
|
|
|
|
||
|
ker h
|
q0
|
A
|
h
|
C
|
|
|
|
|
||||
|
q1
|
|
|
|||
|
|
|
|
|
|
|
|
|
|
f
|
e
|
k
|
|
|
|
|
|
|
|
|
|
|
|
B
|
m
|
img f
|
|
|
|
|
|
|
|

|
h
◦ p0 = h ◦ q0 ◦ i = h ◦ q1 ◦ i = h ◦ p1
|
|
|
|
|
|
|
|
|
|
|
so by
the universal property of the coequaliser there exists a unique mediating
arrow k
|
:
|
img f
|
→
|
C
making the upper
right
|
|
||||
|
triangle
commute. We define partial map g : B
→0 C to be the span B
|
m
|
|
k
|
|
|
|
|||
|
|
img
f
|
|
|
C .
|
|
|
|
||
|
|
|
|
|
|
|
||||
|
|
J. Gibbons / Journal of Logical and Algebraic Methods in
Programming 85 (2016) 921–930
|
929
|
|
|
|
X
|
|
|
|
|
❅!
|
|
|
|
A
|
|
img f
|
|
|
f
|
m
|
k
|
|
|
A
|
B
|
C
|
|

|
a
|
Y
|
|
|
|
|
|
|
❅!
|
d
|
|
|
A
|
c
|
img f
|
|
|
|
|
|
img f
|
m
|
|
|
|
|
|
monomorphism along itself is the identity; so
|
Y
|
=
|
img f
|
, and
|
c
|
=
|
d
|
=
|
id
|
. Secondly, a pullback of
|
the identity (c) is again the
|
|
||||||||||||||
|
|
|
|
|
|
|
|
k e h
|
|
|
|
||||||||||||||||
|
identity; so a = id, and hence X = A and b = e. Therefore,
the outer span is indeed A
|
|
A
|
|
◦ =
|
|
C as required.
|
|
|||||||||||||||||||
|
|
|
|
|
|||||||||||||||||||||||
|
Conversely, given h
= g ◦ f , and kernel
pairs p0, p1 for f
|
and q0, q1
|
for h, we construct the mapping i
: ker f → ker h as
|
|
|||||||||||||||||||||||
|
follows:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
A
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
p0
|
q0
|
|
|
f
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
h
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
||
|
ker f
|
i
|
ker h
|
❅
|
|
|
C
|
|
g
|
|
|
B
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
||||||
|
|
|
|
!
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
p1
|
q1
|
h
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
f
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
||
|
|
|
|
A
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
We have that p0, p1 form a cone over A
|
|
h
|
C
|
|
h
|
|
A :
|
|
|
|
|
|
|
|
|
|
|
|
|
|
||||||
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
||||||||
|
h ◦ p0 = g ◦ f ◦ p0 = g ◦ f ◦ p1 = h ◦ p1
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|||||
|
so by the universal property of the pullback, there exists a
(unique) mediating arrow i : ker f → ker h
|
making the triangles
|
|
||||||||||||||||||||||||
|
p0 = q0 ◦ i and p1 = q1 ◦ i commute.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
✷
|
|
|||
