irafhy
Interval arithmetic based Reachability Analysis Framework for Hybrid Automaton
irafhy::IntervalHull Class Reference

#include <intervalHull.h>

Inheritance diagram for irafhy::IntervalHull:
Inheritance graph
Collaboration diagram for irafhy::IntervalHull:
Collaboration graph

Public Member Functions

 IntervalHull ()
 default constructor More...
 
 IntervalHull (const IntervalHull &intervalHull)=default
 copy constructor with given interval hull More...
 
 IntervalHull (IntervalHull &&intervalHull) noexcept=default
 move constructor with given interval hull More...
 
 IntervalHull (const std::vector< capd::interval > &constraints)
 constructor with given constraints More...
 
 IntervalHull (const std::vector< Point > &points)
 constructor with given points More...
 
 IntervalHull (const Point &center, double radius)
 constructor with one given center and related radius which can specify the variance of each dimension More...
 
 IntervalHull (const capd::C0Rect2Set &set)
 constructor with given state set More...
 
 IntervalHull (const Eigen::VectorXd &center, double radius)
 constructor with given coordinate of the center and related radius More...
 
 ~IntervalHull () override=default
 destructor More...
 
std::vector< capd::interval > constraints () const
 get the constraints of the interval hull More...
 
bool empty () const override
 check if the interval hull is empty or not More...
 
int dimension () const override
 get the dimension of the space which the interval hull in More...
 
std::vector< PointextremeVertices () const
 get the extreme vertices of the interval hull More...
 
Point randInnerPoint () const
 randomly sample a point from the domain defined by the interval hull More...
 
Point centroid () const
 get the centroid of the interval hull More...
 
bool intersect (const IntervalHull &rhs, IntervalHull &result) const override
 check if the current interval hull intersects with the right hand side interval hull or not More...
 
IntervalHull unite (const IntervalHull &rhs) const override
 get the union of the current interval hull and right hand side interval hull More...
 
bool contains (const Point &point) const override
 check if the given point inside the domain defined by the interval hull or not More...
 
bool contains (const Eigen::VectorXd &coordinate) const override
 check if the given coordinate inside the domain defined by the interval hull or not More...
 
bool contains (const IntervalHull &rhs) const
 check if the given interval hull inside the current interval hull or not More...
 
capd::interval & operator[] (std::size_t index)
 get the constraint of specified dimension More...
 
const capd::interval & operator[] (std::size_t index) const
 get the constraint of specified dimension More...
 
bool operator== (const IntervalHull &rhs) const
 relational operator More...
 
bool operator!= (const IntervalHull &rhs) const
 relational operator More...
 
bool operator< (const IntervalHull &rhs) const
 relational operator More...
 
bool operator<= (const IntervalHull &rhs) const
 relational operator More...
 
bool operator> (const IntervalHull &rhs) const
 relational operator More...
 
bool operator>= (const IntervalHull &rhs) const
 relational operator More...
 
IntervalHulloperator= (const IntervalHull &rhs)=default
 assignment operator More...
 
IntervalHulloperator= (IntervalHull &&rhs)=default
 assignment operator More...
 
- Public Member Functions inherited from irafhy::Geometry< IntervalHull >
virtual ~Geometry ()=default
 destructor More...
 

Static Public Member Functions

static IntervalHull Empty (std::size_t dimension=0)
 static constructor of Empty interval hull in specified space More...
 

Private Attributes

std::vector< capd::interval > constraints_
 interval constraints of each dimension related entries More...
 

Constructor & Destructor Documentation

◆ IntervalHull() [1/8]

irafhy::IntervalHull::IntervalHull ( )

default constructor

References constraints_.

Referenced by Empty(), intersect(), and unite().

◆ IntervalHull() [2/8]

irafhy::IntervalHull::IntervalHull ( const IntervalHull intervalHull)
default

copy constructor with given interval hull

Parameters
intervalHullgiven interval hull

◆ IntervalHull() [3/8]

irafhy::IntervalHull::IntervalHull ( IntervalHull &&  intervalHull)
defaultnoexcept

move constructor with given interval hull

Parameters
intervalHullgiven interval hull

◆ IntervalHull() [4/8]

irafhy::IntervalHull::IntervalHull ( const std::vector< capd::interval > &  constraints)
explicit

