1

enter image description here

A polyline layer's (green) length is being calculated via $length. Result: ~100 meters (EPSG 31466).

A buffer of 5meters is created and via Voronoi Polygons (and several other steps) a centerline is created (red). Result: ~ 200 meters (EPSG 31466).

That simply makes no sense at all if you look at the screenshot. It rather should be arround 110 meters, estimated visually. I tried merging all segments but the result stays about the same.

The background behind this situation is a sum length completeness comparism of two road networks. Because of many withstanding end pieces I want to calculate a factor I can use to divide a total network length with in order to correct the centerline length.

  • 1
    Please edit the question to contain a vertex dump of the geometries in question. – Vince May 8 '16 at 21:29
  • 1
    The length of a line is its length in one direction from start to end, length for a polygon is its perimeter, given that it's a buffer of the line it would go start-end-start of the line with a little more for width so I would expect it to be slightly more than double the line length. As @Vince alludes to the centreline probably doubles back. – Michael Stimson May 8 '16 at 21:52
  • how to export a vertex dump in qgis? – Revo May 9 '16 at 6:14
  • to explain the way the centerline is created: 1. buffer polyline 2. dissolve polygon 3. polygon to polyline 4. place regular points on polylines 5. voronoi polygons on points 6. polygons to polylines 7. explode lines 8. select segments within native buffer 9. extract as centerline – Revo May 9 '16 at 6:15

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.