Principle
The quadtree is an effective two-dimensional Spatial Index. Its basic idea is as follows: the whole Workspace is coded as 0, and the horizontal line and the vertical line are used to divide the Workspace into four equal parts. Each part is coded as 00, 01, 02 and 03 in sequence, with the upper left corner as 00 and the lower right corner as 03; The divided grid is divided in the same way, for example, the grid 00 is divided, and the four small grids after division are respectively coded as 000, 001, 002 and 003. If necessary, the division can be continued. For example, the 031 grid can be divided into 0310, 0311, 0312 and 0313, as shown in the following figure. By analogy, the division can be continued, with the number of layers depending on the number and average size of the objects in the study area.
Figure: Quadtree tessellation |
Assuming that the object shown in the above figure is the spatial object contained in the whole Dataset, the quadtree structure established based on this is shown in the following figure:
Figure: Q-tree Index |
Applicable conditions
Q-tree Index is suitable for high-concurrency editing with small data volume.
supporting the establishment of Q-tree Index include SQLPlus, OraclePlus, KingBase, and MySQL.