Description
Use Case ONTO21
Maximum Distance
As a GeoSPARQL data user I would like to measure the maximum distance between two geometries - distance between their farthest points.
If geometries are the same, the function will return the longest distance between the two farthest points in this geometry.
Distance is measured in the units of the spatial reference system.
For the POLYGON ((0 1 0, 1 1 0, 1 0 0, 0 0 0, 0 1 0))
and the POLYGON ((2 3 0, 2 2 0, 3 2 0, 4 3 0, 2 3 0))
the value is 5.
Function signature:
maximumDistance(geometry: ogc:geomLiteral, geometry: ogc:geomLiteral): xsd:double
Actor: GeoSPARQL data user (human or software agent querying RDF dataset with GeoSPARQL)
Preconditions
Features and Geometries with 2D and 3D representations are present in a dataset to be queried. The maximum distance function is discoverable.
Postconditions
A SPARQL query can be executed that includes a function to return maximum from a given geometry to another given geometry - distance between their farthest points. The results of the query are known to be true or false in 2D and 3D.
Steps
Actor: discovers maximum distance function implemented by the system
Actor: executes a SPARQL query containing maximum distance function with two geometries as arguments.
System: returns a SPARQL result with a maximum distance between geometries - distance between their farthest points.
Activity