constructor with given constraints

Parameters
constraintsgiven constraints

References constraints(), and constraints_.

Here is the call graph for this function:

◆ IntervalHull() [5/8]

irafhy::IntervalHull::IntervalHull ( const std::vector< Point > &  points)
explicit

constructor with given points

Parameters
pointsgiven points

References constraints_, and dimension().

Here is the call graph for this function:

◆ IntervalHull() [6/8]

irafhy::IntervalHull::IntervalHull ( const Point center,
double  radius 
)

constructor with one given center and related radius which can specify the variance of each dimension

Parameters
centerpoint which specify the center of the interval hull
radiusgiven radius

References constraints_, irafhy::Point::dimension(), and irafhy::Point::empty().

Here is the call graph for this function:

◆ IntervalHull() [7/8]

irafhy::IntervalHull::IntervalHull ( const capd::C0Rect2Set &  set)
explicit

constructor with given state set

Parameters
setgiven state set

References constraints_, and dimension().

Here is the call graph for this function:

◆ IntervalHull() [8/8]

irafhy::IntervalHull::IntervalHull ( const Eigen::VectorXd &  center,
double  radius 
)

constructor with given coordinate of the center and related radius

Parameters
centercoordinate of the center
radiusgvien radius

References constraints_.

◆ ~IntervalHull()

irafhy::IntervalHull::~IntervalHull ( )
overridedefault

destructor

Member Function Documentation

◆ centroid()

Point irafhy::IntervalHull::centroid ( ) const

get the centroid of the interval hull

Returns
the centroid of the interal hull

References constraints_, and dimension().

Here is the call graph for this function:

◆ constraints()

std::vector< capd::interval > irafhy::IntervalHull::constraints ( ) const

◆ contains() [1/3]

bool irafhy::IntervalHull::contains ( const Point point) const
overridevirtual

check if the given point inside the domain defined by the interval hull or not

Parameters
pointthe given point
Returns
TRUE if the given point inside the domain defined by the interval hull

Implements irafhy::Geometry< IntervalHull >.

References constraints_, irafhy::Point::dimension(), and dimension().

Referenced by contains().

Here is the call graph for this function:

◆ contains() [2/3]

bool irafhy::IntervalHull::contains ( const Eigen::VectorXd &  coordinate) const
overridevirtual

check if the given coordinate inside the domain defined by the interval hull or not

Parameters
coordinatethe given coordinate
Returns
TRUE if the given coordinate inside the domain defined by the interval hull

Implements irafhy::Geometry< IntervalHull >.

References constraints_, contains(), and dimension().

Here is the call graph for this function:

◆ contains() [3/3]

bool irafhy::IntervalHull::contains ( const IntervalHull rhs) const

check if the given interval hull inside the current interval hull or not

Parameters
rhsright hand side interval hull
Returns
TRUE if the given interval hull inside the current interval hull

References constraints(), constraints_, and dimension().

Here is the call graph for this function:

◆ dimension()

int irafhy::IntervalHull::dimension ( ) const
overridevirtual

◆ Empty()

IntervalHull irafhy::IntervalHull::Empty ( std::size_t  dimension = 0)
static

static constructor of Empty interval hull in specified space

Parameters
dimensiondimension of the space which the interval hull in
Returns
resulting Empty interval hull

References IntervalHull().

Referenced by irafhy::Condition::Condition(), irafhy::Condition::Empty(), irafhy::Condition::intersect(), and intersect().

Here is the call graph for this function:

◆ empty()

bool irafhy::IntervalHull::empty ( ) const
overridevirtual

check if the interval hull is empty or not

Returns
TRUE if the interval hull's volume is zero or has empty constraints

Implements irafhy::Geometry< IntervalHull >.

References constraints_, and dimension().

Referenced by intersect(), irafhy::viewer::intervalHullMatrix(), and unite().

Here is the call graph for this function:

◆ extremeVertices()

std::vector< Point > irafhy::IntervalHull::extremeVertices ( ) const

get the extreme vertices of the interval hull

Returns
the extreme vertices of the interval hull

References constraints_, and dimension().

Here is the call graph for this function:

◆ intersect()

