|(require wy-posn-util)||package: wy-posn-util|
This package implements a stack of functions for working with "posn"s.
True when two posns have the same coordinates.
Sum each coordinate separately.
Coordinates of p minus the coordinates of q.
Multiply each coordinate of p by the same number k.
The Euclidean distance between the points specified by p and q.
Place img at the coordinates specified by pt on the bg image.
The length of the vector p.
The square of the length of the vector p. This will be an integer if the coordinates of p are integers.
True if each of the corresponding components of p and q are within eps of each other.
The posn p rescaled so it is of unit length.
The dot product.
The projection of p on q. This is the length of the shadow of p on q when the sun shines perpendicular to q.
The angle between the vectors, in radians. Uses acos.
The angle between the vectors, in degrees. Uses acos.
Convert from rectangular to polar representation (radius, angle).
Convert from polar representation (radius, angle) to rectangular (x,y).