Skip to main content

Class: GeoCircle

Defined in: src/sdk/geo/GeoCircle.ts:17

A circle on Earth's surface, defined as the set of points on the Earth's surface equidistant (as measured geodetically) from a central point.

Constructors

Constructor

new GeoCircle(center, radius): GeoCircle

Defined in: src/sdk/geo/GeoCircle.ts:41

Creates a new instance of GeoCircle.

Parameters

ParameterTypeDescription
centerReadonlyFloat64ArrayThe center of the new circle, represented as a position vector in the standard geographic cartesian reference system.
radiusnumberThe radius of the new circle in great-arc radians.

Returns

GeoCircle

Properties

center

readonly center: Readonly<Omit<Float64Array<ArrayBufferLike>, "set" | "sort" | "copyWithin">>

Defined in: src/sdk/geo/GeoCircle.ts:29

The center of this circle, as the cartesian representation (x, y, z) of a point, in units of great-arc radians.


radius

readonly radius: 0 = 0

Defined in: src/sdk/geo/GeoCircle.ts:32

The radius of this circle, in great-arc radians.


ANGULAR_TOLERANCE

readonly static ANGULAR_TOLERANCE: 1e-7 = GeoMath.ANGULAR_TOLERANCE

Defined in: src/sdk/geo/GeoCircle.ts:19

The default angular tolerance used by GeoCircle, in radians.

Methods

angleAlong()

angleAlong(start, end, tolerance, equalityTolerance): number

Defined in: src/sdk/geo/GeoCircle.ts:295

Gets the angular distance along an arc between two points that lie on this circle. The arc extends from the first point to the second in a counterclockwise direction when viewed from above the center of the circle.

Parameters

ParameterTypeDefault valueDescription
startReadonly<Omit<Float64Array<ArrayBufferLike>, "set" | "sort" | "copyWithin">> | Readonly<LatLonInterface>undefinedA point on this circle which marks the beginning of an arc.
endReadonly<Omit<Float64Array<ArrayBufferLike>, "set" | "sort" | "copyWithin">> | Readonly<LatLonInterface>undefinedA point on this circle which marks the end of an arc.
tolerancenumberGeoCircle.ANGULAR_TOLERANCEThe error tolerance, in great-arc radians, when checking if start and end lie on this circle. Defaults to GeoCircle.ANGULAR_TOLERANCE if not specified.
equalityTolerancenumber0The angular tolerance for considering the start and end points to be equal, in radians. If the absolute (direction-agnostic) angular distance between the start and end points is less than or equal to this value, then the zero will be returned. Defaults to 0.

Returns

number

the angular width of the arc between the two points, in radians.

Throws

Error if either point does not lie on this circle.


angularWidth()

angularWidth(length): number

Defined in: src/sdk/geo/GeoCircle.ts:77

Calculates the central angle which subtends an arc along this circle of given length.

Parameters

ParameterTypeDescription
lengthnumberAn arc length, in great-arc radians.

Returns

number

The central angle which subtends an arc along this circle of the given length, in radians.


arcLength()

arcLength(angle): number

Defined in: src/sdk/geo/GeoCircle.ts:68

Calculates the length of an arc along this circle subtended by a central angle.

Parameters

ParameterTypeDescription
anglenumberA central angle, in radians.

Returns

number

The length of the arc subtended by the angle, in great-arc radians.


bearingAt()

bearingAt(point, tolerance): number

Defined in: src/sdk/geo/GeoCircle.ts:359

Calculates the true bearing along this circle at a point on the circle.

Parameters

ParameterTypeDefault valueDescription
pointReadonly<Omit<Float64Array<ArrayBufferLike>, "set" | "sort" | "copyWithin">> | Readonly<LatLonInterface>undefinedA point on this circle.
tolerancenumberGeoCircle.ANGULAR_TOLERANCEThe error tolerance, in great-arc radians, when checking if point lies on this circle. Defaults to GeoCircle.ANGULAR_TOLERANCE if not specified.

Returns

number

the bearing along this circle at the point.

Throws

Error if the point does not lie on this circle.


closest()

Call Signature

closest(point, out): Float64Array

