<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Extrapolate a point beyond pole with GeometryEngine in Java Maps SDK Questions</title>
    <link>https://community.esri.com/t5/java-maps-sdk-questions/extrapolate-a-point-beyond-pole-with/m-p/1237339#M2640</link>
    <description>&lt;P&gt;I can see the problem here.&amp;nbsp; Loxodromes are lines which happen when you follow a compass bearing.&amp;nbsp; In your example you have a heading of 0 which is North.&amp;nbsp; If you are walking to the North Pole following a compass bearing of North (0), as soon as you reach magnetic north and keep going in the same direction your compass actually starts reading South!&amp;nbsp; This explains why no matter how big a number you pop into your move method, the loxodrome stops at the top of the earth.&lt;/P&gt;&lt;P&gt;Using your code, I switched the line type to a Geodesic (shortest distance between 2 points over the surface of the Earth) and the new point appeared having travelled over the pole.&lt;/P&gt;&lt;P&gt;This is my code:&lt;/P&gt;&lt;LI-CODE lang="java"&gt;      var graphicsOverlay = new GraphicsOverlay();
      mapView.getGraphicsOverlays().add(graphicsOverlay);

      // some markers
      SimpleMarkerSymbol redDot = new SimpleMarkerSymbol(SimpleMarkerSymbol.Style.CIRCLE, Color.RED, 10);
      SimpleMarkerSymbol greenDot = new SimpleMarkerSymbol(SimpleMarkerSymbol.Style.CIRCLE, Color.GREEN, 10);

      // original point
      Point point = new Point(70, 0, SpatialReferences.getWgs84());
      Graphic pointGraphic = new Graphic(point, redDot);
      graphicsOverlay.getGraphics().add(pointGraphic);

      //Point point2 = GeometryEngine.moveGeodetic(point, 8640000.0, new LinearUnit(LinearUnitId.METERS), 0.0, new AngularUnit(AngularUnitId.RADIANS), GeodeticCurveType.LOXODROME); //This returns Point: [0,000000, 90,000000, 0,000000, NaN] SR: 4326

      // geodesic move using a geodesic line instead of a loxodrome.
      Point point2 = GeometryEngine.moveGeodetic(point, 12075000, new LinearUnit(LinearUnitId.METERS), 0.0, new AngularUnit(AngularUnitId.RADIANS), GeodeticCurveType.GEODESIC);
      
      System.out.println("point 2= " + point2.toString());
      Graphic pointGraphic2 = new Graphic(point2, greenDot);
      graphicsOverlay.getGraphics().add(pointGraphic2);&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;You can see the green dot in my app which went over the pole.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="MarkBaird_0-1670004429304.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/57529i57747D94C18580E7/image-size/medium?v=v2&amp;amp;px=400" role="button" title="MarkBaird_0-1670004429304.png" alt="MarkBaird_0-1670004429304.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I went a little further and increased the number to 40075000 which is roughly the circumference of the earth and the 2 dots where "fairly" close to each other.&amp;nbsp; Therefore the point went over the North Pole, the South Pole before coming back to where it started.&lt;/P&gt;&lt;P&gt;Does this help?&lt;/P&gt;&lt;P&gt;Mark&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 02 Dec 2022 18:11:38 GMT</pubDate>
    <dc:creator>MarkBaird</dc:creator>
    <dc:date>2022-12-02T18:11:38Z</dc:date>
    <item>
      <title>Extrapolate a point beyond pole with GeometryEngine</title>
      <link>https://community.esri.com/t5/java-maps-sdk-questions/extrapolate-a-point-beyond-pole-with/m-p/1237262#M2639</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I'm currently developping an application using the 100.14.0 version of the SDK.&lt;/P&gt;&lt;P&gt;I should mention I'm not very experienced in manipulating projections so that might be the issue here.&lt;/P&gt;&lt;P&gt;There is something I can't figure out about the GeometryEngine, here is a sample code :&lt;/P&gt;&lt;LI-CODE lang="java"&gt;Point point = new Point(70, 0, SpatialReferences.getWgs84());

