How is the LRS ArcGIS Measure Along a Line implemented?Writing length of line along the lineDistance between...

How do we improve the relationship with a client software team that performs poorly and is becoming less collaborative?

Fencing style for blades that can attack from a distance

Python: next in for loop

Can divisibility rules for digits be generalized to sum of digits

What are these boxed doors outside store fronts in New York?

"to be prejudice towards/against someone" vs "to be prejudiced against/towards someone"

What would happen to a modern skyscraper if it rains micro blackholes?

Is a tag line useful on a cover?

Email Account under attack (really) - anything I can do?

Is it possible to do 50 km distance without any previous training?

Finding angle with pure Geometry.

Accidentally leaked the solution to an assignment, what to do now? (I'm the prof)

Have astronauts in space suits ever taken selfies? If so, how?

To string or not to string

How did the USSR manage to innovate in an environment characterized by government censorship and high bureaucracy?

Risk of getting Chronic Wasting Disease (CWD) in the United States?

TGV timetables / schedules?

Which models of the Boeing 737 are still in production?

Why did Neo believe he could trust the machine when he asked for peace?

Modeling an IPv4 Address

Why did the Germans forbid the possession of pet pigeons in Rostov-on-Don in 1941?

What's the point of deactivating Num Lock on login screens?

What do you call a Matrix-like slowdown and camera movement effect?

Maximum likelihood parameters deviate from posterior distributions



How is the LRS ArcGIS Measure Along a Line implemented?


Writing length of line along the lineDistance between a Point and Linestring: PostGIS/GEOS vs. BoostMeasure distance between points along a line in QGISFind Point Along Line at Certain DistanceCalculating distance for each point along line in ArcGIS Desktop?QGIS and LRS. Define points along line from distance in .txt filecalculate distance of points from reference points along a lineLRS plugin does not return measure field.Calculate distance to points along line in ArcMap?Measure distance between nearest points in the sea along the coast automatically in ArcGIS






.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty{ margin-bottom:0;
}







0















I'm trying to replicate a nasty corner case in a LRS implementation that doesn't agree with ArcMAP measure tool. I've tried measuring distance in its native shp coordinate system NAD83 (27916) to no avail. (basically same results)



My question is how are the distances calculated along a line for the LRS system. My current distance function (for 4326) is the following.



EARTHRADIUS = 3963.190592 # miles

'''
used in distance
'''
def deg2rad(d):
return d * math.pi / 180.0

# in miles
def distance(pt1, pt2):
dLat = deg2rad(pt2[1] - pt1[1])
dLng = abs(deg2rad(pt2[0] - pt1[0]))
dLat2Sin = math.sin(dLat / 2)
dLng2Sin = math.sin(dLng / 2)
a = dLat2Sin*dLat2Sin + math.cos(deg2rad(pt1[1]))*math.cos(deg2rad(pt2[1]))*dLng2Sin*dLng2Sin
return 2.0 * EARTHRADIUS * math.atan2(math.sqrt(a), math.sqrt(1-a))



For most geometries the distance between the ESRI LRS and mine are nominal but this one has something different. I've dealt with larger linestrings before (30+ miles) with no issues. Previously these other larger linestrings have worked fine throughout the alignment, however with this edge case I'm getting ~.5 miles difference (my implementation distances are always larger) between the two implementations by the end.



Is distance calculated a different way via the LRS implementation, is my geometry duplicating previous points possibly, or is it possible coordinate system error is actually sneaking in?










share|improve this question







New contributor




Charles Murphy is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.



























    0















    I'm trying to replicate a nasty corner case in a LRS implementation that doesn't agree with ArcMAP measure tool. I've tried measuring distance in its native shp coordinate system NAD83 (27916) to no avail. (basically same results)



    My question is how are the distances calculated along a line for the LRS system. My current distance function (for 4326) is the following.



    EARTHRADIUS = 3963.190592 # miles

    '''
    used in distance
    '''
    def deg2rad(d):
    return d * math.pi / 180.0

    # in miles
    def distance(pt1, pt2):
    dLat = deg2rad(pt2[1] - pt1[1])
    dLng = abs(deg2rad(pt2[0] - pt1[0]))
    dLat2Sin = math.sin(dLat / 2)
    dLng2Sin = math.sin(dLng / 2)
    a = dLat2Sin*dLat2Sin + math.cos(deg2rad(pt1[1]))*math.cos(deg2rad(pt2[1]))*dLng2Sin*dLng2Sin
    return 2.0 * EARTHRADIUS * math.atan2(math.sqrt(a), math.sqrt(1-a))



    For most geometries the distance between the ESRI LRS and mine are nominal but this one has something different. I've dealt with larger linestrings before (30+ miles) with no issues. Previously these other larger linestrings have worked fine throughout the alignment, however with this edge case I'm getting ~.5 miles difference (my implementation distances are always larger) between the two implementations by the end.



    Is distance calculated a different way via the LRS implementation, is my geometry duplicating previous points possibly, or is it possible coordinate system error is actually sneaking in?










    share|improve this question







    New contributor




    Charles Murphy is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
    Check out our Code of Conduct.























      0












      0








      0








      I'm trying to replicate a nasty corner case in a LRS implementation that doesn't agree with ArcMAP measure tool. I've tried measuring distance in its native shp coordinate system NAD83 (27916) to no avail. (basically same results)



      My question is how are the distances calculated along a line for the LRS system. My current distance function (for 4326) is the following.



      EARTHRADIUS = 3963.190592 # miles

      '''
      used in distance
      '''
      def deg2rad(d):
      return d * math.pi / 180.0

      # in miles
      def distance(pt1, pt2):
      dLat = deg2rad(pt2[1] - pt1[1])
      dLng = abs(deg2rad(pt2[0] - pt1[0]))
      dLat2Sin = math.sin(dLat / 2)
      dLng2Sin = math.sin(dLng / 2)
      a = dLat2Sin*dLat2Sin + math.cos(deg2rad(pt1[1]))*math.cos(deg2rad(pt2[1]))*dLng2Sin*dLng2Sin
      return 2.0 * EARTHRADIUS * math.atan2(math.sqrt(a), math.sqrt(1-a))



      For most geometries the distance between the ESRI LRS and mine are nominal but this one has something different. I've dealt with larger linestrings before (30+ miles) with no issues. Previously these other larger linestrings have worked fine throughout the alignment, however with this edge case I'm getting ~.5 miles difference (my implementation distances are always larger) between the two implementations by the end.



      Is distance calculated a different way via the LRS implementation, is my geometry duplicating previous points possibly, or is it possible coordinate system error is actually sneaking in?










      share|improve this question







      New contributor




      Charles Murphy is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.












      I'm trying to replicate a nasty corner case in a LRS implementation that doesn't agree with ArcMAP measure tool. I've tried measuring distance in its native shp coordinate system NAD83 (27916) to no avail. (basically same results)



      My question is how are the distances calculated along a line for the LRS system. My current distance function (for 4326) is the following.



      EARTHRADIUS = 3963.190592 # miles

      '''
      used in distance
      '''
      def deg2rad(d):
      return d * math.pi / 180.0

      # in miles
      def distance(pt1, pt2):
      dLat = deg2rad(pt2[1] - pt1[1])
      dLng = abs(deg2rad(pt2[0] - pt1[0]))
      dLat2Sin = math.sin(dLat / 2)
      dLng2Sin = math.sin(dLng / 2)
      a = dLat2Sin*dLat2Sin + math.cos(deg2rad(pt1[1]))*math.cos(deg2rad(pt2[1]))*dLng2Sin*dLng2Sin
      return 2.0 * EARTHRADIUS * math.atan2(math.sqrt(a), math.sqrt(1-a))



      For most geometries the distance between the ESRI LRS and mine are nominal but this one has something different. I've dealt with larger linestrings before (30+ miles) with no issues. Previously these other larger linestrings have worked fine throughout the alignment, however with this edge case I'm getting ~.5 miles difference (my implementation distances are always larger) between the two implementations by the end.



      Is distance calculated a different way via the LRS implementation, is my geometry duplicating previous points possibly, or is it possible coordinate system error is actually sneaking in?







      arcmap line distance linear-referencing






      share|improve this question







      New contributor




      Charles Murphy is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.











      share|improve this question







      New contributor




      Charles Murphy is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.









      share|improve this question




      share|improve this question






      New contributor




      Charles Murphy is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.









      asked 13 mins ago









      Charles MurphyCharles Murphy

      1




      1




      New contributor




      Charles Murphy is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.





      New contributor





      Charles Murphy is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.






      Charles Murphy is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.






















          0






          active

          oldest

          votes












          Your Answer








          StackExchange.ready(function() {
          var channelOptions = {
          tags: "".split(" "),
          id: "79"
          };
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function() {
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled) {
          StackExchange.using("snippets", function() {
          createEditor();
          });
          }
          else {
          createEditor();
          }
          });

          function createEditor() {
          StackExchange.prepareEditor({
          heartbeatType: 'answer',
          autoActivateHeartbeat: false,
          convertImagesToLinks: false,
          noModals: true,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: null,
          bindNavPrevention: true,
          postfix: "",
          imageUploader: {
          brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
          contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
          allowUrls: true
          },
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          });


          }
          });






          Charles Murphy is a new contributor. Be nice, and check out our Code of Conduct.










          draft saved

          draft discarded


















          StackExchange.ready(
          function () {
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fgis.stackexchange.com%2fquestions%2f318000%2fhow-is-the-lrs-arcgis-measure-along-a-line-implemented%23new-answer', 'question_page');
          }
          );

          Post as a guest















          Required, but never shown

























          0






          active

          oldest

          votes








          0






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes








          Charles Murphy is a new contributor. Be nice, and check out our Code of Conduct.










          draft saved

          draft discarded


















          Charles Murphy is a new contributor. Be nice, and check out our Code of Conduct.













          Charles Murphy is a new contributor. Be nice, and check out our Code of Conduct.












          Charles Murphy is a new contributor. Be nice, and check out our Code of Conduct.
















          Thanks for contributing an answer to Geographic Information Systems Stack Exchange!


          • Please be sure to answer the question. Provide details and share your research!

          But avoid



          • Asking for help, clarification, or responding to other answers.

          • Making statements based on opinion; back them up with references or personal experience.


          To learn more, see our tips on writing great answers.




          draft saved


          draft discarded














          StackExchange.ready(
          function () {
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fgis.stackexchange.com%2fquestions%2f318000%2fhow-is-the-lrs-arcgis-measure-along-a-line-implemented%23new-answer', 'question_page');
          }
          );

          Post as a guest















          Required, but never shown





















































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown

































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown







          Popular posts from this blog

          Щит и меч (фильм) Содержание Названия серий | Сюжет |...

          is 'sed' thread safeWhat should someone know about using Python scripts in the shell?Nexenta bash script uses...

          Meter-Bus Содержание Параметры шины | Стандартизация |...