Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use Case ONTO21: Maximum Distance #578

Open
ar-chad opened this issue Oct 30, 2024 · 1 comment
Open

Use Case ONTO21: Maximum Distance #578

ar-chad opened this issue Oct 30, 2024 · 1 comment

Comments

@ar-chad
Copy link
Collaborator

ar-chad commented Oct 30, 2024

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.

@aothms
Copy link

aothms commented Nov 6, 2024

Maybe it would also be beneficial to know where on the input geometries this distance is realized. So maybe the API could also return a line segment that connects input A to B. If you only want the length you get the length of that line segment. If you want to know more about the points on the input geometries, you inspect the points of that segment.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants