![]() |
mrs_lib
Various reusable classes, functions and utilities for use in MRS projects
|
Defines the cyclic class for calculations with cyclic quantities. More...
#include <cmath>#include <ostream>
Include dependency graph for cyclic.h:
This graph shows which files directly or indirectly include this file:Go to the source code of this file.
Classes | |
| struct | mrs_lib::geometry::cyclic< flt, spec > |
| Implementation of the a general cyclic value (such as angles in radians/degrees etc). More... | |
| struct | mrs_lib::geometry::radians |
| Convenience specialization of the cyclic class for unsigned radians (from $0$ to $2\pi$). More... | |
| struct | mrs_lib::geometry::sradians |
| Convenience specialization of the cyclic class for signed radians (from $-\pi$ to $\pi$). More... | |
| struct | mrs_lib::geometry::degrees |
| Convenience specialization of the cyclic class for unsigned degrees (from $0$ to $360$). More... | |
| struct | mrs_lib::geometry::sdegrees |
| Convenience specialization of the cyclic class for signed degrees (from $-180$ to $180$). More... | |
Namespaces | |
| namespace | mrs_lib |
| All mrs_lib functions, classes, variables and definitions are contained in this namespace. | |
Functions | |
| template<typename flt , class spec > | |
| bool | mrs_lib::geometry::operator< (const cyclic< flt, spec > &lhs, const cyclic< flt, spec > &rhs) |
| Implementation of the comparison operation between two angles. | |
| template<typename flt , class spec > | |
| bool | mrs_lib::geometry::operator> (const cyclic< flt, spec > &lhs, const cyclic< flt, spec > &rhs) |
| Implementation of the comparison operation between two angles. | |
| template<typename flt , class spec > | |
| std::ostream & | mrs_lib::geometry::operator<< (std::ostream &out, const cyclic< flt, spec > &ang) |
| Implementation of the stream output operator. | |
Defines the cyclic class for calculations with cyclic quantities.
| bool mrs_lib::geometry::operator< | ( | const cyclic< flt, spec > & | lhs, |
| const cyclic< flt, spec > & | rhs | ||
| ) |
Implementation of the comparison operation between two angles.
An angle is considered to be smaller than another angle if it is shorter - closer to zero.
| lhs | left-hand-side. |
| rhs | right-hand-side. |
| std::ostream & mrs_lib::geometry::operator<< | ( | std::ostream & | out, |
| const cyclic< flt, spec > & | ang | ||
| ) |
Implementation of the stream output operator.
| out | the stream to write the angle to. |
| ang | the angle to be written. |
| bool mrs_lib::geometry::operator> | ( | const cyclic< flt, spec > & | lhs, |
| const cyclic< flt, spec > & | rhs | ||
| ) |
Implementation of the comparison operation between two angles.
An angle is considered to be larger than another angle if it is longer - further from zero.
| lhs | left-hand-side. |
| rhs | right-hand-side. |