<html><head></head><body><div style="font-family: Verdana;font-size: 12.0px;"><div>
<div id="yui_3_16_0_1_1417617698788_15337">Hi,</div>

<div>  </div>

<div>["Turn left",</div>

<div id="yui_3_16_0_1_1417617698788_15336">    "High Street",</div>

<div id="yui_3_16_0_1_1417617698788_15341">    200,                    /// yes this is Integer in the unit of meters from the last instruction</div>

<div id="yui_3_16_0_1_1417617698788_15343">    4,                        // Posistion of instructions according to the geomerty and of course to the start point</div>

<div>                              // dont be scared if this number not follwong the ristrict order if  of 3 not follwos 4.</div>

<div>                              // as I understand this correct this occur because of a generalizaion of the raw geomerty, with this some points can be eliminate.</div>

<div> </div>

<div id="yui_3_16_0_1_1417617698788_15345">    10,                      //Travel time to this point from the last instructions</div>

<div id="yui_3_16_0_1_1417617698788_15347">    "200m",</div>

<div id="yui_3_16_0_1_1417617698788_15349">    "NE",</div>

<div id="yui_3_16_0_1_1417617698788_15351">    22.5</div>

<div id="yui_3_16_0_1_1417617698788_15603">    ]</div>

<div>
<div>1.)</div>

<div>via_points just give the coordinates back of start/end and intermieat points</div>

<div>via_indices look this: https://github.com/Project-OSRM/osrm-backend/issues/1020</div>

<div> </div>

<div>2.) I think this you have to calculated by your self.</div>

<div> </div>

<div>regards</div>

<div> </div>

<div>Carsten</div>

<div style="margin: 10.0px 5.0px 5.0px 10.0px;padding: 10.0px 0 10.0px 10.0px;border-left: 2.0px solid rgb(195,217,229);">
<div style="margin: 0 0 10.0px 0;"><b>Gesendet:</b> Mittwoch, 03. Dezember 2014 um 11:04 Uhr<br/>
<b>Von:</b> "S R" <sriram_ott@yahoo.com><br/>
<b>An:</b> "Mailing list to discuss Project OSRM" <osrm-talk@openstreetmap.org><br/>
<b>Betreff:</b> Re: [OSRM-talk] Plotting position in time using OSRM</div>

<div>
<div style="color: rgb(0,0,0);background-color: rgb(255,255,255);font-family: HelveticaNeue , Helvetica Neue , Helvetica , Arial , Lucida Grande , sans-serif;font-size: 12.0px;">
<div id="yui_3_16_0_1_1417617698788_15308">Hi Carsten</div>

<div id="yui_3_16_0_1_1417617698788_15297"> </div>

<div id="yui_3_16_0_1_1417617698788_15310">Many thanks....the link you mention shows the route instructions describe each street and gives the position of the start point, its length, and time in seconds.</div>

<div id="yui_3_16_0_1_1417617698788_15331"> </div>

<div id="yui_3_16_0_1_1417617698788_15353">This is very helpful.</div>

<div id="yui_3_16_0_1_1417617698788_15333"> </div>

<div id="yui_3_16_0_1_1417617698788_15335">Still the documentation is not fully clear (to me).</div>

<div id="yui_3_16_0_1_1417617698788_15320"> </div>

<div id="yui_3_16_0_1_1417617698788_15338">Take the example in the link:</div>

<div id="yui_3_16_0_1_1417617698788_15337">    ["Turn left",</div>

<div id="yui_3_16_0_1_1417617698788_15336">    "High Street",</div>

<div id="yui_3_16_0_1_1417617698788_15341">    200,                   <------ 200 m long</div>

<div id="yui_3_16_0_1_1417617698788_15343">    4,                        <------ position (of the starting point on the street?)</div>

<div id="yui_3_16_0_1_1417617698788_15345">    10,                      <------- time to traverse this street?</div>

<div id="yui_3_16_0_1_1417617698788_15347">    "200m",</div>

<div id="yui_3_16_0_1_1417617698788_15349">    "NE",</div>

<div id="yui_3_16_0_1_1417617698788_15351">    22.5</div>

<div id="yui_3_16_0_1_1417617698788_15603">    ]</div>

<div id="yui_3_16_0_1_1417617698788_15324"> </div>

<div id="yui_3_16_0_1_1417617698788_15941">My questions are:</div>

<div id="yui_3_16_0_1_1417617698788_15944"> </div>

<div id="yui_3_16_0_1_1417617698788_15945">1. What is the lat/long of the starting position on High Street i.e how to convert "4" to lat/long.</div>

<div id="yui_3_16_0_1_1417617698788_17024"> </div>

