Hi Min,
I am one of the editors of GeoSPARQL. GeoSPARQL doesn't directly address your interests. It is used to: * define spatial relations between Features or Geometries * define functions to calculate spatial relations between Features or Geometries * define multiple Geometry representations, like WKT & GeoJSON What you want to do involves distances between nodes (Features). You could use GeoSPARQL to store the base that from which you calculate distance between Features (see the geof:distance property [1]) but then you will need other logic to calculate shortest paths made up of many distances. I don't think you will get any benefit from RDF-Star here since edge distance calculations can be accomplished in ordinary RDF. You will need to look into algorithms such as those proposed by Simon Bin below. You might find that such algorithms have been implemented in Jena for use with RDF data. If not, you could implement such a thing, based on Dijkstra's algorithm, as you indicated! Regards, Nick [1] https://opengeospatial.github.io/ogc-geosparql/geosparql11/spec.html#_function_geofdistance ------- Original Message ------- On Saturday, March 25th, 2023 at 05:36, Simon Bin <[email protected]> wrote: > Maybe you can take a look at https://www.graphhopper.com/open-source/ > or https://project-osrm.org/ > > On Fri, 2023-03-24 at 18:30 +0100, Yang-Min KIM wrote: > > > Dear Jena community, > > > > I would like to use GeoSPARQL, but before I proceed I need your > > valuable advice. > > > > What I want to do: > > - Using GeoSPARQL, nodes have their own position (or zone). > > - Graph is weighted: edge has a value > > - Find the shortest path between nodes in a weighted graph > > > > For instance, there is Dijkstra's algorithm allowing to find the > > shortest paths considering weighted edges. > > https://en.wikipedia.org/wiki/Dijkstra's_algorithm > > > > Here are my questions as a beginner: > > 1. What is the best way to integrate a weighted graph in Jena? > > 2. Maybe RDF* (RDF-star)? Is it compatible with GeoSPARQL? > > 3. How can we find a shortest path considering edge values? > > > > Thank you for your time and have a great weekend. > > > > Min
