azimuthgeocode(geocode1, geocode2 [, method])

The azimuthgeocode function calculates the directional heading going from one geocode to another. It returns a number between 0-360 where 0 is north, 90 east, etc., up to 360 being north again.

The third, optional method parameter can be used to specify which mathematical method is used to calculate the direction. There are two possible values:

  • greatcircle (default) - The "Great Circle" method is a highly accurate tool for calculating distances and directions on a sphere. It is used by default.

  • pythagorean - Calculations based on the pythagorean method can also be used. They're faster, but less accurate as the core formulas don't take the curvature of the earth into consideration. Some internal adjustments are made, but the values are less accurate than the greatcircle method, especially over long distances and with paths that approach the poles.

For examples of using azimuthgeocode, see the geocode script in the texis/samples directory.

Copyright © Thunderstone Software     Last updated: Oct 5 2023
Copyright © 2024 Thunderstone Software LLC. All rights reserved.