<div id="yui_3_16_0_1_1417617698788_17026">    I think this has to do with via indices and via points in the link you mention, but that seems a bit murky (at least to me). Any clarification would help a lot.</div>

<div id="yui_3_16_0_1_1417617698788_18441">    What is the difference between via_indices and via_points. Is there a via_point for each point in the route instruction? Can I just use one or the other?</div>

<div id="yui_3_16_0_1_1417617698788_15950"> </div>

<div id="yui_3_16_0_1_1417617698788_15947">2. After say 5 seconds of travel on High Street, what would be the lat/long of the new position.</div>

<div id="yui_3_16_0_1_1417617698788_15951"> </div>

<div id="yui_3_16_0_1_1417617698788_15964">Thanks</div>

<div id="yui_3_16_0_1_1417617698788_15963">Sriram</div>

<div id="yui_3_16_0_1_1417617698788_15312"> </div>
 

<div id="yui_3_16_0_1_1417617698788_15289" style="font-family: HelveticaNeue , Helvetica Neue , Helvetica , Arial , Lucida Grande , sans-serif;font-size: 12.0px;">
<div id="yui_3_16_0_1_1417617698788_15288" style="font-family: HelveticaNeue , Helvetica Neue , Helvetica , Arial , Lucida Grande , sans-serif;font-size: 16.0px;">
<div>
<hr size="1"/><font face="Arial" size="2"><b><span style="font-weight: bold;">From:</span></b> Carsten Malchow <carsten64stadt@gmx.de><br/>
<b><span style="font-weight: bold;">To:</span></b> osrm-talk@openstreetmap.org<br/>
<b><span style="font-weight: bold;">Sent:</span></b> Wednesday, December 3, 2014 10:43 AM<br/>
<b><span style="font-weight: bold;">Subject:</span></b> Re: [OSRM-talk] Plotting position in time using OSRM</font></div>

<div class="y_msg_container" id="yui_3_16_0_1_1417617698788_15287"> 
<div id="yiv1059649895">
<div id="yui_3_16_0_1_1417617698788_15286">
<div id="yui_3_16_0_1_1417617698788_15285" style="font-family: Verdana;font-size: 12.0px;">
<div id="yui_3_16_0_1_1417617698788_15284">
<div>Hi Sriram</div>

<div id="yui_3_16_0_1_1417617698788_15295"> </div>

<div id="yui_3_16_0_1_1417617698788_15293">to reply a part of your question:</div>

<div id="yui_3_16_0_1_1417617698788_15292">take a look at this documentacion [1]</div>

<div id="yui_3_16_0_1_1417617698788_15283">
<div id="yui_3_16_0_1_1417617698788_15291">The first number is driving directions.</div>

<div>The geomerty is a compressed tring that you have to decompress.</div>

<div id="yui_3_16_0_1_1417617698788_15282">also discripted in the Link below.</div>

<div> </div>

<div>Kind regards</div>

<div> </div>

<div>Carsten</div>

<div> </div>

<div>[1] <a href="https://github.com/Project-OSRM/osrm-backend/wiki/Output-json" target="_blank">https://github.com/Project-OSRM/osrm-backend/wiki/Output-json</a></div>

<div style="margin: 10.0px 5.0px 5.0px 10.0px;padding: 10.0px 0 10.0px 10.0px;border-left: 2.0px solid rgb(195,217,229);">
<div style="margin: 0 0 10.0px 0;"><b>Gesendet:</b> Mittwoch, 03. Dezember 2014 um 09:58 Uhr<br clear="none"/>
<b>Von:</b> "S R" <sriram_ott@yahoo.com><br clear="none"/>
<b>An:</b> "osrm-talk@openstreetmap.org" <osrm-talk@openstreetmap.org><br clear="none"/>
<b>Betreff:</b> [OSRM-talk] Plotting position in time using OSRM</div>

<div>
<div class="qtdSeparateBR"><br/>
 </div>

<div class="yiv1059649895yqt7741810159" id="yiv1059649895yqt78126">
<div style="color: rgb(0,0,0);background-color: rgb(255,255,255);font-family: HelveticaNeue , Helvetica Neue , Helvetica , Arial , Lucida Grande , sans-serif;font-size: 12.0px;">
<div id="yiv1059649895yui_3_16_0_1_1417617698788_5392">I would like to create a simple simulation of  a trip using OSRM.</div>

<div id="yiv1059649895yui_3_16_0_1_1417617698788_5391"> </div>

<div id="yiv1059649895yui_3_16_0_1_1417617698788_5390">I believe the steps would be as follows (my questions are in parenthesis below)</div>