bool irafhy::IntervalHull::intersect ( const IntervalHull rhs,
IntervalHull result 
) const
overridevirtual

check if the current interval hull intersects with the right hand side interval hull or not

Parameters
rhsright hand side interval hull
resultintersection of two interval hulls if exists
Returns
TRUE if the intersection isn't empty

Implements irafhy::Geometry< IntervalHull >.

References constraints(), constraints_, dimension(), Empty(), empty(), and IntervalHull().

Referenced by irafhy::Condition::intersect().

Here is the call graph for this function:

◆ operator!=()

bool irafhy::IntervalHull::operator!= ( const IntervalHull rhs) const

relational operator

Parameters
rhsright hand side interval hull
Returns
TRUE if the current interval hull does not equal to the given one

◆ operator<()

bool irafhy::IntervalHull::operator< ( const IntervalHull rhs) const

relational operator

Parameters
rhsright hand side interval hull
Returns
FALSE if the there exist at least one dimension in which the constraint of current interval hull is greater than or equal to the right hand side one's

References constraints(), constraints_, and dimension().

Here is the call graph for this function:

◆ operator<=()

bool irafhy::IntervalHull::operator<= ( const IntervalHull rhs) const

relational operator

Parameters
rhsright hand side interval hull
Returns
FALSE if the there exist at least one dimension in which the constraint of current interval hull is greater than the right hand side one's

References constraints(), constraints_, and dimension().

Here is the call graph for this function:

◆ operator=() [1/2]

IntervalHull& irafhy::IntervalHull::operator= ( const IntervalHull rhs)
default

assignment operator

Parameters
rhsright hand side interval hull
Returns
resulting interval hull

◆ operator=() [2/2]

IntervalHull& irafhy::IntervalHull::operator= ( IntervalHull &&  rhs)
default

assignment operator

Parameters
rhsright hand side interval hull
Returns
resulting interval hull

◆ operator==()

bool irafhy::IntervalHull::operator== ( const IntervalHull rhs) const

relational operator

Parameters
rhsright hand side interval hull
Returns
TRUE if the two interval hulls equal to each other

References constraints(), constraints_, and dimension().

Here is the call graph for this function:

◆ operator>()

bool irafhy::IntervalHull::operator> ( const IntervalHull rhs) const

relational operator

Parameters
rhsright hand side interval hull
Returns
FALSE if there exist at least one dimension in which the constraint of current interval hull is less than or equal to the right hand side one's

◆ operator>=()

bool irafhy::IntervalHull::operator>= ( const IntervalHull rhs) const

relational operator

Parameters
rhsright hand side interval hull
Returns
FALSE if there exist at least one dimension in which the constraint of current interval hull less than the right hand side one's

◆ operator[]() [1/2]

capd::interval & irafhy::IntervalHull::operator[] ( std::size_t  index)

get the constraint of specified dimension

Parameters
indexindex of the dimension
Returns
the constraint of given dimension in interval form

References constraints_.

◆ operator[]() [2/2]

const capd::interval & irafhy::IntervalHull::operator[] ( std::size_t  index) const

get the constraint of specified dimension

Parameters
indexindex of the dimension
Returns
the constraint of given dimension in interval form

References constraints_.

◆ randInnerPoint()

Point irafhy::IntervalHull::randInnerPoint ( ) const

randomly sample a point from the domain defined by the interval hull

Returns
resulting point which randomly sampled from the domain defined by the interval hull

◆ unite()

IntervalHull irafhy::IntervalHull::unite ( const IntervalHull rhs) const
overridevirtual

get the union of the current interval hull and right hand side interval hull

Parameters
rhsright hand side interval hull
Returns
the union of two interval hulls

Implements irafhy::Geometry< IntervalHull >.

References constraints(), constraints_, dimension(), empty(), and IntervalHull().

Referenced by irafhy::Condition::unite().

Here is the call graph for this function:

Member Data Documentation

◆ constraints_

std::vector<capd::interval> irafhy::IntervalHull::constraints_
private

interval constraints of each dimension related entries

Referenced by centroid(), constraints(), contains(), dimension(), empty(), extremeVertices(), intersect(), IntervalHull(), operator<(), operator<=(), operator==(), operator[](), and unite().


The documentation for this class was generated from the following files: