Function distance

  • Find the great-circle distance between two points

    This implementation uses a special case of the Vincenty formula See the last formula in https://en.wikipedia.org/wiki/Great-circle_distance#Computational_formulas

    Parameters

    • ra1: number

      The right ascension of the first point, in radians

    • dec1: number

      The declination of the first point, in radians

    • ra2: number

      The right ascension of the second point, in radians

    • dec2: number

      The declination of the second point, in radians

    Returns number

    The great-circle distance

Generated using TypeDoc