Database Reference
In-Depth Information
E G and V G and two morphisms s,t
:
E G
V G giving respectively the source and
target of each edge.
The Yoneda Lemma asserts that C OP embeds in Set C as a full subcategory. In the
graph example, the embedding represents C OP as the subcategory of Set C whose
two objects are V as the one-vertex no-edge graph and E as the two-vertex one-
edge graph (both as functors), and whose two nonidentity morphisms are the two
graph homomorphisms from V to E (both as natural transformations). The natural
transformations from V to an arbitrary graph (functor) G constitute the vertices
of G while those from E to G constitute its edges. Although Set C , which we can
identify with Grph , is not made concrete by either V or E alone, the functor
U
Set 2 sending object G to the pair of sets ( Grph (V ,G) , Grph (E ,G) )
and morphism h
:
Grph
H to the pair of functions ( Grph (V ,h) , Grph (E ,h) )is
faithful. That is, a morphism of graphs can be understood as a pair of functions,
one mapping the vertices and the other the edges, with application still realized
as composition but now with multiple sorts of generalized elements. This shows
that the traditional concept of a concrete category as one whose objects have an
underlying set can be generalized to cater for a wider range of topoi by allowing an
object to have multiple underlying sets, that is, to be multisorted.
An important result, obtained from Proposition 49 in Sect. 8.1.3 , demonstrates
that DB is not a CCC and, consequently, DB is not a standard topos. Thus, for
each sketch category, obtained from a database-mapping graph G , DB Sch (G) (see
Sect. 4.1.3 for the semantics of database-mapping systems) is not a topos as well.
Consequently, in the rest of this chapter, we will investigate some topological
properties of the database category DB . That is, we will consider its metric, subob-
ject classifier and topos properties. We will show that DB is a metric space, weak
monoidal topos, and that there are some negative results, e.g., that DB is not well-
pointed, has no power objects and pullbacks do not preserve epics.
:
G
9.1.1 Database Metric Space
In a metric space X , we denote by X(A,B) the non-negative real quantity of X-
distance from the point A to the point B . In a database context, for any two given
databases A and B , their matching is inverse proportional to their distance: The
maximal distance,
, between any two objects is equal to the minimal possible
0 , while the minimal dis-
tance 0 is obtained for their maximal matching, i.e., when these two objects are
isomorphic ( A
matching, i.e.,
is represented by the closed object
B ).
Following this reasoning, we are able to formally define the concept of the
database distance. In a first approach, we will consider only the simple databases
and hence the subcategory DB :
Search WWH ::




Custom Search