Modelling spatial relations and operations with...

15
INT. J. GEOGRAPHICAL INFORMATION SYSTEMS. 1993, vor. 7, No. 3, 2tl_22g Modelling spatial relations and operations with partially ordered sets WOLFGANG KAINZ,f MAX J. EGENHOFER and IAN GREASLEYT National C1n1e1 for Geographic Information and Analysis and Department of Surveyin{ Engineering, U;i;;.rrty ;i'#;;". Boardman Hall, Orono, ME"Oa+OS, U.S.n. Abstract' Formalmethods for thedescription of spatial relations canbebased on mathematical theories of order.Subdivisions .iil;;;;;;resented as partially ordered sets (posets), a moder that is generai;;"Gil;;;Jlspat,ar queries about inclusion and coxtainment of spatiai areas. afteia u.iijni-or.tion to the basic concepts ol posets andlattices, theirapplications to modeilin!rputrut relations and operations for sparial regions in terms oicon.";;;;;oui?ruy u.. p.esented. An interpretation is given for new seographical etemenis ;h;; u." created by the compretion from a poset to a iiuiie.^tt i..ho;;-;i;;^l nover approach to characterize certain topological relations baseo on ulut-t-i". ola simplicial complex is a modelfor spatiar iegio-ns that combrnes ilh 6;i;;Ja uno order rerations and ailowsspatiar queries to be answered in a uninea wiv.-' l. Introduction The modelling of,spatial relations in geographical information systems(GIS) is basedon fundamental mathematical theor]es.over the past two decades it has been extensivelv invesrigated^l:*_ l: apply topol:gy {". -"a.rii"g rp"tial rerationships (corbett 1979, white 1990, r9g4,-p.a"k and Kuhn 19g6, Egenhofer and Franzosa 1991)' The findings of these investigations have significantly contributed to the state-of- the-art data models used in modern GIS, such as Arc/Info (Morehouse l9g5), TIGRIS (Herring 1987), System 9 (charrwoo d ei at.19g7) and smailworld GIS (Newell er a/. 1991), and the U.s. SDTS spatiardata exchange standard (Rossmeissl and Rugg l99r). At the same time, only littre attention has been p)ra i" -i-rr" application of complementary or alternative mathematical conceptsto GIS and spatial analysissuch as metric or order. Arthough white's ( 1 9g4)landmark paper on the'use of topology for cartography mentioned partially ordered sets. and a"spite potential for interesting spatial applications of partially ordered sets, this topic has gained only little attention from GIS researchers. Saalfeld(19g3 a, b, 19b5), Meixrer uni suutr"to (r9g5), Greasley (1988'1990) and Kainz.(r9gg, r9g9, r990) investigated some aspects of partiar order relations in GIS. Nevertheless, to daie there exist n"o "o.pr"rr".rri* r""i"r" of partially ordered sets and assessment of their usefulnessin GIS applications. This article attempts to fill this gap by providing an introduction to the matt "matlc, of partially ordered setsand demonstrating theii application to modelling *it"r relationships in The use of partially ordered setsis motivated here by an example to model spatial subdivisions of land. A spatial subdivision is commonly thought of u, u hierarchy in t current address: Department of Geoinformalic-s, International Institute for Aerospace Survey and Earth Sciencei (ITC) p.o. s"- i; Ni-2s00 AA Enschede, The Netherlands. { current address: Biedertalsiras* u cii-arr8 Rodersdorf, Switzerland. 0269 3798193 $10.00 e) 1993 Taylor & Francis Ltd.

Transcript of Modelling spatial relations and operations with...

Page 1: Modelling spatial relations and operations with …homepage.univie.ac.at/.../Kainz_Egenhofer_Greasley_1993.pdfordered sets (posets), a moder that is generai;;"Gil;;;Jlspat,ar as partially

INT. J. GEOGRAPHICAL INFORMATION SYSTEMS. 1993, vor. 7, No. 3, 2tl_22g

Modelling spatial relations and operationswith partially ordered sets

WOLFGANG KAINZ,f MAX J. EGENHOFERand IAN GREASLEYT

National C1n1e1 for Geographic Information and Analysis andDepartment of Surveyin{ Engineering, U;i;;.rrty ;i'#;;".Boardman Hall, Orono, ME"Oa+OS, U.S.n.

Abstract' Formal methods for the description of spatial relations can be based onmathematical theories of order. Subdivisions .iil;;;;;;resented as partiallyordered sets (posets), a moder that is generai;;"Gil;;;Jlspat,ar queries aboutinclusion and coxtainment of spatiai areas. afteia u.iijni-or.tion to the basicconcepts ol posets and lattices, their applications to modeilin! rputrut relations andoperations for sparial regions in terms oicon.";;;;;oui?ruy u.. p.esented. Aninterpretation is given for new seographical etemenis ;h;; u." created by thecompretion from a poset to a iiuiie.^tt i..ho;;-;i;;^l nover approach tocharacterize certain topological relations baseo on ulut-t-i". ola simplicial complexis a model for spatiar iegio-ns that combrnes ilh 6;i;;Ja uno order rerationsand ailows spatiar queries to be answered in a uninea wiv.-'

l. IntroductionThe modelling of,spatial relations in geographical information systems (GIS) isbased on fundamental mathematical theor]es. over the past two decades it has beenextensivelv invesrigated^l:*_

l: apply topol:gy

{". -"a.rii"g rp"tial rerationships(corbett 1979, white 1990, r9g4,-p.a"k and Kuhn 19g6, Egenhofer and Franzosa1991)' The findings of these investigations have significantly contributed to the state-of-the-art data models used in modern GIS, such as Arc/Info (Morehouse l9g5), TIGRIS(Herring 1987), System 9 (charrwoo d ei at.19g7) and smailworld GIS (Newell er a/.1991), and the U.s. SDTS spatiar data exchange standard (Rossmeissl and Rugg l99r).At the same time, only littre attention has been p)ra i"

-i-rr" application ofcomplementary or alternative mathematical concepts to GIS and spatial analysis suchas metric or order. Arthough white's ( 1 9g4) landmark paper on the'use of topology forcartography mentioned partially ordered sets. and a"spite potential for interestingspatial applications of partially ordered sets, this topic has gained only little attentionfrom GIS researchers. Saalfeld (19g3 a, b, 19b5), Meixrer uni suutr"to (r9g5), Greasley(1988' 1990) and Kainz.(r9gg, r9g9, r990) investigated some aspects of partiar orderrelations in GIS. Nevertheless, to daie there exist n"o "o.pr"rr".rri* r""i"r" of partiallyordered sets and assessment of their usefulness in GIS applications. This articleattempts to fill this gap by providing an introduction to the matt "matlc, of partiallyordered sets and demonstrating theii application to modelling *it"r relationships in

The use of partially ordered sets is motivated here by an example to model spatialsubdivisions of land. A spatial subdivision is commonly thought of u, u hierarchy int current address: Department of Geoinformalic-s, International Institute for AerospaceSurvey and Earth Sciencei (ITC) p.o. s"- i; Ni-2s00 AA Enschede, The Netherlands.{ current address: Biedertalsiras* u cii-arr8 Rodersdorf, Switzerland.

0269 3798193 $10.00 e) 1993 Taylor & Francis Ltd.

Page 2: Modelling spatial relations and operations with …homepage.univie.ac.at/.../Kainz_Egenhofer_Greasley_1993.pdfordered sets (posets), a moder that is generai;;"Gil;;;Jlspat,ar as partially

Spatial subdivision with fields and overlapping crop

216 W. Kainz et al.

Figure I

Figure 2. Representations of the subdivision in figure 1 as hierarchies.

which each area belongs to exactly one larger area. For example, most politicalsubdivisions form a hierarchy-a country being divided into states, the states intocounties, the counties into townships. Unfortunately, the model of a hierarchy isfrequently insufficient to model spatial situations. For instance, a city may cross countyboundaries. The following example is to demonstrate why users may not get answers tocertain spatial queries if the spatial situation is modelled as a hierarchy. Consider twocrop zones, A and B, and some fields a, b, c, d in these zones (figure 1). While ahierarchical structure is appropriate to answer queries about fields that are located in asingle zone, it fails for those areas in which both A and B can be grown. Simplequestions such as, 'What can be grown in field c?' or 'Where can I grow A and B?'cannot be answered, because field c would have to be either assigned to zone .4 or B, butnot to both (figure 2).

The mathematical structure of a partially ordered set overcomes many of thehierarchy's limitations and is a better quality model for such a form of geographicalinformation than a hierarchical model. In fact, a hierarchy is a special type of partiallyordered set where there is only one path from any element to the top.

The presentation of possible applications of partially ordered sets to GIS is builtupon the basic theory of partially ordered sets and lattices. The concepts relevant tomodelling spatial relations in GIS and pertinent to the subsequent discussions arebriefly summarized in $2. Readers familiar with this mathematical background mayskip this section and continue with $ 3, which discusses the meaning of certain ordertheoretic properties in terms of spatial subdivisions. Section 4 focuses on the possibleapplications of this theory to determine topological spatial relations such ascontainment and neighbourhood operations. Conclusions in $ 5 compare the models ofanswering spatial queries either in the category of ordered sets or in the category oftopological spaces, and outlines the needs for future research in this area.

2. The mathematics of partially ordered setsOne of the basic structures upon which mathematical disciplines are built is order. A

set is said to be (partially) ordered when an order relation is defined between itselements, making them comparable. The study of partially ordered sets and lattices is

coveredGratzer'Priestleyexamplegermaneto haveinteresteliteratur,lattices ilater sec

Let Ix , v , z e .

A s e t P ua partialposet, thstatemerreplacinl

IrachH asse tlirelation.no,xeP tThe set crConversrwritten irepresen'rclation.and bot t

For pgrcatcf o(l i 'eatest I

-gireittcst (

elemeni <Whereashas neitl:

Page 3: Modelling spatial relations and operations with …homepage.univie.ac.at/.../Kainz_Egenhofer_Greasley_1993.pdfordered sets (posets), a moder that is generai;;"Gil;;;Jlspat,ar as partially

@ies.

Operations with partially ordered sets 217

covered by an extensive amount of mathematical l i terature. Birkhoffs (1967) andGrdtzer's (1978) books are considered to be classics. A recent work by Davey andPriestley (1990) provides an excellcnt introduction to the theory and gives manyexamples and applications in various disciplines. While some of these results aregermane to modell ing spatial relations, a great amount of this theoretical work appearsto have litt le or no meaningfui applications to geographical objects. To prevent theinterested reader from labouring through the extensive volumes of mathematicall i terature, a brief sumrnary of the most important concepts of partially ordered sets andlattices is given in this section. This section also introduces the notations used in thelater sections.

Le t P bease t . A po r t i a l o rde ron P i sa b ina ry re la t i on s on Psuch tha t , f o reve rvx. v. ze P'.

, x < x

i f -r (y

(reflexive)

and ] ( -x, thcn -r:.y (antisymrnetric) (2'l

( l )

(3)rost polit icale states intohierarchy iscross countyet answers tolonsider twor 1). While ae located in aown. Simplew A and B'!'te I or B, but

many of thegeographical,e of partially

GIS is built.s relevant toicusslons are:ground may;ertain orderthe possible

lns such as:he models of: category o["'4.

iltis order. Abetween its

.nd lattices is

if x ( y and y ( z, thcn .x (: (transitive)

A sct P with a reflexive, antisymmetric and transitive relation (order relation) ( is calleda purtially r.trdered set (or poset). For every partially ordered set p we can find a newposct, the duul of P, by defining thar x{y is the dual if and only if yg.x in p. Anystatement about a partially ordered set can be turned into a statement of its dual byreplacing { lvith ), and vice versa.

Each (finitc) poset can be representcd graphically by a tl iagram, also callcd thcHusse dioqram" The construction of a diagram is based on the concept of a coveringrclation. A t 'ouers B (or B is <:oueretl by A) in a poset p means that B < ,4 and therc existsno re P that B < -x < ,4, i.c., ,1 is greatcr than rg anC there is no other elemcnt in betrvccl.The set of all elernents that cover an element x is called lhe t.ouer of x, denoted by X

- .

Ctrnvcrsely, the sct of all elemcnts that arc covcred by X is callcd the r:o<:or;er ol X,written as X A diagram of a posct p is drawn as a configuration of circlesrepresenting the elements of P and connecting l incs in<licating the coveringrelation. lf .4 covcrs B, the circle of clement ,4 is drawn above the circlc for elernent B.und both arc connccted with a straight l inc (figure 3).

For pose ts and subscts of ordered sets it is often desirable to l-rave elements that aregrcater t lr lcss than all othcr clemcnts. Lct / ' � bc a posct and S c P. An elcment aeS is the( l i ' ( u ! t s t ( c t r t nu r imum\e lemen t c l f S i f a ) x fo r eve ry . xes .deno tedbya :maxS .Thegreatest element of P, if i t exists, is called the top element of P. Thc least (or minimumlele.ment crf S, written as min S, and the hottom element of p are defined by duality.Whereas subsets of the poset in figure 3 have greatest and least elements. the poset itselfhas neither a top nor a bottom element.

Figure 3. Poset representing the order in f igure l .

Page 4: Modelling spatial relations and operations with …homepage.univie.ac.at/.../Kainz_Egenhofer_Greasley_1993.pdfordered sets (posets), a moder that is generai;;"Gil;;;Jlspat,ar as partially

218 W. Kainz et al.

2.2. U pper and lower boundsLet Pbea poset and ScP. AnelementxePisan upperbound of S i f s(x fora l l seS.

A lower bound is defined by duality. The set of all upper bounds of S is denoted by S*(read as S upper) and the set of all lower bounds (or S lower\is S*. If S* has a leastelement, it is called the least upper bound (l.u.b.) of S. By duality, if S* has a largestelement, it is called the greatest lower bound (g.l.b.) of S. A least upper bound or agreatest lower bound is always unique. For the least upper bound and the greatestlower bound of two elements x and y we write xvy and xny, respectively.

In some configurations a greatest lower bound or a least upper bound does notexist. This may be the case if elements do not have common bounds or if a g.l.b. or l.u.b.does not ex is t .

2.3. LatticesIn the general case of a partially ordered set, we cannot expect that the greatest

lower bounds and least upper bounds always exist. Therefore, a more specific orderstructure is needed. A lattice L is a poset in which every pair of elements has a leastupper bound and a greatest lower bound. A lattice is called complete when a greatestlower bound and a least upper bound exist for every subset of the poset. It can beproven that every finite lattice is complete. This is an important result, because it meansthat for every lattice with a finite number of elements we can always find least upperbounds and greatest lower bounds for every subset of the lattice.

Not every poset is a lattice, because posets exist in which not all subsets havegreatest lower bounds and least upper bounds. It is, however, always possible to addelements to a poset to create a lattice. The process of the normal completion specifieshow to find the smallest number of elements necessary to add to a poset to create alattice, i.c., to build the minimal containing lattice of a poset (MacNeille 1937). Thenormal completion lattice has two important properties: (1)Every lattice is equal to itsnormal completion lattice. This means, whenever the poset is already a lattice, thenormal completion does not add anything to the lattice. It leaves the lattice unchanged.(2) Since the normal completion turns any poset into a lattice, the successive normalcompletion provides the same normal completion lattice. Therefore, applying thenormal completion more than once does not increase the number of elements added tothe completion lattice. This implies that the number of elements in the completionlatticc is bounded by 2 lor n elements in the poset.

2.4. Direct productThere are many ways of generating new ordered sets from existing posets. One of

these is the direct product of ordered sets. The direct product P x Q of two posets P and

Q is these to fa l l pa i r s ( r , y )w i t h rePand yeQ,o rde redby the ru le tha t ( x , , y r ) ( ( xz , yz )i f a n d o n l y i f x , { x 2 i n P a n d } r ( . ! z i n Q . T h e d i r e c t p r o d u c t o f t w o l a t t i c e s L . , x L r i s alat t ice wi th l .u .b. and g. l .b . formed as (x , , yr )v (xr ,yr ) : (x , v xr ,y , v yr ) and( r r , y r )n ( r r , y r ) : ( x rAXz , ! t ny r ) , r espec t i ve l y , f o ra l l x r , y reL r , x2 , ! 2€L2and (x t , y t ) ,(xr ,yr )eLrxLr . The d iagram of a d i rect product PxQ is drawn by replac ing eachpoint of the diagram of P by a copy of the diagram for Q, and connecting'corresponding ' points.

3. Spatial interpretation of the characteristics of posets and latticesThe spatial relationship ofareas being contained in other areas defines an order on

the set of areas with the order relation < corresponding to the notions of is contained

in', ' l ies irposet, be,

- e v- i f

al- i f

c(

The duacorrespoThereforspatial rr

3.1. BasiUsinl

questioncharacte

QuestiorAnswet

QuestiotAnswe

QuestiotAnswe

QuestiotAnswe

QuestioAnswe

3.2. Th,The

these qtcases. Tquestiota top ortop elenset or n

Morelementthey sta

Lrulif

Page 5: Modelling spatial relations and operations with …homepage.univie.ac.at/.../Kainz_Egenhofer_Greasley_1993.pdfordered sets (posets), a moder that is generai;;"Gil;;;Jlspat,ar as partially

r all seS.rd by S*s a leastt largestn d o r agreatest

loes notor l .u .b.

greatestic order; a leastgrearestcan be

t meanst upper

ts haveto add

pecifies)reate a7). Theal to itsice, theranged.normaling theJded topletion

One of; P a n d(xr ' y r )Lris a

,) andx t , I r ) ,g eachlecting

der ontained

Operations with partially ordered sets 219

in', 'lies in' or 'is part of'. For example, the crop zones and fields of figure 1 represent aposet, because

every area is contained within itself (reflexive),- if an area x is contained in y and y is contained in x, then x and y are the same

area (antisymmetric), andif an area x is contained in y which itself is contained in z, then x is alsocontained in z (transitive).

The dual to the order relation ( is read as 'contains' or'consists of'. This modelcorresponds to the concept of sets being a 'subset of' or ('superset of') other sets.Therefore, we will also apply the set theoretic notions of union and intersection tospatial regions.

3.1. Basic relationsUsing the model of spatial regions ordered by 'is contained in', the following

questions about relationships between those regicns can be answered by applying thecharacteristics of posets and lattices from $ 2 without any additional knowledge.

Question: Is region B contained in region .4?Answer: If B <,4, then B is contained in A.lf A and B are not comparable, then they

either overlap or do not have any area in common.

Question: Which areas are contained in one or more given areas?Answer: Determine all lower bounds of the given areas.

Question: Which areas contain one or more given areas?Answer'. Determine all upper bounds of the given areas.

Question: Which one is the largest area contained in one or more givel areas?Answer: Determine the greatest lower bound of the given areas.

Question: Which one is the smallest area containing one or more given areas?Answer: Determine the least upper bound of the given areas.

3.2. The role of new lattice elementsThe use of greatest lower bounds and least upper bounds for answering some of

these questions shows that we need a lattice in order to find an answer in all possiblecases. This is why the normal completion is so important. It leaves us, however, with thequestion of how to interpret the newly created lattice elements. If the poset already hada top or bottom element, they are retained in the completion lattice. Otherwise a newtop element (the whole area containing all other areas) and bottom element (the emptyset or null area) are created.

More interesting are those new lattice elements other than the top or bottomelement. The following property of the normal ccmpletion aliows us to derive whatthey stand for:

Let P be a poset and A, Bc-P.(A*)* is then the set of the lower bounds of theupper bounds of ,4. This defines aclosure operator,C(A),onP such that AcC(A);tf AcB then C(A)c-C(B); and C(C(A)):C(A). The family of DM(P):

Page 6: Modelling spatial relations and operations with …homepage.univie.ac.at/.../Kainz_Egenhofer_Greasley_1993.pdfordered sets (posets), a moder that is generai;;"Gil;;;Jlspat,ar as partially

L

A B

d

X

a L b

@

220 W. Kainz et al.

Figure 4. Lattice resulting from the normal completion of the poset in figure 3.

: t A = p l ( A * ) *

greatest lower

and/ \'(!J '')

respectively.

From this follows that the new elements added to the poset to form a lattice can beinterpreted as being the intersection of poset elements. For example, the lattice elementX in figure 4 is the spatial intersection of the crop zones A and B.

3.3. Direct product and ouerlayFrom $ 2.4 we know that the direct product of two lattices L, and Lris alattice. The

elements in the product lattice are pairs (o,b) where aeL, and belr. Kainz (1988)suggested replacing (a,b) by aob and avb to model the intersection and union of thetwo orders represented by Lt and Lr, respectively. This approach yields all possibleintersections or unions between the elements of the two lattices in their correct positionwithin the order.

If L, has n elements and L, has m elements then Lrx L, has n.lt,r elements. Thenumber of elements in the product lattice can be reduced depending on whether bothlattices have the same top or bottom element. This is because the top element containsall other elements of the lattice and the bottom element is contained in all other latticeelements. Let / be the top element and b the bottom element. Then xn/: x , xvt: t andxab : b, xvb : x for all x. Table 1 shows the number of elements in the product lattice

Table 1. Number of elements in the intersection and union of two lattices l, and Lrwithnandrr elements depending on their top elements tLt, tL2 and bottom elements bL,, bL,.

Intersection Union

: A| is a complete lattice when ordered by inclusion, in whichbound and least upper bound of a set of elements A, are

) A ,

for interspossibleintereseccomputa

4. PoseThis

operatioThrougtillustrattcomplex(Lefschemodel s1Worboycan be I(Herrinpequivalethe addi1991 ) . Hare easitnumberthink ofcurved,

4.1. SpaA t u

simplicehas twcl-dimensimplicesimplice

'The

This cortriangle

Figure I

t r , : t r , a n d b r , : b r , ( n - l ) - ( m - l ) + 1t r r : t r , a n d b r . , + b L , n , mt L , + t L , a n d b r , : b L , f u - l ) ' ( m - l ) + 1t r . t + t L 2 a n d b L , + b L , n . m

( n - 1 ) . ( m - r ) + 1( n - r ) . ( m - r ) + 1

n . mn - m

Page 7: Modelling spatial relations and operations with …homepage.univie.ac.at/.../Kainz_Egenhofer_Greasley_1993.pdfordered sets (posets), a moder that is generai;;"Gil;;;Jlspat,ar as partially

;ure 3.

n, in which

; &t€

tice can beice element

attice. Thednz (1988)rion of thell possiblect position

rents. The:ther botht containsher latticeut : I anduct lattice

with n andA

t u L t .

Operations with partially ordered sets 221

for intersection and union. The result of these operations yields lattices that reflect allpossible relationships between the spatial areas of two subdivisions after their union orinteresection by using only set and order theory without the necessity for geometl'icalcomputations.

4. Posets and topological spatial relationsThis section describes topological spatial operations based on the theory of $ 2. The

operations are intersection, boundary, neighbourhood, touch, and containment.Throughout this section, we use two intersecting squares as one simple example toillustrate each operation. The intersecting squares are represented as a simplicialcomplex. Simplicial complexes are a well-known concept in algebraic topology(Lefschetz 1975), that has also been used as a simple, but comprehensive framework tomodel spatial data in GIS (Frank and Kuhn 1986, Egenhofer et a\.1990, Pigot 1991,Worboys 1992). The methods as described here for simplices and simplicial complexescan be generalized to arbitrarily shaped cells and cell complexes built from such(Herring 1987). Topology created by a simplicial subdivision of space is nearlyequivalent to cellular topology, a popular way to represent topology in GIS, and it hasthe additional advantage of a rigorous and mathematically sound formalism (HerringI 99 1 ). However, formalization and programming of simplices and simplicial complexesare easier as they are of fixed topological structure, whereas cells may have a varyingnumber of faces in their boundaries. Readers who prefer the cellular model though, maythink of the straight edges displayed in the geographical domain as being arbitrarilycurved, but non-intersecting l ines.

4.1. Spatial data modelA two-dimensional simplicial complex is a collecticn of 0-, l- and 2-Cimensional

simplices points, segments, triangles--with certain characteristics. Every l-simplexhas two O-dimensiolal faces and a 2-simplex has three 0-dimensional and threeI -dimensional faces. The intersection of two simplices is either empty or a face of bothsimplices. A simplicial 2-complex defines a triangulation of the set of points of allsimplices.

' The two intersecting squares X and Y in figure 5 (a) may represent two land parcels.

This configuration can be partitioned into a simplicial complex of points, segments andtriangles (figure 5 (b)). Points are denoted with numbers, segments with lower case and

s(b)

operations,

(a \ e

Figure 5. (a) Two intersecting squares as model for topologicalrepresentation as a simplicial complex.

0

(b) and their

Page 8: Modelling spatial relations and operations with …homepage.univie.ac.at/.../Kainz_Egenhofer_Greasley_1993.pdfordered sets (posets), a moder that is generai;;"Gil;;;Jlspat,ar as partially

222 W. Kainz et al.

triangles with upper case characters. Notice that the triangles form a partition over theintersecting squares. The elements of the partition (triangles) form building blocks outof which the higher level objects (areas) are built. This is an important fact which isuseful in the spatial intersection operation.

This model can be used to extend our definition of spatial inclusion by defining therelations betv.'een the elements of the simplicial complex such that:

-- if the point p is an end point of the segment s, then p { s, and- if the segment s is an edge of the triangle t, then s < t.

The simplices (points, segments, triangles) and areas define a poset (figure 6 (o)) whichcan be completed to a lattice (figure 6 (b)). This lattice will be used to demonstrateexamples of topological operations on the lattice structure.

The toplogical relationships between the simplices of the complex can now beexpressed as order relations in the poset:

- Two points, p, and p2,can share only one segment, which is prv pr.- Two segments, s, and s2, coo share only one point, which is s1 n s2.- Two segments, s, and s2, coo share only one triangle, which is sl v s2.- Two triangles, t , and t r, can share only one segment, or one point, both of which

i s t , n t r .

(b)

Figure 6. (a) Poset of the simplices of two intersecting squares, and (b) its normal completion.

\ a )

The fac,lead tocompletpossiblr

4.2. IntProposilower b

Proof.simplexBut thiscannotintersecwould tThis nregreateslelemenl

Figure 'operatishadedelement

4.3. BoThe

differensimplic

Figure

Page 9: Modelling spatial relations and operations with …homepage.univie.ac.at/.../Kainz_Egenhofer_Greasley_1993.pdfordered sets (posets), a moder that is generai;;"Gil;;;Jlspat,ar as partially

t over thelocks outwhich is

ining the

z)) whichronstrate

now be

2 '

1 .

of which

:letion

Operations with partially ordered sets . / .L)

The fact that the point-segment-triangle part of the poset is already lattice-like mightlead to the conclusion that the points and segments can be left out of the normalcompletion process. Greasley (1990) showed, however, that in general this is notpossible and that all simplices must be included in the completion process.

4.2. IntersectionProposition 4.1 . The intersection of the elements of a set ,4 is calculated as the greatestlower bound of ,4.

Proof. If the greatest lower bound was larger than the intersection, then at least onesimplex of the partition would not be contained in every element of the set of areas A.But this is not the greatest lower bound of ,4. This means that the greatest lower boundcannot be larger than the intersection. If the greatest lower bound was smaller than theintersection, then at least one simplex of the partition that is in all areas of the set ,4would not be in the greatest lower bound. But this cannot be the greatest lower bound.This nreans that the greatest lower bound cannot be smaller than the intersection. If thegreatest lower bound of A can be neither smaller nor larger than the intersection of theelements of ,4 then it must be equal to the intersection of the elements of ,4. n

Figure 7 (a) shows the intersection of X and Y and figure 7 (b) shows the correspondingoperation on the Hasse diagram of the lattice, i.e., intersection (X,n:X n X Theshaded element Z is the greatest lower bound and, therefore, the intersection of theelements X and Y.

4.3. BoundaryThe boundary of an area A can be determined by calculating the symmetric

difference A of the elements that are covered by all the triangles of A, i.e., if C, is asimpliciaf 2-complex, then boundary (C ,): L((C r) ,) ,.

(b\

F igureT. (a ) In te rsec t ionof twosquares X and\and(b) thecor respond ingopera t ion in thelattice.

Page 10: Modelling spatial relations and operations with …homepage.univie.ac.at/.../Kainz_Egenhofer_Greasley_1993.pdfordered sets (posets), a moder that is generai;;"Gil;;;Jlspat,ar as partially

224 W. Kainz eI al.

(e)Figure 8. (c) Boundary of area Z, and (b) the corresponding operation in the lattice.

The dark lines in figure 8 (a) show the boundary of the shaded area Z. Figure 8 (b)displays the Hasse diagram and the boundary operation on the lattice. Area Z is acomposition of the triangles E and F. The sets of elements that are covered by E and Fare {i, h,j} and \j, l ,k\, respectively. The symmetric difference of these sets is theboundary:

boundary (Z) : { i ,h , j }LU, l ,k l : l i ,h , t ,k l l

4.4. NeighbourhoodThe neighbourhood of an area A can be defined as all the triangles that share a

segment with ,4: w(a )- , Va e triangles(,4). Let us call this neighbourhood operation oso that o(,4) is the segment-neighbourhood of l. We assume that A belongs to itsneighbourhood.

Figure 9 (a) i l lustrates this definit ion. Triangles -B and C each share a segment (thicklines) with the dark grey triangle.4. Figure 9(b) shows the Hasse diagram and theoperation on the lattice. The thick lines denote the search path. They lead from ,4 to theset {a,c ,d} , which is the cocover o l A. They then lead f rom {a,c,d} to the set o( ,4): , ,A ,8 ,C ) , wh i ch i s t he cove r o f { a , c ,d } .

The neighbourhood ofan area ,4 can also be defined as all the triangles that share apoint with A: w(((a -) -1-)- ,Ya e triangles(.4). Let us call this neighbourhood operationz so that n(A) is the point-neighbourhood of ,4. Again we assume that A belongs to itsneighbourhood. Figure l0 (a) illustrates this definition. Each of the grey triangles B, C,D and E shares a point (highlighted) with the dark grey triangle,4. Figure 10(b) showsthe Hasse diagram and the corresponding operation on the lattice. The thick l ines showthe search path. They lead f rom,4 to the set {a,c ,d} to the set 1,1,2,3} . {1,2,3} is thecocover of the cocover of ,4. They then lead f rom {1,2,3} to the set {a,b,c,d,e,a,h, i } tothe se t n (A ) : {A ,B ,C ,D ,E } , wh i ch i s t he cove r o f t he cove r o f { 1 ,2 ,3 } .

Notice that o(o(A))-n(A). This can easily be shown. Consider a regular triangulartessellation of the plane. For every triangle ,4 the segment-neighbourhood o(,4) canhave at the most four elements. o(o(A)) has at most ten elements, whereas zr(,4) hasthirteen elements.

Figure 9

Figure 1(

A n ,n"(A) ,udegreeThis ofinto acrhood. Iacross 1the san

Page 11: Modelling spatial relations and operations with …homepage.univie.ac.at/.../Kainz_Egenhofer_Greasley_1993.pdfordered sets (posets), a moder that is generai;;"Gil;;;Jlspat,ar as partially

lattice.

igure 8 (b): e a Z i s al E a n d I 'rets is the

rt share a)eratlon ongs to its

ent (thickr and ther .4 to ther set o(l)

tt share arperationngs to its

3les B, C,b)showsnes show3) is theg ,h , i I t o

iangularrlA) canr(,4) has

Operations with partially ordered sets 225

Figure 9. (a) Segment neighbours of triangle A, and (b) the corresponding operation in thelatttce.

(b\

Figure 10. (a) Point neighbours oftriangle ,4, and (b) the corresponding operation in the lattice.

A neighbourhood operation can be performed several times for an area, written asz'(l), where n is the number of times the operation is to be applied. The factor n is thedegree of neighbourhood including neighbours that are farther away as n increases.This of course is not the ultimate definit ion of neighbourhood. It does, however, takeinto account the information density, which influences our perception of neighbour-hood. It does not take into account the actual terrain. The town over the mountain oracross the river may not be as close a neighbour as the town down the valley or downthe same bank of the r iver .

Page 12: Modelling spatial relations and operations with …homepage.univie.ac.at/.../Kainz_Egenhofer_Greasley_1993.pdfordered sets (posets), a moder that is generai;;"Gil;;;Jlspat,ar as partially

226 W. Kainz et al

4.5. TouchThe spatial relationship touch(Egenhofer and Franzosa 1991)can be derived from

the set intersection, which was calculated with the greatest lower bound (see $ 4.2). If thegreatest lower bound is a triangle or a set of triangles then the two areas intersect. If thegreatest lower bound is a segment, a point, or a set of segments and/or points then thetwo areas touch. Notice that by this approach it is also possible to determine how thetwo areas touch. Figure l1 (a) shows an example of this operation and figure 1l (b)shows how the operation is performed in the lattice. Element 8 is the greatest lowerboundofthetwoelements Z andJ,andrepresentsthepointwhere arcaZ andtriangleJ touch.

4.6. Contt,As sho

i .e. , contu iareas thcldetermine(figurc l2 (

and X.

5. ConclrIn th is

based onspatial retrthat the hquestionsmore genupper borand norncharactertopologiccontainm

Latticbe tweencomplex.wi thoutaddi t ion,

Havi rtheore ticspatial qranothcr rinteriorsdo not, t lrepresenlthen we Iquery citIind thecorrcspo

O n c ,Dedekinlattice. Sthousan<approacJof thesecharactewhethercompletialgorithr

Figure 1 1. (a) Two areas Z and J touch in a point, and (b)lattice.

(b)

the corresponding operation in the

Figure l2. (c) The only elements that contain both B andthe operation of containment of B and F and

(b)

F are X and the whole area, and (b)U and X in the lattice.

Page 13: Modelling spatial relations and operations with …homepage.univie.ac.at/.../Kainz_Egenhofer_Greasley_1993.pdfordered sets (posets), a moder that is generai;;"Gil;;;Jlspat,ar as partially

erived fromr$ 4.2). If theersect. If thents then theine how thefigure 1 1 (b)ratest lowerrnd triangle

'ation in the

rea, and (b)

Operatktns with partially ordered sets 227

4.6. ContainmentAs shown in $ 3.1 the upper bounds of a given set determine the containing areas,

i .e . , contu iners ( {A,B}) : lA,B}* . F igure l2(a) shows the t r iangles B and F and theareas thcy are contained in. In order to find these areas in the lattice we have todetermine all upper bounds of the set of elements {8, } '} which gives {8, F }* : { U, X }(figurc 12(h)). lt follows that the only arcas that contain both trianglcs B and F are Uand X.

5. ConclusionsIn this article we have presented a framework for relations between spatial objects

based on the theory of ordered sets. It was demonstrated that relationships betweenspatial regions can be interpreted as order relations in posets and lattices. We have seenthat the hierarchical model of a subdivision of land is not gencral enough to answcrquestions relating to the containment of spatial regions and should be replaced by themore general approach of partially ordered sets. The operations of cover, cocover,upper bounds, lower bounds, least upper bound, greatest lower bound, direct product,and normal completion of posets are not only useful in determining areas with specificcharacteristics and to model spatial overlay, but also provide tools to calculatetopological operations of intersection, boundary, neighbourhood, touch, and spatialcontainment.

Lattices can be used as a high-level model for spatial regions and the relationsbetween them, built on the topological representation of these areas as a simplicialcomplex. Some queries can then already be answered by simple lattice operationswithout having to pcrform topological operations or geometric calculations. Inaddition, the lattice representation is also a model for topological operations.

Having both ways to represent spatial relations the topological and the orderthcoretic approach allows us to look for the most efficient model to answer certainspatial queries. If, for instance, we want to know whether a given region is contained inanother one, we can choose the topological model and look at the intersections of theinteriors and boundaries of both regions. If the interiors intersect and the boundariesdo not, then we know that one area is inside the other. We may also look into a posetreprescntation ofthe regions and check whether both areas are comparable. Ifthey are,then we know that one area is contained in the other. What we have done is to map aquery cithcr to the category oftopological spaces or to the category ofordered sets andfind the answer in the respective model. This can be done, because there is acorrespondence between the topological and the poset model of spatial regions.

One of the crucial parts of the poset model is the normal completion. The classicalDedekind-MacNeille procedure uses the powerset for the completion of a poset to alattice. Since real world posets of spatial regions usually consist of hundreds or eventhousands of clements the classical algorithm cannot be applied. Although alternateapproaches have been proposed (Perry 1990) a thorough analysis and implementationof these algorithms is sti l l missing. It might also be worthwhile to look into thecharacteristics of posets and lattices representing spatial subdivisions to find outwhether certain types of lattices can be identif ied. This could influence the normalcompletion process and allow for the design of tailored, efficient normal completionalgorithms.

Page 14: Modelling spatial relations and operations with …homepage.univie.ac.at/.../Kainz_Egenhofer_Greasley_1993.pdfordered sets (posets), a moder that is generai;;"Gil;;;Jlspat,ar as partially

228 W. Kainz et al.

Acknowledgments

Andrew Frank. Alan Saalfeld, and Bob Franzosa st irnulated the research with

valuable comments and discussions. Their help and support are grateful ly acknowled-

ged. This work was part ial ly supportcd by grants frorn the [J.S. Bureau of the Census

under joint stat ist ical agreements U7 1l and l l9 33. Addit ional support came from

Intergraph Corporation and from the National Sciencc Foundation lor the National

Centc r fo r Geograph ic In fo rmat ion and Ana lys is under g ran t number SES-88-109 17 .

References

BIRxntrrr, G., 196'7, Latt ice Theorv. American Mathematical Socicty Colloquium Publications,25 (Providence, RI: American Mathematical Society).

Cuenlw<;ou, G., MtxrN, G., and Tut.tp, J., 1987, Developing a DBMS for gcographicinformation: a review. Proceedinqs Auto Carto 8, I lal t imore, cditcd by N. R. Chrisman(Falls Church, VA: American Society for Photogrammetry and Remote Sensing andAmerican Congress on Surveying and Mapping), pp.302 315.

Ctxutl l l r , J. P.,1979, Topological Principlcs in Cartography. Tcchnical Papcr,48, US Bureau ofthe Census, Washington, DC.

Dnvrv, B. A., and Pnrnsl lr .v, H. A., 1990, Intodut ' t ion to Lutt i t 'es untl Order (Cambridge:Cambridge University Press).

EcrNHrxnn, M. J., FneNx, A. tJ., and Jrcrs<lx, J. P., 1990, A topological data model for spatialdatabases. ln Desiqn antl Implementation ol Lurqe Sputial Dutttbuses, edited byA. Buchmann, O. Giinther, T. Smith and Y. Wang, Lccturc Notcs in Computer Science,409 (New York: Springer-Verlag).

Ec;tNHtxnn, M. J., and FnrNzt.rsr, R. D., 1991. Point-set topological spatial relat ions.Internutionul Journal ol Geouruphit 'al Inlormation Slsrcms.5, l6l 174.

Fn'rNx, A. U., and KuHr, W., 1986, Cell graphs: a provable correct method for the storage ofgeometry. Proteedinl ls Setonti lnternutionul SJ,ntposiunr on Sputiul Dutu Hurdl int l , Seutt le,l /21 (Wil l iamsvi l le, NY: International Geographical [Jnion, Commission on GeographicalData Sensing and Processing), pp.4l l 436.

GxAIzt,n, G., 1978. General Lutt ice Theor-,- (New York, NY: Academic Press).( in resnry ,1 . , l98 i l , Data s t ruc tu res to o rgan ize spat ia l subd iv is ions . ' fechn ica l Pupers 1988

AC S M - AS P RS A nnua l C o nre nt ktn. S t. Loui s, M O, ( F al ls C hu r c h, VA : A mer i t :un Soc ie t v lb rPhotogramrnetrv urul Remot.e Sensinq and Amcritan Conpress tnr Surrc):itru und Mappina),6. r39 148.

GRrasr.rv, I . , 1990. Part ial ly ordered sets and latt ices: correct models of spatial relat ions for landinformation systems. Master 's Thesis. [Jniversity of Maine, Department of SurveyingEngincering, Orono. M E.

Hr,nnrN<;, J. R., 1987, TIGRIS: topological ly integrated geographic information system.Proceedingls Auto Corto, l , Balt imore, edited by N. R. Clhrisnran (Fal ls Church, VA:American Society for Photogrammetry and Renrote Sensing antl American Congress onS u r v e r i n g a n d M a p p i n g t . p p . 2 8 2 2 9 l .

Hrnnr^-r; , J. R., 1991, The malhematical modeling of spatial and non-spatial information ingeographic information systems. ln Cognit iue and Linguist i t ' Aspet ' ts ol Geoglraphic Space,cditcd by D. Mark and A. F rank (Dordrecht: Kluwcr Academic Publishers), pp. 313 350.

KerNz, W., 1988, Application of latt ice theory in geography. Proceetl inqs'[ 'hird lnternationulSymposium on Spatial Datu Handlingl, Sydney", Austrul ia. edited by D. Marble (Columbus,OH: International Geographical Union. C--ommission on Geographical Data Sensing andProcessing), pp. 135 142.

Ka.rNz, W., 1989, Order. topology and metric in GlS. Technical Papers 1989 ,4SPRS-ACSMAnnual C'onuention (Fal ls Church, VA: American Society for Photogrammetry andRemotc Sensing and American Congress on Surveying and Mapping),4, pp. 154 160.

K,A.rxz, W., 1990, Spatial relat ionships topology versus order. Proteetl ings Fourth InternationalSymposium on Spatiul Data Handling, Zurich, SwitzerlunLl, edited by K. Brassel andH. Kishimoto (Columbus OH: International Geographical Union, Commission onGeographic Information Systems), 2, pp. 814 819.

Lrrr-scrnetz, S., 1975, Appli t :ut ions d Alqehruir: Topolog1y (New York: Springer-Verlag).

Me.cNstr-leSociet

Muxr-sn, IlgeogrAutoSensit

MonrHoustCarttand I

Newslr-, R.GIS.CongRemt

Prnnv, L. NMast

Prcor, S., 1,4CSMap1 0 , 3

Rossl.tusst-Spatling (

Slelnnlo,DC.

SeeLnnlu,.Was

Sealrglo,VA:o n S

WHIrr, M.ChuSurl

WnrrE, M.syst(

Wongclvs,S1'ntand2, Pj

Page 15: Modelling spatial relations and operations with …homepage.univie.ac.at/.../Kainz_Egenhofer_Greasley_1993.pdfordered sets (posets), a moder that is generai;;"Gil;;;Jlspat,ar as partially

Operations with partially ordered sets 229

earch withtcknowled-the Censuscame frome Nat ional; - 88 -10917 .

tubl icat ions,

gcographicl. ChrisrnanSensing and

fS Bureau of

Cambridgc:

:l for spatialeditcd by

ter Scicnce.

I relat ions.

: storagc ofinq. Serlttle.:ographical

'upers 19[18r Sotier v lbrI NI uppinul.

rns for land' Surveving

ln system.rurch. VA:onSress on

rmation inphic Sput e,o . 313 -150.ternutionul3o lumbus.ensrng anci

RS-,4CSMnetry and154 160.lernatbnulrassel andrission on

rg).

MecNRII-rn, H. M., 1937, Partially ordered sels. Transactions of the American MathematicalSociety. 42,90 96.

MErxr-En, D., and Sanlrrr.o, A., 1985, Storing, retr ieving and maintaining information ongeographic structures. A geographic tabulation unit base (GTUB) approach. ProceedingsAuto Carto 7 (Falls Church, VA: American Society for Photogrammetry and RemoteSensing and American Congress on Surveying and Mapping), pp.369 376.

M<xEHousn, S., 1985, Arc/Info: a geo-relational model for spatial information. Proceedings AutoCarto 7 (Falls Church, VA: American Society for Photogrammetry and Remote Sensingand American Congress on Surveying and Mapping), pp. 3gg 397.

Nr:well , R. G., EasrnnRrnln, M., and rnsnrrur-r, D. G., lggl, Integration of spatial objects in aGIS. Technical Papers 1991 ACSM-ASPRS Annuul Conuention(Bethesdi, MD: AmericanCongress on Surveying and Mapping and American Society for Photogrammetry andRemote Sensing), 6, Auto Carto 10,408 415.

Plnnv, L. M., 1990, Extending (finite) partially ordered sets to lattices: an incremental approach.Master's Thesis, University of Maine, Department of Mathematics, orono, M-E.

Ptcor, S., 1991, Topological models for 3D spatial information systems. Technical Paper 1991ACSM-ASPRS Annual Conuention (Bethesda, MD: American Congress on Surveying andMapping and American Society for Photogrammetry and Remote Sensing), 6, Aito -arto10,368-392.

Rosslrussl, H. J., and Rucc, R. D., 1991, The United States spatial data transfer standard. InSpatial Database Transfer Standards: Current lnternational Starus, edited by H. Moeller-ing (Amsterdam: Elsevier Applied Science).

Sanu-EI-o, A., 1983 a, Latt ice Building ( internal report), US Bureau of the Census, Washington,DC.

SaalFslo, A., 1983 b, Structuring a Poset/Latt ice Fi le ( internal report), US Bureau of the Census,Washington, DC.

Sreunro, A., 1985, Lattice structures in geography. Prr.tceedings Auto Carto 7 (Falls Church,VA: American Society for Photogrammetry and Remote Sensing and American Congresson Surveying and Mapping), pp.a82489.

Wsrrn, M. S., 1980, A survey of the mathematics of maps. Proceedingls Auto Carto IV (Fallschurch, vA: American Society for Photogrammetry and American congress onSurvey ing and Mapp ing) , 1 ,82 96 .

WslrE, M. S., 1984, Technical requirements and standards for a mult ipurpose geographic datasystem. The American Cartoglrapher, ll, 15 26.

Wonnovs, M., 1992, A model for spatio-temporal information. Proceedings 5th Internationalsymposium on spatial Data Handling, Charleston, sc, edited by p. Bresnahan, E. Corwin,and D. Cowen (Columbia, SC: International Geographical Union, Commission on GIS).2 . p p . 6 0 2 6 l l .