Hermes
|
Represents a numeric interval that supports interval arithmetic. More...
Public Member Functions | |
HERMES_DEVICE_CALLABLE | Interval () |
Default constructor. | |
HERMES_DEVICE_CALLABLE | Interval (T v) |
Constructs from center value. More... | |
HERMES_DEVICE_CALLABLE | Interval (T l, T h) |
Construct from interval values. More... | |
HERMES_DEVICE_CALLABLE | operator T () const |
Gets interval center value. More... | |
HERMES_DEVICE_CALLABLE Interval | operator- () const |
Negates interval. More... | |
HERMES_DEVICE_CALLABLE Interval | operator+ (const Interval &i) const |
Uses interval arithmetic addition. More... | |
HERMES_DEVICE_CALLABLE Interval | operator- (const Interval &i) const |
Uses interval arithmetic subtraction. More... | |
HERMES_DEVICE_CALLABLE Interval | operator* (const Interval &i) const |
Uses interval arithmetic multiplication. More... | |
HERMES_DEVICE_CALLABLE Interval | operator/ (const Interval &i) const |
Uses interval arithmetic division. More... | |
HERMES_DEVICE_CALLABLE bool | operator== (const Interval< T > &b) const |
HERMES_DEVICE_CALLABLE bool | contains (T v) const |
Checks if this interval contains v. More... | |
HERMES_DEVICE_CALLABLE T | center () const |
Gets interval center value. More... | |
HERMES_DEVICE_CALLABLE T | radius () const |
Gets interval radius. More... | |
HERMES_DEVICE_CALLABLE T | width () const |
Gets interval diameter. More... | |
HERMES_DEVICE_CALLABLE bool | isExact () const |
Checks if interval contains a single value. More... | |
HERMES_DEVICE_CALLABLE Interval | sqr () const |
Computes arithmetic interval square. More... | |
HERMES_DEVICE_CALLABLE Interval | sqrt () const |
Computes arithmetic interval square root. More... | |
Static Public Member Functions | |
static HERMES_DEVICE_CALLABLE Interval | withRadius (real_t c, real_t r) |
Constructs interval from center and radius. More... | |
Static Public Member Functions inherited from hermes::MathElement< T, 2u > | |
static constexpr u64 | componentCount () |
Gets the number of dimensional components. More... | |
static constexpr u64 | numericTypeSizeInBytes () |
Gets the size in bytes of underlying data type. More... | |
static MemoryDumper::RegionLayout | memoryDumpLayout () |
Gets memory layout. More... | |
Public Attributes | |
T | low {0} |
lowest interval value | |
T | high {0} |
greatest interval value | |
Additional Inherited Members | |
Static Public Attributes inherited from hermes::MathElement< T, 2u > | |
static T | numeric_data |
Underlying data type. | |
Represents a numeric interval that supports interval arithmetic.
|
inline |
Constructs from center value.
v |
|
inline |
Construct from interval values.
l | |
h |
|
inline |
Gets interval center value.
|
inline |
Checks if this interval contains v.
v |
|
inline |
Checks if interval contains a single value.
|
inlineexplicit |
Gets interval center value.
|
inline |
Uses interval arithmetic multiplication.
i |
|
inline |
Uses interval arithmetic addition.
i |
|
inline |
Negates interval.
|
inline |
Uses interval arithmetic subtraction.
i |
|
inline |
Uses interval arithmetic division.
i |
|
inline |
Gets interval radius.
|
inline |
Computes arithmetic interval square.
|
inline |
Computes arithmetic interval square root.
|
inline |
Gets interval diameter.
|
inlinestatic |
Constructs interval from center and radius.
c | |
r |