Presentation is loading. Please wait.

Presentation is loading. Please wait.

Spatial Database 2/5/2011 Reference – Ramakrishna Gerhke and Silbershatz.

Similar presentations


Presentation on theme: "Spatial Database 2/5/2011 Reference – Ramakrishna Gerhke and Silbershatz."— Presentation transcript:

1 Spatial Database 2/5/2011 Reference – Ramakrishna Gerhke and Silbershatz

2 Spatial Data Any data that occupies space in a spacial world is spatial data – Types Point Data – characterized only by its location and has not boundary Region Data – characterized by a centre and a boundary

3 Spatial Applications Image data – Medical images like MRI scans – either transformed to lesser dimensions using image tranformation functions like hough function – or used directly as colors of locations Geographic Information Systems (GIS) – To store roads and rivers as lines and buildings or landscapes as polygons CAD/CAM Application – To store surfaces of modeling objects using wire mesh polygons Effective indexing and nearest neighbor querying for numerical data

4 Querying Capabilities Nearest Neighbor Queries – Find the first five close restaurants to my house – E.g., find all hotels within 100 metres from my house Spatial Range Queries – Find all roads passing through a given region in map – Find all houses contained in a specific locality marked in the map using boundaries Spatial Join Queries – Find all medical shops which are within about 10metres radius from the nearest hospital.

5 Indexing Schemes Spatial Curve Indexing – Z-Order Indexing – Hilbert Curve Indexing Grid File Indexing R Tree Indexing

6 Spatial Curve Filling The spatial curve filling approach orders the data using an z-value computed from the actual data represented in a bitmap The z- value is computed as follows – Calculate the bitmapped value of the data point in the given space – Interleave the bits from several dimensions and obtain a new binary value – The decimal equivalent of the re-arranged bits is called the z-value – The z-value is indexed using B+Tree – The z-value ordering captures the spatial closeness of the represented data well

7 2 bit Z-ordering

8 Hilbert Curve

9 Grid Indexing Creating a grid directory the data stored in pages Add the location of data to the grid cell entries Addr1 Addr3 Addr1 Addr3 Addr2 Addr4 Scale 1 Scale 2 Addr1 Addr2 Addr3 Addr4 Addr5 Grid Directory More than one cell pointed to the same space

10

11 R-Tree Stores Region Mostly answers range queries and join trees It is an extension of B+Trees Mark all regions in the space as a bounding rectangle A bounding rectangle is the smallest rectangle that encloses an object A B C D E

12 R-Trees Partition the rectangle boxes using split operation Insert the boundaries in a B_Tree If the page is full split a bounding box and create the new split up nodes A B C D E

13


Download ppt "Spatial Database 2/5/2011 Reference – Ramakrishna Gerhke and Silbershatz."

Similar presentations


Ads by Google