2.3 Computer representations of geographic information
2.3.4 Topology and spatial relationships
General spatial topology
Topologydeals with spatial properties that do not change under certain transfor- mations. For example, features drawn on a sheet of rubber (as in Figure 2.13) can be made to change in shape and size by stretching and pulling the sheet. However, some properties of these features do not change:
• AreaEis still inside areaD,
• The neighbourhood relationships between A, B, C, D, and E stay intact, and their boundaries have the same start and end nodes, and
• The areas are still bounded by the same boundaries, only the shapes and lengths of their perimeters have changed.
1 3 A B C D E 2 4 5 6 7 3 A B C D E 4 5 2 6 7 1 Figure 2.13: Rubber sheet transformation: The space is transformed, yet many relationships between the constituents remain unchanged.
Topological relationships are built from simple elements into more complex el- ements: nodes define line segments, and line segments connect to define lines, which in turn define polygons. The fundamental issues relating to order, con-
nectivity and adjacency of geographical elements form the basis of more sophis- Topological properties ticated GIS analyses. These relationships (called topological properties) are in-
variant under a continuous transformation, referred to as a topological mapping. In what follows below, we will look at aspects of topology in two ways. Firstly, using simplices, we will look at how simple elements (points) can be combined to define more complex ones (lines and polygons). Secondly, we will exam- ine the logical aspects of topological relationships using set-theory. The three- dimensional case is also briefly discussed.
Topological relationships
The mathematical properties of the geometric space used for spatial data can be described as follows:
• The space is a three-dimensionalEuclidean spacewhere for every point we can determine its three-dimensional coordinates as a triple(x, y, z)of real numbers. In this space, we can define features like points, lines, polygons, and volumes as geometric primitives of the respective dimension. A point is zero-dimensional, a line one-dimensional, a polygon two-dimensional, and a volume is a three-dimensional primitive.
• The space is ametric space, which means that we can always compute the distance between two points according to a given distance function. Such a function is also known as ametric.
• The space is a topological space, of which the definition is a bit compli- cated. In essence, for every point in the space we can find a neighbourhood around it that fully belongs to that space as well.
• Interiorandboundaryare properties of spatial features that remain invari- ant under topological mappings. This means, that under any topological mapping, the interior and the boundary of a feature remains unbroken and intact.
0-simplex simplicial complex 3-simplex 2-simplex 1-simplex Figure 2.14: Simplices and a simplicial complex. Features are approxi- mated by a set of points, line segments, triangles, and tetrahedrons.
‘topological sensitivity’ simple building blocks have been proposed with which more complicated representations can be constructed:
• We can define within the topological space, features that are easy to handle and that can be used as representations of geographic objects. These fea- tures are calledsimplicesas they are the simplest geometric shapes of some dimension: point(0-simplex),line segment(1-simplex),triangle(2-simplex), andtetrahedron(3-simplex).
• When we combine various simplices into a single feature, we obtain asim- plicial complex. Figure2.14provides examples.
As the topological characteristics of simplices are well-known, we can infer the topological characteristics of a simplicial complex from the way it was con- structed.
The topology of two dimensions
We can use the topological properties of interior and boundary to define rela- tionships between spatial features. Since the properties of interior and bound- ary do not change under topological mappings, we can investigate their possi- ble relations between spatial features.4 We can define the interiorof a region R
as the largest set of points ofR for which we can construct a disk-like environ- Interior and exterior ment around it (no matter how small) that also falls completely inside R. The
boundary ofRis the set of those points belonging toRbut that do not belong to the interior ofR, i.e. one cannot construct a disk-like environment around such points that still belongs toRcompletely.
Suppose we consider a spatial region A. It has a boundary and an interior, both seen as (infinite) sets of points, and which are denoted byboundary(A)and
interior(A), respectively. We consider all possible combinations of intersections (∩) between the boundary and the interior of A with those of another region
B, and test whether they are the empty set (∅) or not. From these intersection Set theory patterns, we can derive eight (mutually exclusive) spatial relationships between
two regions. If, for instance, the interiors ofAand B do not intersect, but their boundaries do, yet a boundary of one does not intersect the interior of the other, we say that A and B meet. In mathematics, we can therefore define the meets
relationship using set theory, as
4We restrict ourselves here to relationships between spatialregions(i.e. two-dimensional fea-
AmeetsB =def interior(A)∩interior(B) = ∅ ∧
boundary(A)∩boundary(B)6=∅ ∧
interior(A)∩boundary(B) =∅ ∧
boundary(A)∩interior(B) =∅.
In the above formula, the symbol∧expresses the logical connective ‘and’. Thus, the formula states four properties that must all hold for the formula to be true.
... is disjoint from ... ... meets ... ... is equal to ... ... is inside ... ... covered by .. ... contains ... ... covers ... ... overlaps ...
Figure 2.15: Spatial re- lationships between two regions derived from the topological invariants of in- tersections of boundary and interior. The relation- ships can be read with the green region on the left . . . and the blue region on the
Figure2.15shows all eight spatial relationships:disjoint,meets,equals,inside,cov- ered by, contains,covers, andoverlaps. These relationships can be used in queries against a spatial database, and represent the ‘building blocks’ of more complex spatial queries.
It turns out that the rules of how simplices and simplicial complexes can be emdedded in space are quite different for two-dimensional space than they are for three-dimensional space. Such a set of rules defines thetopological consistency
of that space. It can be proven that if the rules below are satisfied for all fea- Topological consistency tures in atwo-dimensional space, the features define a topologically consistent
1. Every 1-simplex (‘arc’) must be bounded by two 0-simplices (‘nodes’, namely its begin and end node)
2. Every 1-simplex borders two 2-simplices (‘polygons’, namely its ‘left’ and ‘right’ polygons)
3. Every 2-simplex has a closed boundary consisting of an alternating (and cyclic) sequence of 0- and 1-simplices.
4. Around every 0-simplex exists an alternating (and cyclic) sequence of 1- and 2-simplices.
5. 1-simplices only intersect at their (bounding) nodes.
0
rule (1) rules (2, 5) rule (3) rule (4) 0 1 1 1 1 1 0 0 0 2 1 2 2 1 1
Figure 2.16: The five rules of topological consis- tency in two-dimensional space
The three-dimensional case
It is not without reason that our discussion of vector representations and spatial topology has focused mostly on objects in two-dimensional space. The history of spatial data handling is almost purely 2D, and this is remains the case for the majority of present-day GIS applications. Many application domains make use of elevational, but these are usually accommodated by so-called 21
2D data
structures. These 21
2D data structures are similar to the (above discussed) 2D
data structures using points, lines and areas. They also apply the rules of two- dimensional topology, as they were illustrated in Figure 2.16. This means that different lines cannot cross without intersecting nodes, and that different areas cannot overlap.
There is, on the other hand, one important aspect in which 212D data does dif- fer from standard 2D data, and that is in their association of an additional z- value with each 0-simplex (‘node’). Thus, nodes also have an elevation value associated with them. Essentially, this allows the GIS user to represent 1- and 2-simplices that are non-horizontal, and therefore, a piecewise planar, ‘wrinkled surface’ can be constructed as well, much like a TIN. Note however, that one cannot have two different nodes with identicalx- andy-coordinates, but differ- entz-values. Such nodes would constitute a perfectly vertical feature, and this is not allowed. Consequently, true solids cannot be represented in a 21
2D GIS.
Solid representation is an important feature for some dedicated GIS application domains. Two of these are worth mentioning here: mineral exploration, where solids are used to represent ore bodies, and urban models, where solids may rep- resent various human constructions like buildings and sewer canals. The three- dimensional characteristics of such objects are fundamental as their depth and
volume may matter, or their real life visibility must be faithfully represented. A solid can be defined as a true 3D object. An important class of solids in 3D GIS is formed by thepolyhedra, which are the solids limited by planarfacets. A facet is polygon-shaped, flat side that is part of the boundary of a polyhedron. Any polyhedron has at least four facets; this happens to be the case for the 3-simplex. Most polyhedra have many more facets; the cube already has six.