Spatial Data Structure
Domain: Data Structures
π― Motivation
When data has location (coordinates on a map, 3D objects in a game), spatial structures organise it by position for fast geographic queries.
π Concrete Example
A quadtree divides a 2D map into four quadrants, recursively. βFind all restaurants within 1 kmβ becomes checking only the relevant quadrants.
π Analogy
A city divided into districts, each divided into blocks, each into buildings. Finding a restaurant nearby means checking only your district, not the entire city.