Database Reference
In-Depth Information
It is easy to show that
φ
is a bijection. Indeed, from the fact that
d(A,B)
A
={
|
B
∈
Ob
DB
,B
S
|
S
=
TS
⊆
TA
}
,
we get:
1.
d(A,
=⊥
0
)
0
1
1
⊥
=⊥
→⊥
:
A
→
A
;
A
, such that
f
2.
d(A,B)
=
TA
∩
TB
→
f
:
A
→
=
TA
∩
TB
⊆
TA
;
=
id
A
→
3.
d(A,Υ)
=
TA
∩
TΥ
=
TA
id
A
:
A
→
A
.
Notice that the locally closed property means that, for any distance
d(A,B)
from a simple database
A
, we have a morphism
ϕ(d(A,B))
=
f
:
A
→
A
such
that
d(A,B)
=
f
.
Now we can conservatively extend the metric space to all, also complex, objects
in
DB
:
Proposition 63
If A and B are any two objects in
DB
then their distance
,
denoted
by d(A,B)
,
is defined as follows
:
Υ
if A
≈
B
;
d(A,B)
=
A
B
otherwise.
The
(
binary
)
partial
distance relation
'
' on closed database objects is defined as
the inverse of the PO relation '
'
.
This is a conservative extension of the metrics for
simple objects in Definition
61
.
Proof
From Definition
28
and Corollary
14
in Sect.
3.4.1
, we obtain that the strong
behavioral equivalence '
≈
' is a strict generalization of the
DB
category isomor-
phism '
', so that this extension of the metrics to all objects in
DB
is a generaliza-
tion of the metrics for only simple objects (databases). Let us show that it is a con-
servative extension. In fact,
A
≈
B
iff (
A
B
and
A
B
)iff(
A
B
and
A
B
),
where for the simple objects (by Theorem
6
in Sect.
3.2.5
)
A
B
iff
TA
⊆
TB
.
Consequently, for the simple objects
A
B
.
Moreover, all distances are closed objects and for the simple objects the sets
TS
are closed as well, and hence for any set of simple objects
A,B,C
and
D
,
d(A,B)
≈
B
iff
TA
=
TB
, i.e.,
A
⊆
d(C,D)
iff
d(A,B)
d(C,D)
, and so the metric ordering '
'inthis
proposition is a conservative extension of that in Definition
61
.
Let us show the metric property
d(A,B)
⊗
d(B,C)
d(A,C)
. In fact,
d(A,B)
⊗
d(B,C)
=
(A
⊗
B)
⊗
(B
⊗
C)
(by commutativity of tensor prod-
uct)
(B
⊗
B)
⊗
(A
⊗
C)
. That is, from Corollary
14
in Sect.
3.4.1
,
d(A,B)
⊗
d(B,C)
≈
(B
⊗
B)
⊗
(A
⊗
C)
and
(B
⊗
B)
⊗
(A
⊗
C)
A
⊗
C
=
d(A,C)
, so that
d(A,B)
d(A,C)
.
In Proposition
51
, Sect.
8.1.5
, we demonstrated that the database lattice
L
DB
=
(Ob
D
B,
⊗
d(B,C)
d(A,C)
, i.e.,
d(A,B)
⊗
d(B,C)
,
⊕
,
⊗
)
is a complete algebraic lattice with the top and bottom objects
0
, respectively. Thus, from the fact that each distance
d(A,B)
Υ
and
⊥
=
A
⊗
B
0
, that is,
Υ
is a closed object in
DB
,
Υ
d(A,A)
and
d(A,B)
⊥
d(A,A)
0
. Thus,
d(A,B)
⊥
=
⊗
⊗
=
and
d(A,B)
A
B
B
A
d(B,A)
, i.e.,
d(A,B)