13.4 Spatial Query

a. Types of spatial query
Spatial query is a search of the data to satisfy a given condition. There are two types of spatial query.

(1) Query of attribute data
A spatial distribution or an area will be searched with respect to a given attribute of interest.

(2) Query of geometric data
With a given geometric condition for example location, shape or intersection, all data that satisfy the condition will be searched. In the case of a vector data form, to search an area which includes a given point, and to find all line segments which intersect a given line would be a typical query of geometric data.

In the case of raster form of data, it will be easier to search any attribute and geometric data based on a given grid.

Figure 13.4.1 shows an example of a query of attribute data in the aster form, in which the areas with slope gradient of greater than 30 degrees are located.

Figure 13.4.2 shows an example of a query of geometric data in which the area was searched that includes a point, as given by a cursor.

b. Data Structure for High Speed Query
It is important to develop a data structure which allows for high speed query, because the data volume is usually very huge.

For example, in order to search all points which are included in an area, it is necessary to check many points whether those points are included in the area or not.

Tree structure and block structure are typical data structures used to save time of query. Figure 13.4.3 shows the block structure for solving a point-in-polygon problem, where only the block that includes a polygon should be checked and searched instead of all other blocks.

The Quadtree structure has been proposed and used not only for high speed query but also for data compression.


Copyright © 1996 Japan Association of Remote Sensing All rights reserved