4#include "RaidZeroLib/api/Units/Units.hpp"
26 constexpr Point() noexcept = default;
82 Point operator-() const noexcept;
90 Point operator*(
double scalar) const noexcept;
100 Point operator/(
double scalar) const noexcept;
Immutable 2D point / vector with unit-safe Cartesian coordinates.
Definition Point.hpp:21
bool isApprox(const Point &rhs) const noexcept
Approximate equality in Euclidean metric.
Length mag() const noexcept
Magnitude (Euclidean norm).
Length distTo(const Point &rhs) const noexcept
Euclidean distance to another point.
Point rotateBy(const Rotation &rhs) const noexcept
Rotates this point by a Rotation about the origin.
Length Y() const noexcept
Y coordinate.
Point project(const Point &rhs) const noexcept
Projection of this vector onto another.
Angle theta() const noexcept
Direction (heading) of the vector in radians.
Area dot(const Point &rhs) const noexcept
Dot (inner) product.
Area wedge(const Point &rhs) const noexcept
2D wedge (scalar cross) product.
Angle angleTo(const Point &rhs) const noexcept
Signed smallest-angle direction from this point’s heading to another’s.
constexpr Point() noexcept=default
Constructs the origin (0 m, 0 m).
Length X() const noexcept
X coordinate.
Immutable planar rotation about the Z axis.
Definition Rotation.hpp:16
Length circumradius(const Point &A, const Point &B, const Point &C) noexcept
Circumradius of the triangle defined by three points.
std::optional< double > circleLineIntersection(const Point &start, const Point &end, const Point ¢er, Length radius) noexcept
Intersection of a circle with a line segment.
void start(RobotConfig config)
Starts RaidZeroLib on the brain. Call once from initialize().
au::QuantityD< au::Squared< au::Meters > > Area
Definition Units.hpp:10
au::QuantityD< au::Radians > Angle
Definition Units.hpp:13
au::QuantityD< au::Meters > Length
Definition Units.hpp:9
Definition DriverControl.hpp:11