Returns the angle from the origin to a coordinate.
Arguments:
Returns: number
The angle, in degrees, clockwise from the positive X
axis to
a .
|
code » | |||
Returns the difference between two coordinates as a new
goog.math.Coordinate.
Arguments:
|
code » | |||
Returns the distance between two coordinates.
Arguments:
|
code » | |||
Compares coordinates for equality.
Arguments:
Returns: boolean
True iff the coordinates are equal, or if both are null.
|
code » | |||
Returns the magnitude of a coordinate.
Arguments:
Returns: number
The distance between the origin and
a .
|
code » | |||
Returns the squared distance between two coordinates. Squared distances can
be used for comparisons when the actual value is not required.
Performance note: eliminating the square root is an optimization often used
in lower-level languages, but the speed difference is not nearly as
pronounced in JavaScript (only a few percent.)
Arguments:
|
code » | |||
Returns the sum of two coordinates as a new goog.math.Coordinate.
Arguments:
Returns: !goog.math.Coordinate
A Coordinate representing the sum of the two
coordinates.
|
code » |