elastic / elasticsearch

Free and Open Source, Distributed, RESTful Search Engine
https://www.elastic.co/products/elasticsearch
Other
69.72k stars 24.67k forks source link

[DOCS] Clarify meaning of intersection and containment for spatial queries #70662

Open atombender opened 3 years ago

atombender commented 3 years ago

The terms "contains" and "intersects" are used in the documentation for geo_shape queries, but the terms are not defined.

What's unclear is if it containment and intersection operate on both the interior and boundary of shapes, or just the interior. From what I can tell from my testing, it's the latter; for example, it looks like a polygon can never intersect or contain itself.

Having the operations defined in terms of OGC's DE-9IM predicate matrix would be helpful. As far as I can see, WITHIN and CONTAINS do not conform to these definitions.

It's also not clear from the documentation whether spatial geo_shape queries use Cartesian (planar) operations or a spherical projection. From what I can tell, they use Cartesian coordinates.

elasticmachine commented 3 years ago

Pinging @elastic/es-docs (Team:Docs)

elasticmachine commented 3 years ago

Pinging @elastic/es-analytics-geo (Team:Analytics)

elasticsearchmachine commented 3 months ago

Pinging @elastic/es-analytical-engine (Team:Analytics)