Map Technical Notes
These notes provide a brief description of the data and tools used to produce
the walks/travel map shown in Walks Map
- Data. The data has been collected using GPSlogger on an android
phone. To make best use of this tool and avoid the generation of too
many spurious data-points, it is useful to configure the logger to record
only points with an error < 40m, and to inhibit recording of points when the
phone has not been moved (e.g. when stopped for lunch). Typically
a 30s update has been used since the walking speed is low.
- Data has been preprocssed to merge any track segments that may be
present. Large files have been filtered to reduce the number of data
points. This has been done using either Garmin Basecamp or GPSbabel.
- The GPX files have been assembled into a set of subfolders, one per trail,
in a ./gpx folder, eg ./gpx/Harcamlow/20160802.gpx. This single ./gpx
folder represents a simple data archive from which the page is generated.
- The map is generated using leaflet.js.
- The track overlays are generated using the leaflet plugin leaflet-gpx.
- Simple PHP code is used to get the trail names (subfolder names)
and the gpx filenames per trail.
- All gpx files in a trail are grouped into a featureLayer and a map
overlay control added to support views of selected trail(s).
- The leaflet-gpx tool provides mechanism to get the date, length
(and other parameters) from the gpx files. These are used to
generate a summary table.
- The leaflet-gpx tool generates a 3d track length which includes
differences in height. For this data the elevation is very noisy
and the 3d track length is unreasonably large. The gpx.js has been
modified to return the 2d (flat) distance instead of the 3d distance.
- utrack provides an on-line tool which
computes the flat and total distance from a gpx file.
Measurement of Distance Travelled
The calculation of diatance travlled from a GPX file is computed is
many different ways by different tools. The measurements made
from one file (20150728.gpx harcamlow) are (November 2016, km):
| Garmin Basecamp: || 41.4
| Google earth, length: || 46.6|
| Google earth, ‘range total’: || 39|
| Leaflet-GPX default (3d): || 46.55|
| Leaflet-GPX 2d: || 41.31|
|uTrack flat distance: || 41.3 |
|uTrack real distance: || 46.5|
So main difference is from ‘flat’ or ‘sloping’ distances.
Since elevation is very noisy in most gpx measurements, the
difference is large. uTrack reports total climb as 8,126m, which
is almost Everest scale – so clearly very wrong.
For this site the leaflet-gpx has been tweaked to use the flat
(2d) distance rather the sloping (3d) distance.
It is noted that the computation of the flat earth distance in
leaflet-gpx uses a fixed earth radius (6371km). While the earth
radius varies from equator to pole the difference is small for
this application and dwarfed by GPS measurement errors.