<div id="yiv1059649895yui_3_16_0_1_1417617698788_5389"> </div>

<div id="yiv1059649895yui_3_16_0_1_1417617698788_5388">a. Load OSM map of a city into OSRM</div>

<div id="yiv1059649895yui_3_16_0_1_1417617698788_5397">b. Choose a random begin, end location that falls within the city lat/long (how to find lat/long limits of the loaded map?)</div>

<div id="yiv1059649895yui_3_16_0_1_1417617698788_5400">c. Compute the distance (in time) between start, end using OSRM</div>

<div id="yiv1059649895yui_3_16_0_1_1417617698788_5401">d. Also compute a path between start, end using OSRM (are the node vertices mentioned in route the same as in the OSM map?)</div>

<div id="yiv1059649895yui_3_16_0_1_1417617698788_5402">e. The difficult part:</div>

<div id="yiv1059649895yui_3_16_0_1_1417617698788_5403">    -- start the simulation by displaying the map along with position marker (Leaflet?)</div>

<div id="yiv1059649895yui_3_16_0_1_1417617698788_5404">    -- As time progresses, determine the location along the OSRM route computed above (how can this be done?)</div>

<div id="yiv1059649895yui_3_16_0_1_1417617698788_5406">       and adjust the position marker.</div>

<div id="yiv1059649895yui_3_16_0_1_1417617698788_6764">   </div>

<div id="yiv1059649895yui_3_16_0_1_1417617698788_6054">An OSRM route looks like this:</div>

<pre id="yiv1059649895yui_3_16_0_1_1417617698788_6055"><span id="yiv1059649895yui_3_16_0_1_1417617698788_6767"><span>"</span>route_instructions<span id="yiv1059649895yui_3_16_0_1_1417617698788_6766">"</span></span>: [
        [
            <span><span>"</span>10<span>"</span></span>,    <-------------------- what is this id and how to convert it to lat/long
            <span id="yiv1059649895yui_3_16_0_1_1417617698788_6765"><span>"</span>Schulstraße<span>"</span></span>,
            <span>126</span>,
            <span>0</span>,
            <span>18</span>,
            <span><span>"</span>126m<span>"</span></span>,
            <span><span>"</span>SE<span>"</span></span>,
            <span>116</span>
        ],
        [
            <span><span>"</span>7<span>"</span></span>,     <----------------  how to find elapsed time to this point from previous one
            <span><span>"</span>Am Rahmtor<span>"</span></span>,
            <span>57</span>,
            <span>2</span>,
            <span>11</span>,
            <span id="yiv1059649895yui_3_16_0_1_1417617698788_7592"><span>"</span>57m<span>"</span></span>,
            <span><span>"</span>NE<span>"</span></span>,
            <span>38</span>
        ]

Given a start and end lat/long, a network distance (time) can be obtained as follows:
<span id="yiv1059649895yui_3_16_0_1_1417617698788_6763"><span>"</span>distance_table<span>"</span></span>: [
        [
            <span>0</span>,
            <span id="yiv1059649895yui_3_16_0_1_1417617698788_6761">26084</span>
        ],
        [
            <span id="yiv1059649895yui_3_16_0_1_1417617698788_6762">26084</span>,
            <span>0</span>
        ]

This would be useful if the route way-points above could be converted into time units.
</pre>

<div id="yiv1059649895yui_3_16_0_1_1417617698788_5409">Would appreciate any help with the above questions,</div>

<div id="yiv1059649895yui_3_16_0_1_1417617698788_5411">Sriram</div>
</div>
</div>
_______________________________________________ OSRM-talk mailing list OSRM-talk@openstreetmap.org <a href="https://lists.openstreetmap.org/listinfo/osrm-talk" target="_blank">https://lists.openstreetmap.org/listinfo/osrm-talk</a></div>
</div>
</div>
</div>
</div>
</div>
</div>
 

<div class="yqt7741810159" id="yqt28711">_______________________________________________<br clear="none"/>
OSRM-talk mailing list<br clear="none"/>
<a>OSRM-talk@openstreetmap.org</a><br clear="none"/>
<a href="https://lists.openstreetmap.org/listinfo/osrm-talk" target="_blank">https://lists.openstreetmap.org/listinfo/osrm-talk</a></div>
<br/>
 </div>
</div>
</div>
</div>
_______________________________________________ OSRM-talk mailing list OSRM-talk@openstreetmap.org <a href="https://lists.openstreetmap.org/listinfo/osrm-talk" target="_blank">https://lists.openstreetmap.org/listinfo/osrm-talk</a></div>
</div>
</div>
</div></div></body></html>