GeometryEngine.moveGeodetic(point, 8640000.0, new LinearUnit(LinearUnitId.METERS), 0.0, new AngularUnit(AngularUnitId.RADIANS), GeodeticCurveType.LOXODROME); //This returns Point: [0,000000, 90,000000, 0,000000, NaN] SR: 4326&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I would expect the point to go beyond the north pole and circle around the earth, but it seems like the GeometryEngine cannot go beyond the pole in this configuration.&lt;/P&gt;&lt;P&gt;I suspect this has something to do with the projection, but I'm not knowledgeable enough about it to understand how to fix this.&lt;/P&gt;&lt;P&gt;Could anyone explain what's going on ? Are there any ressources I could read about this topic that could help me ?&lt;/P&gt;</description>
      <pubDate>Fri, 02 Dec 2022 15:32:33 GMT</pubDate>
      <guid>https://community.esri.com/t5/java-maps-sdk-questions/extrapolate-a-point-beyond-pole-with/m-p/1237262#M2639</guid>
      <dc:creator>Tone</dc:creator>
      <dc:date>2022-12-02T15:32:33Z</dc:date>
    </item>
    <item>
      <title>Re: Extrapolate a point beyond pole with GeometryEngine</title>
      <link>https://community.esri.com/t5/java-maps-sdk-questions/extrapolate-a-point-beyond-pole-with/m-p/1237339#M2640</link>
      <description>&lt;P&gt;I can see the problem here.&amp;nbsp; Loxodromes are lines which happen when you follow a compass bearing.&amp;nbsp; In your example you have a heading of 0 which is North.&amp;nbsp; If you are walking to the North Pole following a compass bearing of North (0), as soon as you reach magnetic north and keep going in the same direction your compass actually starts reading South!&amp;nbsp; This explains why no matter how big a number you pop into your move method, the loxodrome stops at the top of the earth.&lt;/P&gt;&lt;P&gt;Using your code, I switched the line type to a Geodesic (shortest distance between 2 points over the surface of the Earth) and the new point appeared having travelled over the pole.&lt;/P&gt;&lt;P&gt;This is my code:&lt;/P&gt;&lt;LI-CODE lang="java"&gt;      var graphicsOverlay = new GraphicsOverlay();
      mapView.getGraphicsOverlays().add(graphicsOverlay);

      // some markers
      SimpleMarkerSymbol redDot = new SimpleMarkerSymbol(SimpleMarkerSymbol.Style.CIRCLE, Color.RED, 10);
      SimpleMarkerSymbol greenDot = new SimpleMarkerSymbol(SimpleMarkerSymbol.Style.CIRCLE, Color.GREEN, 10);

      // original point
      Point point = new Point(70, 0, SpatialReferences.getWgs84());
      Graphic pointGraphic = new Graphic(point, redDot);
      graphicsOverlay.getGraphics().add(pointGraphic);

      //Point point2 = GeometryEngine.moveGeodetic(point, 8640000.0, new LinearUnit(LinearUnitId.METERS), 0.0, new AngularUnit(AngularUnitId.RADIANS), GeodeticCurveType.LOXODROME); //This returns Point: [0,000000, 90,000000, 0,000000, NaN] SR: 4326

      // geodesic move using a geodesic line instead of a loxodrome.
      Point point2 = GeometryEngine.moveGeodetic(point, 12075000, new LinearUnit(LinearUnitId.METERS), 0.0, new AngularUnit(AngularUnitId.RADIANS), GeodeticCurveType.GEODESIC);
      
      System.out.println("point 2= " + point2.toString());
      Graphic pointGraphic2 = new Graphic(point2, greenDot);
      graphicsOverlay.getGraphics().add(pointGraphic2);&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;You can see the green dot in my app which went over the pole.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="MarkBaird_0-1670004429304.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/57529i57747D94C18580E7/image-size/medium?v=v2&amp;amp;px=400" role="button" title="MarkBaird_0-1670004429304.png" alt="MarkBaird_0-1670004429304.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I went a little further and increased the number to 40075000 which is roughly the circumference of the earth and the 2 dots where "fairly" close to each other.&amp;nbsp; Therefore the point went over the North Pole, the South Pole before coming back to where it started.&lt;/P&gt;&lt;P&gt;Does this help?&lt;/P&gt;&lt;P&gt;Mark&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 02 Dec 2022 18:11:38 GMT</pubDate>
      <guid>https://community.esri.com/t5/java-maps-sdk-questions/extrapolate-a-point-beyond-pole-with/m-p/1237339#M2640</guid>
      <dc:creator>MarkBaird</dc:creator>
      <dc:date>2022-12-02T18:11:38Z</dc:date>
    </item>
    <item>
      <title>Re: Extrapolate a point beyond pole with GeometryEngine</title>
      <link>https://community.esri.com/t5/java-maps-sdk-questions/extrapolate-a-point-beyond-pole-with/m-p/1238651#M2641</link>
      <description>&lt;P&gt;Yes, thank you very much !&lt;/P&gt;</description>
      <pubDate>Wed, 07 Dec 2022 09:25:34 GMT</pubDate>
      <guid>https://community.esri.com/t5/java-maps-sdk-questions/extrapolate-a-point-beyond-pole-with/m-p/1238651#M2641</guid>
      <dc:creator>Tone</dc:creator>
      <dc:date>2022-12-07T09:25:34Z</dc:date>
    </item>
  </channel>
</rss>

