2.2 A Global, Regular, Hierarchical Spatial Data Model
In place of latitudes, longitudes and metadata, we propose a notation for location that documents its own precision, one which can model spatial and scale relationships as well as denoting positions. Data in this form can be derived from coordinates plus scale or accuracy information, and is thus compatible with existing digital georeferenced data. Once so encoded, positions can be retrieved at a wide range of precision, i.e. at specific scales or resolutions. Locations neighboring a given one can be directly identified at any resolution. Every point on the planet has its own unique hierarchical geocode, accurate to the extent its location can or needs to be measured. Our notation uses integer identifiers rather than floating-point coordinates, and at first sight do not appear to be coordinates at all. But they directly denote position, and do so at multiple, nested resolutions. This is why we refer to it as a hierarchical coordinate system, the form and orientation of which is described by figures 2.2 and 2.3
Figure 2.2: Quaternary Triangular Mesh to Three Levels of Detail
These properties are achieved through the use of a geometric computational model that, starting with an octahedron we imagine to be embedded in the Earth, subdivides its eight faces into four each, proceeding to recursively subdivide each of the 32 resulting triangular facets (also called quadrants) into four children. The basic geometry and topology of this hierarchical model are illustrated in figure 2.3. While all facets can be subdivided in the same way, in practice this is not done everywhere, but only where one has point positions to encode. Each such location is identified by a sequence of quaternary digits (from 0 to 3), having as many places as the number of times facets were divided in representing that point. We call each of these places a level, as it is equivalent to a certain level of spatial resolution. Our implementation allows for 29 levels of detail (in a 64-bit word), corresponding to about 2 cm of ground resolution, or to maps at a scale of 1:50 or larger. This should suffice for nearly all cartographic and analytic purposes.
Figure 2.3: Form and orientation of the Quaternary Triangular Mesh
Detailed images of this structure are difficult to render properly, due to the great number of subdivisions that quickly accumulate. But many of its hierarchical properties are readily summarized numerically; table 2.1 presents the major ones. In that table, the third column refers to the number of subdivisions in an octant (an eighth of the earth); the Linear Divisions column likewise specifies how many times an octant’s edges are subdivided at each level. Dividing that number into one quarter of the earth’s circumference (10,000 km) yields the average length of a facet edge, labelled Linear Extent. Since these lengths do vary (by up to 35%, as section 3.1.1 shows) they are presented as round numbers and scaled to be easier to comprehend. The last two columns present a loose equivalence between spatial resolution and map scale. This correspondence is based on an (arguable) assumption that the positions of points on a printed map are accurate to within 0.4 mm (Tobler 1988). This exceeds U.S. national map accuracy standards (see section 1.3), but is still coarser than some line weights on topographic maps. The Scale Denominator is computed by dividing Linear Extent (in mm) by 0.4 mm. Simplifying further, this is rounded to a whole number in the Standard Scales column.
QTM
|
ID
|
OCTANT
|
QUADRANT
|
UNIT
|
LINEAR
|
LINEAR
|
UN
|
SCALE
|
STANDARD
|
LEVEL
|
BITS
|
QUADRANTS
|
AVG. AREA
|
|
DIVISIONS
|
EXTENT
|
IT
|
DENOM.
|
SCALES
|
1
|
6
|
4
|
16,120,936
|
kmsq
|
2
|
5,000
|
km
|
1.00E+10
|
|
2
|
8
|
16
|
4,030,234
|
kmsq
|
4
|
2,500
|
km
|
5.00E+09
|
|
3
|
10
|
64
|
1,007,559
|
kmsq
|
8
|
1,250
|
km
|
2.50E+09
|
|
4
|
12
|
256
|
251,890
|
kmsq
|
16
|
625
|
km
|
1.25E+09
|
|
5
|
14
|
1,024
|
62,972
|
kmsq
|
32
|
313
|
km
|
6.25E+08
|
|
6
|
16
|
4,096
|
15,743
|
kmsq
|
64
|
156
|
km
|
3.13E+08
|
|
7
|
18
|
16,384
|
3,936
|
kmsq
|
128
|
78
|
km
|
1.56E+08
|
|
8
|
20
|
65,536
|
984
|
kmsq
|
256
|
39
|
km
|
7.81E+07
|
1:100,000,000
|
9
|
22
|
262,144
|
246
|
kmsq
|
512
|
20
|
km
|
3.91E+07
|
1:50,000,000
|
10
|
24
|
1,048,576
|
61
|
kmsq
|
1,024
|
10
|
km
|
1.95E+07
|
1:20,000,000
|
11
|
26
|
4,194,304
|
15
|
kmsq
|
2,048
|
5
|
km
|
9.77E+06
|
1:10,000,000
|
12
|
28
|
16,777,216
|
4
|
kmsq
|
4,096
|
2
|
km
|
4.88E+06
|
1:5,000,000
|
13
|
30
|
67,108,864
|
960,883
|
msq
|
8,192
|
1
|
km
|
2.44E+06
|
1:2,000,000
|
14
|
32
|
268,435,456
|
240,221
|
msq
|
16,384
|
610
|
m
|
1.22E+06
|
1:1,000,000
|
15
|
34
|
1,073,741,824
|
60,055
|
msq
|
32,768
|
305
|
m
|
6.10E+05
|
1:500,000
|
16
|
36
|
4,294,967,296
|
15,014
|
msq
|
65,536
|
153
|
m
|
3.05E+05
|
1:250,000
|
17
|
38
|
1.717987E+10
|
3,753
|
msq
|
131,072
|
76
|
m
|
1.53E+05
|
1:100,000
|
18
|
40
|
6.871948E+10
|
938
|
msq
|
262,144
|
38
|
m
|
7.63E+04
|
1:62,500
|
19
|
42
|
2.748779E+11
|
235
|
msq
|
524,288
|
19
|
m
|
3.81E+04
|
1:50,000
|
20
|
44
|
1.099512E+12
|
59
|
msq
|
1,048,576
|
10
|
m
|
1.91E+04
|
1:25000
|
21
|
46
|
4.398047E+12
|
15
|
msq
|
2,097,152
|
5
|
m
|
9.54E+03
|
1:10000
|
22
|
48
|
1.759219E+13
|
4
|
msq
|
4,194,304
|
2
|
m
|
4.77E+03
|
1:5000
|
23
|
50
|
7.036874E+13
|
1
|
msq
|
8,388,608
|
1
|
m
|
2.38E+03
|
1:2500
|
24
|
52
|
2.814750E+14
|
2,291
|
cmsq
|
16,777,216
|
60
|
cm
|
1.19E+03
|
1:1000
|
25
|
54
|
1.125900E+15
|
573
|
cmsq
|
33,554,432
|
30
|
cm
|
5.96E+02
|
1:500
|
26
|
56
|
4.503600E+15
|
143
|
cmsq
|
67,108,864
|
15
|
cm
|
2.98E+02
|
1:300
|
27
|
58
|
1.801440E+16
|
36
|
cmsq
|
134,217,728
|
7
|
cm
|
1.49E+02
|
1:150
|
28
|
60
|
7.205759E+16
|
9
|
cmsq
|
268,435,456
|
4
|
cm
|
7.45E+01
|
1:75
|
29
|
62
|
2.882304E+17
|
2
|
cmsq
|
536,870,912
|
2
|
cm
|
3.73E+01
|
1:40
|
30
|
64
|
1.152922E+18
|
1
|
cmsq
|
1,073,741,824
|
1
|
cm
|
1.86E+01
|
1:20
|
Table 2.1: Quaternary triangular mesh statistics for 30 levels of geometric detail
As space is recursively subdivided into four nearly similar units, we have, computationally speaking, a quadtree, or quaternary division of space. More precisely, they form a forest of eight region quadtrees, one for each octahedral face, or octant. Region quadtrees are but one of numerous variants of hierarchical space partitioning systems, but are perhaps the most widely used of them. In our approach, however, as vertices (point locations) are encoded (as opposed to line elements or polygons), we could also call the data structure a point quadtree. In Samet’s semi-official terminology, we could call our storage mechanism a PR Quadtree (P for point, R for region), as each leaf node is a region that is occupied by one and only one vertex (Samet 1990: 92).6 Further-more, rather than a rectangular division of space (which quadtrees almost always employ), we use a three-axis system; it is triangles (starting with a set of eight) that subdivide into four each. The edges of these triangles are aligned in a finite three-way mesh that extends around the planet and densifies where precision goes up. Hence the model’s name, Quaternary Triangular Mesh, or QTM7 for short.
2.2.1 Local and Global Properties
We orient the octahedron to the Earth by aligning its vertices with cardinal points — to the poles and at longitudes 0, 90, 180 and -90 degrees along the equator — and number the octants from 1 to 8, as defined by table 2.2. The triangular subdivisions of octants are identified by adding a quaternary digit (0, 1, 2 or 3) to a series of them built up in the course of fixing a location. Upon reaching a point's limit of precision the process stops, and the sequence of digits becomes the QTM address (a quadtree leaf node which we denote as QTM ID) of that point. Address digits are assigned to quadrants according to a method that always numbers the central one 0, but permutes the other three identifiers at each level. This method results in grouping six 1's, 2's or 3's around every grid node, reflected in the last digit of facets’ QTM IDs.8
An octahedron has three axes that connect poles, and three orthogonal “equators.” Our way of coding its facets yields 429 (2.88230...E17) child facets. Every facet is defined by three mesh nodes at which (with six exceptions) six facets meet. When a node lies on the edge of an octant, three of its incident facets lie in one octant's quadtree; the other three are stored in an adjoining one. A similar relation holds true for any node, not just those along the edges of octants; facets incident at a node are cousins, not siblings, and relating objects that span them can be awkward in quadtrees. Because they relate quadrants in different trees and sub-trees, nodes play a critical role in the QTM framework, and are important enough to warrant the special name Attractor.9 For many purposes, attractors are as important for retrieving locational data as QTM addresses are for encoding them. Properties and uses of attractors will be examined in detail in following chapters.
Octant Minimum Maximum Minimum Maximum
ID Longitude Longitude Latitude Latitude
1 0 < 90 > 0 90
2 90 <180 > 0 90
3 180 <270 > 0 90
4 270 <360 > 0 90
5 0 < 90 -90 0
6 90 <180 -90 0
7 180 <270 -90 0
8 270 <360 -90 0
Table 2.2: Orientation of the QTM basis octahedron to the earth
In describing QTM, we have so far stressed its global properties, as these are what qualify it as a (hierarchical) coordinate system suitable for encoding geographic data. Based on this overview, some readers might assume that QTM is only intended to handle geospatial data which spans the globe, such as world climatalogical, bioregional or demographic statistics. In the large, QTM can certainly support such world-wide applications, but only because it also works in the small, and throughout a range of scales. In this project we have deliberately focused on the small end of this continuum, but not simply to avoid grappling with global datasets, which would tax our processing platforms without adding much explanatory value; we have done this to explore essential details of hierarchical data handling that are critical to understand, regardless of the scope of one’s spatial data and their application.
360>270>180>360>270>180>
Share with your friends: |