![]() |
Fréchet View
1.6.0
A Tool for Exploring Fréchet Distance Algorithms
|
attaches a component ID to an interval
In the k-Frechet algorithm, components are projected to domain axes. The MappedInterval class represents such a projection with the associated component identifier.
Definition at line 32 of file kalgorithm.h.
#include <kalgorithm.h>
Inherits frechet::data::Interval.
Public Member Functions | |
MappedInterval () | |
empty constructor; creates an invalid interval More... | |
MappedInterval (const Interval &ival, int compID) | |
default constructor More... | |
bool | operator< (const MappedInterval &that) const |
comparison operator, needed for sorting a list of MappedInterval objects. We first compare the lower bounds of both intervals. Next, we compare the upper bounds in reversed order (i.e. larger intervals are sorted in front of smaller ones) Thirdly, we compare compoent IDs. More... | |
bool | operator== (const MappedInterval &that) const |
equality operator, needed for sorting a list of MappedInterval objects. More... | |
![]() | |
Interval () | |
Default constructor. Creates an invalid Interval. More... | |
Interval (double lower, double upper) | |
Constructor from boundary values. More... | |
Interval (const Interval &that) | |
Copy constructor. More... | |
Interval (const Interval &that, double shift) | |
Copy constructor with shift offset. More... | |
double | size () const |
size of the interval (upper - lower). More... | |
bool | valid () const |
validity test More... | |
bool | empty () const |
empty test More... | |
operator bool () const | |
bool | operator! () const |
double | lower () const |
double | upper () const |
double & | lower () |
double & | upper () |
Interval & | setLower (double value) |
update lower bound More... | |
Interval & | setUpper (double value) |
update upper bound More... | |
double | mid () const |
Interval & | operator= (const Interval &that) |
assignment operator More... | |
bool | operator== (const Interval &that) const |
equality comparator More... | |
bool | equals (const Interval &that, double precision) const |
equalality comparator with tolerance More... | |
bool | operator!= (const Interval &that) const |
non-equality comparator More... | |
Interval | normalized () const |
normalized More... | |
Interval & | normalize () |
make sure that lower <= upper, swapping bounds, if necessary More... | |
Interval & | clear () |
make this an invalid interval More... | |
bool | contains (double x) const |
containment test (assumes closed interval, bounds inclusive) More... | |
bool | contains (double x, double precision) const |
containment test with tolerance (assumes closed interval, bounds inclusive) More... | |
bool | contains (const Interval &that) const |
containment test (closed interval, bounds inclusive) More... | |
bool | intersects (const Interval &that) const |
intersection test (closed interval, bounds inclusive) More... | |
bool | intersects_proper (const Interval &that) const |
intersection test (open interval, bounds exclusive) More... | |
bool | bordersTo (const Interval &that) const |
adjacency test More... | |
double | mapToUnitInterval (double x) const |
re-map a value from this interval to the unit interval More... | |
double | mapFromUnitInterval (double x) const |
re-map a value from the unit interval to this interval More... | |
double | mapTo (double x, const Interval &other) const |
re-map a value to another interval More... | |
double | mapFrom (double x, const Interval &other) const |
re-map a value from another interval to this interval More... | |
Interval | operator+ (double offset) const |
shift the interval by a fixed offset More... | |
Interval & | operator+= (double offset) |
shift the interval by a fixed offset More... | |
Interval | operator- (double offset) const |
shift the interval by a fixed offset More... | |
Interval & | operator-= (double offset) |
shift the interval by a fixed offset More... | |
Interval | operator * (double factor) const |
multiply by a factor More... | |
Interval & | operator *= (double factor) |
multiply by a factor More... | |
Interval | operator/ (double factor) const |
divide by a factor More... | |
Interval & | operator/= (double factor) |
multiply by a factor More... | |
Interval | operator+ (const Interval &that) const |
union operator More... | |
Interval & | operator+= (const Interval &that) |
union operator More... | |
Interval | operator- (const Interval &that) const |
difference operator More... | |
Interval | operator-= (const Interval &that) |
difference operator More... | |
Interval | operator & (const Interval &that) const |
intersection operator More... | |
Interval & | operator&= (const Interval &that) |
intersection operator More... | |
Interval & | union_lf (const Interval &that) |
lock-free union operator; not used and not tested More... | |
Public Attributes | |
int | componentID |
Additional Inherited Members | |
![]() | |
static bool | equals (double a, double b) |
equality comparator More... | |
![]() | |
static const Interval | UNIT |
the unit interval [0,1] More... | |
static const Interval | INVALID = Interval () |
an invalid interval (contains NAN values) More... | |
|
inline |
empty constructor; creates an invalid interval
Definition at line 39 of file kalgorithm.h.
|
inline |
default constructor
ival | a projection of a component to a domain axis |
compID | the associated component identifier |
Definition at line 47 of file kalgorithm.h.
bool MappedInterval::operator< | ( | const MappedInterval & | that | ) | const |
comparison operator, needed for sorting a list of MappedInterval objects. We first compare the lower bounds of both intervals. Next, we compare the upper bounds in reversed order (i.e. larger intervals are sorted in front of smaller ones) Thirdly, we compare compoent IDs.
that | object to compare with |
Definition at line 494 of file kalgorithm.cpp.
bool MappedInterval::operator== | ( | const MappedInterval & | that | ) | const |
equality operator, needed for sorting a list of MappedInterval objects.
that | object to compare with |
Definition at line 508 of file kalgorithm.cpp.
int frechet::k::MappedInterval::componentID |
unique identifier of the component
Definition at line 36 of file kalgorithm.h.