Defined in: src/sdk/geo/GeoCircle.ts:191

Finds the closest point on this circle to a specified point. In other words, projects the specified point onto this circle. If the specified point is equidistant from all points on this circle (i.e. it is coincident with or antipodal to this circle's center), then NaN will be written to all components of the result.

Parameters
ParameterTypeDescription
pointReadonly<Omit<Float64Array<ArrayBufferLike>, "set" | "sort" | "copyWithin">> | Readonly<LatLonInterface>A point, represented as either a position vector or lat/long coordinates.
outFloat64ArrayA 3D vector to which to write the result. The result will be written as the cartesian (x, y, z) representation, in units of great-arc radians.
Returns

Float64Array

The closest point on this circle to the specified point.

Call Signature

closest(point, out): GeoPoint

Defined in: src/sdk/geo/GeoCircle.ts:200

Finds the closest point on this circle to a specified point. In other words, projects the specified point onto this circle. If the specified point is equidistant from all points on this circle (i.e. it is coincident with or antipodal to this circle's center), NaN will be written to all components of the result.

Parameters
ParameterTypeDescription
pointReadonly<Omit<Float64Array<ArrayBufferLike>, "set" | "sort" | "copyWithin">> | Readonly<LatLonInterface>A point, represented as either a position vector or lat/long coordinates.
outGeoPointA GeoPoint object to which to write the result.
Returns

GeoPoint

The closest point on this circle to the specified point.

Call Signature

closest<Out>(point, out): Out

Defined in: src/sdk/geo/GeoCircle.ts:210

Finds the closest point on this circle to a specified point. In other words, projects the specified point onto this circle. If the specified point is equidistant from all points on this circle (i.e. it is coincident with or antipodal to this circle's center), NaN will be written to all components of the result.

Type Parameters
Type Parameter
Out extends Float64Array<ArrayBufferLike> | GeoPoint
Parameters
ParameterTypeDescription
pointReadonly<Omit<Float64Array<ArrayBufferLike>, "set" | "sort" | "copyWithin">> | Readonly<LatLonInterface>A point, represented as either a position vector or lat/long coordinates.
outOutA 3D vector or GeoPoint object to which to write the result. If a vector is supplied, then the result will be written as the cartesian (x, y, z) representation, in units of great-arc radians.
Returns

Out

The closest point on this circle to the specified point.


distance()

distance(point): number

Defined in: src/sdk/geo/GeoCircle.ts:249

Calculates and returns the great-circle distance from a specified point to the closest point that lies on this circle. In other words, calculates the shortest distance from a point to this circle. The distance is signed, with positive distances representing deviation away from the center of the circle, and negative distances representing deviation toward the center of the circle.

Parameters

ParameterTypeDescription
pointReadonly<Omit<Float64Array<ArrayBufferLike>, "set" | "sort" | "copyWithin">> | Readonly<LatLonInterface>A point, represented as either a position vector or lat/long coordinates.

Returns

number

the great circle distance, in great-arc radians, from the point to the closest point on this circle.


distanceAlong()

distanceAlong(start, end, tolerance, equalityTolerance): number

Defined in: src/sdk/geo/GeoCircle.ts:342

Gets the distance along an arc between two points that lie on this circle. The arc extends from the first point to the second in a counterclockwise direction when viewed from above the center of the circle.

Parameters

ParameterTypeDefault valueDescription
startReadonly<Omit<Float64Array<ArrayBufferLike>, "set" | "sort" | "copyWithin">> | Readonly<LatLonInterface>undefinedA point on this circle which marks the beginning of an arc.
endReadonly<Omit<Float64Array<ArrayBufferLike>, "set" | "sort" | "copyWithin">> | Readonly<LatLonInterface>undefinedA point on this circle which marks the end of an arc.
tolerancenumberGeoCircle.ANGULAR_TOLERANCEThe error tolerance, in great-arc radians, when checking if start and end lie on this circle. Defaults to GeoCircle.ANGULAR_TOLERANCE if not specified.
equalityTolerancenumber0The tolerance for considering the start and end points to be equal, in great-arc radians. If the absolute (direction-agnostic) along-arc distance between the start and end points is less than or equal to this value, then the zero will be returned. Defaults to 0.

Returns

number

the length of the arc between the two points, in great-arc radians.

Throws

Error if either point does not lie on this circle.


encircles()

encircles(point, inclusive, tolerance): boolean

Defined in: src/sdk/geo/GeoCircle.ts:275

Checks whether a point lies within the boundary defined by this circle. This is equivalent to checking whether the distance of the point from the center of this circle is less than or equal to this circle's radius.

Parameters

ParameterTypeDefault valueDescription
pointReadonly<Omit<Float64Array<ArrayBufferLike>, "set" | "sort" | "copyWithin">> | Readonly<LatLonInterface>undefinedA point, represented as either a position vector or lat/long coordinates.
inclusivebooleantrueWhether points that lie on this circle should pass the check. True by default.
tolerancenumberGeoCircle.ANGULAR_TOLERANCEThe error tolerance, in great-arc radians, of this operation. Defaults to GeoCircle.ANGULAR_TOLERANCE if not specified.

Returns

boolean

whether the point lies within the boundary defined by this circle.


includes()

includes(point, tolerance): boolean

Defined in: src/sdk/geo/GeoCircle.ts:261

Checks whether a point lies on this circle.

Parameters

ParameterTypeDefault valueDescription
pointReadonly<Omit<Float64Array<ArrayBufferLike>, "set" | "sort" | "copyWithin">> | Readonly<LatLonInterface>undefinedA point, represented as either a position vector or lat/long coordinates.
tolerancenumberGeoCircle.ANGULAR_TOLERANCEThe error tolerance, in great-arc radians, of this operation. Defaults to GeoCircle.ANGULAR_TOLERANCE if not specified.

Returns

boolean

whether the point lies on this circle.


intersection()

intersection(other, out, tolerance): number

Defined in: src/sdk/geo/GeoCircle.ts:604

Calculates and returns the set of intersection points between this circle and another one, and writes the results to an array of position vectors.

Parameters

ParameterTypeDefault valueDescription
otherReadonlyGeoCircleundefinedThe other circle to test for intersections.
outFloat64Array<ArrayBufferLike>[]undefinedAn array in which to store the results. The results will be stored at indexes 0 and 1. If these indexes are empty, then new Float64Array objects will be created and inserted into the array.
tolerancenumber0The error tolerance of this operation, in great-arc radians. Defaults to 0.

Returns

number

The number of solutions written to the out array. Either 0, 1, or 2.


intersectionGeoPoint()

intersectionGeoPoint(other, out, tolerance): number

Defined in: src/sdk/geo/GeoCircle.ts:695

Calculates and returns the set of intersection points between this circle and another one, and writes the results to an array of GeoPoint objects.

Parameters

ParameterTypeDefault valueDescription
otherReadonlyGeoCircleundefinedThe other circle to test for intersections.
outGeoPoint[]undefinedAn array in which to store the results. The results will be stored at indexes 0 and 1. If these indexes are empty, then new GeoPoint objects will be created and inserted into the array.
tolerancenumber0The error tolerance of this operation, in great-arc radians. Defaults to 0.

Returns

number

The number of solutions written to the out array. Either 0, 1, or 2.


isGreatCircle()

isGreatCircle(): boolean

Defined in: src/sdk/geo/GeoCircle.ts:59

Checks whether this circle is a great circle, or equivalently, whether its radius is equal to pi / 2 great-arc radians.

Returns

boolean

Whether this circle is a great circle.


isValid()

isValid(): boolean

Defined in: src/sdk/geo/GeoCircle.ts:50

Checks whether this circle is a valid. A circle is valid if and only if it has a finite radius and its center is a position vector pointing to a point on the earth's surface.

Returns

boolean

Whether this circle is valid.


numIntersectionPoints()

numIntersectionPoints(other, tolerance): number

Defined in: src/sdk/geo/GeoCircle.ts:718

Calculates and returns the number of intersection points between this circle and another one. Returns NaN if there are an infinite number of intersection points.

Parameters

ParameterTypeDefault valueDescription
otherReadonlyGeoCircleundefinedThe other circle to test for intersections.
tolerancenumberGeoCircle.ANGULAR_TOLERANCEThe error tolerance of this operation, in great-arc radians. Defaults to GeoCircle.ANGULAR_TOLERANCE if not specified.

Returns

number

The number of intersection points between this circle and the other one.


offsetAngleAlong()

Call Signature

offsetAngleAlong(point, angle, out, tolerance?): Float64Array

Defined in: src/sdk/geo/GeoCircle.ts:448

Offsets a point on this circle by a specified angular distance. The direction of the offset for positive distances is counterclockwise when viewed from above the center of this circle.

Parameters
ParameterTypeDescription
pointReadonly<Omit<Float64Array<ArrayBufferLike>, "set" | "sort" | "copyWithin">> | Readonly<LatLonInterface>The point to offset.
anglenumberThe angular distance by which to offset, in radians.
outFloat64ArrayA 3D vector to which to write the result. The result will be written as the cartesian (x, y, z) representation, in units of great-arc radians.
tolerance?numberThe error tolerance, in great-arc radians, when checking if point lies on this circle. Defaults to GeoCircle.ANGULAR_TOLERANCE if not specified.
Returns

Float64Array

The offset point.

Throws

Error if the point does not lie on this circle.

Call Signature

offsetAngleAlong(point, angle, out, tolerance?): GeoPoint

Defined in: src/sdk/geo/GeoCircle.ts:460

Offsets a point on this circle by a specified angular distance. The direction of the offset for positive distances is counterclockwise when viewed from above the center of this circle.

Parameters
ParameterTypeDescription
pointReadonly<Omit<Float64Array<ArrayBufferLike>, "set" | "sort" | "copyWithin">> | Readonly<LatLonInterface>The point to offset.
anglenumberThe angular distance by which to offset, in radians.
outGeoPointA GeoPoint object to which to write the result.
tolerance?numberThe error tolerance, in great-arc radians, when checking if point lies on this circle. Defaults to GeoCircle.ANGULAR_TOLERANCE if not specified.
Returns

GeoPoint

The offset point.

Throws

Error if the point does not lie on this circle.

Call Signature

offsetAngleAlong<Out>(point, angle, out, tolerance?): Out

Defined in: src/sdk/geo/GeoCircle.ts:473

Offsets a point on this circle by a specified angular distance. The direction of the offset for positive distances is counterclockwise when viewed from above the center of this circle.

Type Parameters
Type Parameter
Out extends Float64Array<ArrayBufferLike> | GeoPoint
Parameters
ParameterTypeDescription
pointReadonly<Omit<Float64Array<ArrayBufferLike>, "set" | "sort" | "copyWithin">> | Readonly<LatLonInterface>The point to offset.
anglenumberThe angular distance by which to offset, in radians.
outOutA 3D vector or GeoPoint object to which to write the result. If a vector is supplied, then the result will be written as the cartesian (x, y, z) representation, in units of great-arc radians.
tolerance?numberThe error tolerance, in great-arc radians, when checking if point lies on this circle. Defaults to GeoCircle.ANGULAR_TOLERANCE if not specified.
Returns

Out

The offset point.

Throws

Error if the point does not lie on this circle.


offsetDistanceAlong()

Call Signature

offsetDistanceAlong(point, distance, out, tolerance?): Float64Array

Defined in: src/sdk/geo/GeoCircle.ts:394

Offsets a point on this circle by a specified distance. The direction of the offset for positive distances is counterclockwise when viewed from above the center of this circle.

Parameters
ParameterTypeDescription
pointReadonly<Omit<Float64Array<ArrayBufferLike>, "set" | "sort" | "copyWithin">> | Readonly<LatLonInterface>The point to offset.
distancenumberThe distance by which to offset, in great-arc radians.
outFloat64ArrayA 3D vector to which to write the result. The result will be written as the cartesian (x, y, z) representation, in units of great-arc radians.
tolerance?numberThe error tolerance, in great-arc radians, when checking if point lies on this circle. Defaults to GeoCircle.ANGULAR_TOLERANCE if not specified.
Returns

Float64Array

The offset point.

Throws

Error if the point does not lie on this circle.

Call Signature

offsetDistanceAlong(point, distance, out, tolerance?): GeoPoint

Defined in: src/sdk/geo/GeoCircle.ts:406

Offsets a point on this circle by a specified distance. The direction of the offset for positive distances is counterclockwise when viewed from above the center of this circle.

Parameters
ParameterTypeDescription
pointReadonly<Omit<Float64Array<ArrayBufferLike>, "set" | "sort" | "copyWithin">> | Readonly<LatLonInterface>The point to offset.
distancenumberThe distance by which to offset, in great-arc radians.
outGeoPointA GeoPoint object to which to write the result.
tolerance?numberThe error tolerance, in great-arc radians, when checking if point lies on this circle. Defaults to GeoCircle.ANGULAR_TOLERANCE if not specified.
Returns

GeoPoint

The offset point.

Throws

Error if the point does not lie on this circle.

Call Signature

offsetDistanceAlong<Out>(point, distance, out, tolerance?): Out

Defined in: src/sdk/geo/GeoCircle.ts:419

Offsets a point on this circle by a specified distance. The direction of the offset for positive distances is counterclockwise when viewed from above the center of this circle.

Type Parameters
Type Parameter
Out extends Float64Array<ArrayBufferLike> | GeoPoint
Parameters
ParameterTypeDescription
pointReadonly<Omit<Float64Array<ArrayBufferLike>, "set" | "sort" | "copyWithin">> | Readonly<LatLonInterface>The point to offset.
distancenumberThe distance by which to offset, in great-arc radians.
outOutA 3D vector or GeoPoint object to which to write the result. If a vector is supplied, then the result will be written as the cartesian (x, y, z) representation, in units of great-arc radians.
tolerance?numberThe error tolerance, in great-arc radians, when checking if point lies on this circle. Defaults to GeoCircle.ANGULAR_TOLERANCE if not specified.
Returns

Out

The offset point.

Throws

Error if the point does not lie on this circle.


reverse()

reverse(): this

Defined in: src/sdk/geo/GeoCircle.ts:158

Reverses the direction of this circle. This sets the center of the circle to its antipode and the radius to its complement with Math.PI.

Returns

this

This circle, after it has been reversed.


rotate()

rotate(pivot, angle, tolerance): GeoCircle

Defined in: src/sdk/geo/GeoCircle.ts:561

Rotates this circle around a pivot.

Parameters

ParameterTypeDefault valueDescription
pivotReadonly<Omit<Float64Array<ArrayBufferLike>, "set" | "sort" | "copyWithin">> | Readonly<LatLonInterface>undefinedThe pivot point of the rotation. If the pivot point does not lie exactly on this circle, then it will be projected onto this circle.
anglenumberundefinedThe angle by which to rotate, in radians. Positive angles rotate the circle clockwise. In other words, if vector A is parallel to this circle at the pivot point and vector B is parallel to this circle after a rotation by angle delta at the pivot point, then vector B is equal to vector A after a clockwise rotation by angle delta, as viewed from directly above the earth's surface at the pivot point.
tolerancenumberGeoCircle.ANGULAR_TOLERANCEThe error tolerance, in great-arc radians, when checking if pivot lies on this circle. Defaults to GeoCircle.ANGULAR_TOLERANCE if not specified.

Returns

GeoCircle

This circle, after it has been rotated around the specified pivot point by the specified angle.

Throws

Error if the pivot point does not lie on this circle, or if the pivot point cannot be projected onto this circle because it is equidistant to all points on this circle.


set()

set(center, radius): this

Defined in: src/sdk/geo/GeoCircle.ts:87

Sets the center and radius of this circle.

Parameters

ParameterTypeDescription
centerReadonly<Omit<Float64Array<ArrayBufferLike>, "set" | "sort" | "copyWithin">> | Readonly<LatLonInterface>The new center.
radiusnumberThe new radius in great-arc radians.

Returns

this

This circle, after it has been changed.


setAsGreatCircle()

Call Signature

setAsGreatCircle(point1, point2): this

Defined in: src/sdk/geo/GeoCircle.ts:121

Sets this circle to be a great circle that includes two given points and is parallel to the path from the first point to the second point. If the two points are coincident or antipodal, then this circle will be set to an invalid circle with center coordinates equal to [NaN, NaN, NaN].

Parameters
ParameterTypeDescription
point1Readonly<Omit<Float64Array<ArrayBufferLike>, "set" | "sort" | "copyWithin">> | Readonly<LatLonInterface>The first point that lies on the great circle.
point2Readonly<Omit<Float64Array<ArrayBufferLike>, "set" | "sort" | "copyWithin">> | Readonly<LatLonInterface>The second point that lies on the great circle.
Returns

this

This circle, after it has been changed.

Call Signature

setAsGreatCircle(point, bearing): this

Defined in: src/sdk/geo/GeoCircle.ts:129

Sets this circle to be a great circle that includes a given point and is parallel to an initial bearing from the same point.

Parameters
ParameterTypeDescription
pointReadonly<Omit<Float64Array<ArrayBufferLike>, "set" | "sort" | "copyWithin">> | Readonly<LatLonInterface>A point that lies on the great circle.
bearingnumberThe initial bearing from the point, in degrees.
Returns

this

This circle, after it has been changed.

Call Signature

setAsGreatCircle(point, circle): this

Defined in: src/sdk/geo/GeoCircle.ts:139

Sets this circle to be a great circle that is tangent and parallel to another GeoCircle at a given point. If the specified point does not lie exactly on the other GeoCircle, then the projection of the point onto the other GeoCircle will be used instead. If the point cannot be projected onto the GeoCircle, then this circle will be set to an invalid circle with center coordinates equal to [NaN, NaN, NaN].

Parameters
ParameterTypeDescription
pointReadonly<Omit<Float64Array<ArrayBufferLike>, "set" | "sort" | "copyWithin">> | Readonly<LatLonInterface>The point at which this circle will be tangent and parallel to the other circle.
circleReadonlyGeoCircleThe other GeoCircle.
Returns

this

This circle, after it has been changed.


createFromPoint()

static createFromPoint(point, radius): GeoCircle

Defined in: src/sdk/geo/GeoCircle.ts:776

Creates a new small circle from a lat/long coordinate pair and radius.

Parameters

ParameterTypeDescription
pointReadonly<LatLonInterface>The center of the new small circle.
radiusnumberThe radius of the new small circle, in great-arc radians.

Returns

GeoCircle

a small circle.


createGreatCircle()

Call Signature

static createGreatCircle(point1, point2): GeoCircle

Defined in: src/sdk/geo/GeoCircle.ts:789

Creates a new great circle that includes two points and is parallel to the path from the first point to the second point. If the two points are coincident or antipodal, then the new circle will be set to an invalid circle with center coordinates equal to [NaN, NaN, NaN].

Parameters
ParameterTypeDescription
point1Readonly<Omit<Float64Array<ArrayBufferLike>, "set" | "sort" | "copyWithin">> | Readonly<LatLonInterface>The first point that lies on the new great circle.
point2Readonly<Omit<Float64Array<ArrayBufferLike>, "set" | "sort" | "copyWithin">> | Readonly<LatLonInterface>The second point that lies on the new great circle.
Returns

GeoCircle

A great circle that includes both specified points and is parallel to the path from the first point to the second point.

Call Signature

static createGreatCircle(point, bearing): GeoCircle

Defined in: src/sdk/geo/GeoCircle.ts:797

Creates a new great circle that includes a given point and is parallel to an initial bearing from the same point.

Parameters
ParameterTypeDescription
pointReadonly<Omit<Float64Array<ArrayBufferLike>, "set" | "sort" | "copyWithin">> | Readonly<LatLonInterface>A point that lies on the new great circle.
bearingnumberThe initial bearing from the point, in degrees.
Returns

GeoCircle

A great circle that includes the specified point and is parallel to the specified initial bearing from the same point.

Call Signature

static createGreatCircle(point, circle): GeoCircle

Defined in: src/sdk/geo/GeoCircle.ts:807

Creates a new great circle that is tangent and parallel to another GeoCircle at a given point. If the specified point does not lie exactly on the other GeoCircle, then the projection of the point onto the other GeoCircle will be used instead. If the point cannot be projected onto the GeoCircle, then the new circle will be set to an invalid circle with center coordinates equal to [NaN, NaN, NaN].

Parameters
ParameterTypeDescription
pointReadonly<Omit<Float64Array<ArrayBufferLike>, "set" | "sort" | "copyWithin">> | Readonly<LatLonInterface>The point at which the new great circle is tangent and parallel to the other circle.
circleReadonlyGeoCircleThe other GeoCircle.
Returns

GeoCircle

A great circle that is tangent and parallel to the specified other GeoCircle at the specified point.


createGreatCircleFromPointBearing()

static createGreatCircleFromPointBearing(point, bearing): GeoCircle

Defined in: src/sdk/geo/GeoCircle.ts:823

Creates a new great circle defined by one point and a bearing offset. The new great circle will be equivalent to the path projected from the point with the specified initial bearing (forward azimuth).

Parameters

ParameterTypeDescription
pointReadonly<Omit<Float64Array<ArrayBufferLike>, "set" | "sort" | "copyWithin">> | Readonly<LatLonInterface>A point that lies on the new great circle.
bearingnumberThe initial bearing from the point.

Returns

GeoCircle

a great circle.


getGreatCircleNormal()

Call Signature

static getGreatCircleNormal(point1, point2, out): Float64Array

Defined in: src/sdk/geo/GeoCircle.ts:838

Calculates a normal vector for a great circle that includes two given points and is parallel to the path from the first point to the second point. If the two points are coincident or antipodal, then NaN will be written to all components of the result.

Parameters
ParameterTypeDescription
point1Readonly<Omit<Float64Array<ArrayBufferLike>, "set" | "sort" | "copyWithin">> | Readonly<LatLonInterface>The first point that lies on the great circle.
point2Readonly<Omit<Float64Array<ArrayBufferLike>, "set" | "sort" | "copyWithin">> | Readonly<LatLonInterface>The second point that lies on the great circle.
outFloat64ArrayA 3D vector to which to write the result. The result will be written as the cartesian (x, y, z) representation, in units of great-arc radians.
Returns

Float64Array

The normal vector for the great circle that is tangent and parallel to the specified GeoCircle at the specified point.

Call Signature

static getGreatCircleNormal(point, bearing, out): Float64Array

Defined in: src/sdk/geo/GeoCircle.ts:853

Calculates a normal vector for a great circle that includes a given a point and is parallel to an initial bearing at the same point.

Parameters
ParameterTypeDescription
pointReadonly<Omit<Float64Array<ArrayBufferLike>, "set" | "sort" | "copyWithin">> | Readonly<LatLonInterface>A point that lies on the great circle.
bearingnumberThe initial bearing from the point.
outFloat64ArrayA 3D vector to which to write the result. The result will be written as the cartesian (x, y, z) representation, in units of great-arc radians.
Returns

Float64Array

The normal vector for the great circle that includes the specified point and is parallel to the specified bearing at that point.

Call Signature

static getGreatCircleNormal(point, circle, out): Float64Array

Defined in: src/sdk/geo/GeoCircle.ts:867

Calculates a normal vector for a great circle that is tangent and parallel to a GeoCircle at a given point. If the specified point does not lie exactly on the GeoCircle, then the projection of the point onto the GeoCircle will be used instead. If the point cannot be projected onto the GeoCircle, then NaN will be written to all components of the result.

Parameters
ParameterTypeDescription
pointReadonly<Omit<Float64Array<ArrayBufferLike>, "set" | "sort" | "copyWithin">> | Readonly<LatLonInterface>The point at which the great circle whose normal vector to calculate is tangent and parallel to the GeoCircle.
circleReadonlyGeoCircleA GeoCircle.
outFloat64ArrayA 3D vector to which to write the result. The result will be written as the cartesian (x, y, z) representation, in units of great-arc radians.
Returns

Float64Array

The normal vector for the great circle that is tangent and parallel to the specified GeoCircle at the specified point.