Vector.angles

Vector.angles(other)[source]

Compute both angles between this vector and another vector.

Parameters

other ([float, float, float] | compas.geometry.Vector) – The other vector.

Returns

tuple[float, float] – The angles between the two vectors, with the smallest angle first.

Examples

>>> u = Vector(1.0, 0.0, 0.0)
>>> v = Vector(0.0, 1.0, 0.0)
>>> u.angles(v)[0] == 0.5 * math.pi
True