1lrs(1)                        Grass User's Manual                       lrs(1)
2
3
4

LRS (Linear Referencing System)

DESCRIPTION

7       A Linear Referencing System (LRS) is a system where features (points or
8       segments) are localized by a measure along a linear element.   The  LRS
9       can be used to reference events for any network of linear features, for
10       example roads, railways,  rivers,  pipelines,  electric  and  telephone
11       lines,  water and sewer networks. An event is defined in LRS by a route
12       ID and a measure. A route is a path on the  network,  usually  composed
13       from  more  features  in the input map.  Events can be either points or
14       lines (segments).
15
16       LRS is created from input lines and points in vector map.  Points -  MP
17       (mileposts) must have attached attributes specifying line and distance.
18       The distances from the beginning of the linear feature  in  real  world
19       are  specified by MP+offset.  Typically, MP is in kilometers and offset
20       in meters.
21
22       The implementation of LRS in GRASS has some particularities.
23
24   Double referenced system
25       This feature gives a possibility to continue to use most of  old  mile‐
26       posts  if  only  small part of linear object in real world has changed.
27       Example:
28       --- road (linear feature)
29        +   MP (milepost, point, distance from the beginning in km)
30       Old situation:
31       +----+----+----+----+----+
32       0    2    3    4    5    6
33       New situation (for example a new bypass around the village)
34                 ?    ?
35                 +----+
36                 |    |
37                 |    |
38       +----+----+    +----+----+
39       0    2    3    4    5    6
40       The segment between km 3 and 4 is now longer, it is now 3 km not  1  km
41       as  in  old  version. It would be expensive to change also all MP >= 4,
42       but we cannot use km 4 twice.  It is possible to use  another  notation
43       for  the  new  segment,  we reference the segment from the kilometer 3,
44       using only offset.
45             3+1000  3+2000
46                 +----+
47                 |    |
48                 |    |
49       +----+----+    +----+----+
50       0    2    3  3+3000 5    6
51                      4
52       This way, there is no ambiguity and minimal changes  are  needed.   But
53       the  MP  4  is  no more the end of segment 3 - 4 but the end of segment
54       3+2000 - 3+3000. This information must be entered to the system and  it
55       is done by optional MP attributes:
56
57           ·   end_mp - end MP
58
59           ·   end_off - end offset
60       In this case original MP on km 4 will have these attributes:
61       start_mp:  4
62       start_off: 0
63       end_mp:    3
64       end_off:   3000
65       Because  each  MP  can keep 2 values (start, end) it is called ’double’
66       referenced LRS.
67
68       To avoid potential confusion, MP values are limited to  integers  only.
69       It  would  be  ambiguous to have for example segments 3.500 - 3.500+200
70       and 3.600 - 3.600+200. The position 3+650 would fall into  2  segments,
71       correct  would  be 3.600+50.  That means, that MP must be the beginning
72       of antonomous segment and all parts which becomes  longer  then  before
73       must be referenced from the last not changed MP.
74
75       The  MP  start_mp  and end_mp columns must be decimal, but v.lrs.create
76       takes only the decimal part, and adds its value to offset and prints  a
77       warning.
78
79       It  is  highly  recommended to work with polylines instead of segmented
80       vector lines. The command v.build.polylines creates this map structure.
81
82   LRS table structure
83       Attribute                                                    Type                                                         Description
84
85       rsid                                                         integer                                                      reference segment ID, unique in the table
86
87       lcat                                                         integer                                                      category of the line in the LRS map
88
89       lid                                                          integer                                                      route ID (LID)
90
91       start_map                                                    double precision                                             distance measured along the line in LRS map from the  begin‐
92                                                                                                                                 ning  of  the line to the beginning of the segment (absolute
93                                                                                                                                 milepost distance)
94
95       end_map                                                      double precision                                             distance measured along the line in LRS map from the  begin‐
96                                                                                                                                 ning  of  the line to the end of the segment  (absolute dis‐
97                                                                                                                                 tance of subsequent milepost)
98
99       start_mp                                                     double precision                                             milepost number assigned to the start of the segment
100
101       start_off                                                    double precision                                             distance from start_mp to the start of the segment  measured
102                                                                                                                                 along the physical object
103
104       end_mp                                                       double precision                                             milepost number assigned to the end of the segment
105
106       end_off                                                      double precision                                             distance  from  end_mp  to end of the segment measured along
107                                                                                                                                 the physical object
108
109       end_type                                                     integer                                                      1: the same as specified for from_ ; 2: calculated from  map
110                                                                                                                                 along the line from previous MP; 3: defined by user
111
112
113   Available commands
114           ·   v.lrs.create to create a linear referencing system,
115
116           ·   v.lrs.label to create stationing on the LRS,
117
118           ·   v.lrs.segment to create points/segments on LRS, and
119
120           ·   v.lrs.where to find line id and real km+offset for given points
121               in vector map using linear referencing system.
122
123   Input lines for v.lrs.segment and v.lrs.label
124       v.lrs.create joins all connected lines of the same  line  ID  into  one
125       line,  the  LRS  library  and  other  modules  using  LRS  expect this!
126       LR_get_nearest_offset in the LRS library checks duplicate segments only
127       by line_cat and map_offset, not by coordinates in map.
128
129   Duplicate positions
130       It can happen that one offset appears on 2 different lines:
131       ------1-------     --------2------
132       +0.0            +1.0              +2.0
133       In  this case, the module gives error because the position results in 2
134       points.
135
136       It can be also intended, for example a part of the road is shared  with
137       another one, but MP are used only for one:
138        + road1/km15         + road1/km22
139         \                  /
140          \ road1/km17     / road1/km20
141           +--------------+
142          / road2/km52     \ road2/km52
143         /                  \
144        + road2/km50         + road2/km54
145

NOTES

147       Explanations of selected options:
148
149           ·   llayer:  vector  layer  in line map (usually 1; see vectorintro
150               for "layer" concept)
151
152           ·   player: vector layer in point map (usually 1;  see  vectorintro
153               for "layer" concept)
154
155           ·   rsdriver: Driver name for LRS table - DBMI SQL driver (dbf, pg,
156               mysql, sqlite, etc)
157
158           ·   rsdatabase: Database name for LRS table  -  DBMI  SQL  database
159               name (e.g., "lrsdb")
160
161           ·   rstable:  Name  of  the  LRS table - DBMI SQL table name (e.g.,
162               "streamslrs")
163

SEE ALSO

165       R. Blazek, 2004, Introducing the  Linear  Reference  System  in  GRASS,
166       Bangkok, GRASS User Conf. Proc.
167       R.  Blazek,  2005,  Introducing  the  Linear Reference System in GRASS,
168       International Journal of Geoinformatics, Vol. 1(3), pp. 95-100
169
170       v.build.polylines,    v.lrs.create,     v.lrs.segment,     v.lrs.where,
171       v.lrs.label
172

AUTHOR

174       Radim Blazek, ITC-irst/MPA Solutions Trento
175       Documentation  update  (based  on  above  journal article and available
176       fragments): Markus Neteler
177
178       Last changed: $Date: 2014-04-20 12:47:59 +0200 (Sun, 20 Apr 2014) $
179
180       Main index | Topics index | Keywords index |  Graphical  index  |  Full
181       index
182
183       © 2003-2019 GRASS Development Team, GRASS GIS 7.6.0 Reference Manual
184
185
186
187GRASS 7.6.0                                                             lrs(1)
Impressum