Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Overview
Artifact ID: | ca0e52bba6eefb7fdde271847dcf518d219c5efd |
---|---|
Page Name: | VirtualRouting |
Date: | 2018-03-22 17:41:42 |
Original User: | sandro |
Next | c22f4645ee5e82326ecc4ce2102752b686bb9170 |
Content
Introduction
Previous versions of SpatiaLite traditionally supported a pure SQL routing module that was named VirtualNetwork.Since version 5.0.0 a brand new routing module (more advanced and sophisticated) is now available, that is named VirtualRouting.
The nowadays obsolete VirtualNetwork still continues to be supported by version 5.0.0 so to not cause an abrupt break to already existing applications, but will be presumably suppressed in future versions.
Using VirtualRouting instead of VirtualNetwirk is warmly reccommended for any new development.
Teoretical foundations - an ultra-quick recall
All Routing algorithms (aka Shortest Path algorithms) are based on the mathematics of the Graph theory and more precisely on Weighted Graphs.A topologically valid Network is a dataset fullfilling the following requirements:
- All items in the dataset are called Links (aks Arcs), and are expected to represent some oriented conection joining two Nodes.
- So all Links are always expected to explicitly reference a Start-Node (aks Node-From) and an End-Node (aka Node-To).
The Start- and End-Node could eventually be the same, and in this case we'll have a self-closed Link.
Network's Links can eventually define a linear Geometry (LINESTRING) going from the Start-Node to the End-Node, but this is an optional feature, not a mandatory requirement.
What is absolutely mandatory is that each Link must explicitly reference its Nodes. - A Network supporting Geometries is a Spatial Network; otherwise a Network lacking any geometry is a Logical Network.
In a Spatial Network all Links must have a corresponding Geometry.
In a Logical Network all Links are strictly forbidden to have any geometry. - In a Spatial Network both the StartPoint and EndPoint of each Link's LINESTING are always expected to exactly coincide with the corresponding Nodes.
- All references to the same Node by different Links must exactly coincide.