politopix
5.0.0
|
A n-coordinates generator for internal data structure. It can be a vertex or an edge whether it is embedded in a polytope or a polyhedral cone. It contains all of its support facets. More...
#include <Generator_Rn.h>
Public Types | |
enum | Status { UNCHANGED, MODIFIED, CREATED, CREATED_AND_MODIFIED, DELETED, UNKNOWN } |
Public Member Functions | |
Generator_Rn_SD (unsigned int n, unsigned int nb, Status st) | |
Creates a n-coordinates generator. More... | |
Generator_Rn_SD (const boost::numeric::ublas::vector< double > &coordinates, unsigned int nb) | |
Creates a n-coordinates generator. More... | |
Generator_Rn_SD (const Generator_Rn_SD &gn) | |
Copy constructor. More... | |
Generator_Rn_SD (const Generator_Rn &gn, unsigned int nb, Status st) | |
Constructor with a Generator_Rn. More... | |
Generator_Rn_SD () | |
Empty constructor. More... | |
~Generator_Rn_SD () | |
Destructor. More... | |
int | dimension () const |
void | init (unsigned int nb, Status st) |
boost::shared_ptr< Generator_Rn > | makeGenerator_Rn () const |
To make a Generator_Rn out of a Generator_Rn_SD. More... | |
void | setCoordinate (unsigned int i, double val) |
double | getCoordinate (unsigned int i) const |
void | setCoordinates (const vector< double > &vec) |
void | setGeneratorNumber (unsigned int gn) |
unsigned int | getGeneratorNumber () const |
void | setStatus (Status stu) |
The status is used for traceability through the operations and can be equal to: UNCHANGED,MODIFIED,CREATED,CREATED_AND_MODIFIED,DELETED,UNKNOWN. More... | |
Status | getStatus () const |
The status is used for traceability through the operations and can be equal to: UNCHANGED,MODIFIED,CREATED,CREATED_AND_MODIFIED,DELETED,UNKNOWN. More... | |
Status & | getStatus () |
void | setState (HalfSpace_Rn::State ste) |
The state of the generator SD with respect to a given half-space (hs_ON,hs_IN,hs_OUT,hs_UNKNOWN,hs_IN_OR_OUT) More... | |
void | setState (HalfSpace_Rn::State ste, double scalar_prod) |
void | resetState () |
HalfSpace_Rn::State | getState () const |
The state of the generator SD with respect to a given half-space (hs_ON,hs_IN,hs_OUT,hs_UNKNOWN,hs_IN_OR_OUT) More... | |
double | getScalarProduct () const |
void | setScalarProduct (double sp) |
vector< double >::const_iterator | begin () const |
vector< double >::const_iterator | end () const |
const vector< double > & | vect () const |
void | negate () |
bool | isEqual1 (const boost::shared_ptr< Generator_Rn_SD > &gn, unsigned int RnDIM, double TOL2) |
bool | isEqual2 (const boost::shared_ptr< Generator_Rn_SD > &gn, unsigned int RnDIM, double TOL2) |
bool | fuzzyFacets () const |
unsigned int | fuzzyFacetsSize () const |
void | setFuzzyFacet (unsigned int F) |
Insert a new fuzzy facet for the current generator. More... | |
void | setFacet (unsigned int F) |
Insert a new support facet in the current generator. More... | |
void | setFacets (const std::vector< unsigned int > &AF) |
Insert new support facets in the current generator at the end of the existing list. More... | |
void | setAllFacets (const std::vector< unsigned int > &AF) |
Insert new support facets in the current generator erasing the others. More... | |
const std::vector< unsigned int > & | getAllFacets () |
Return all support facets of the current generator. More... | |
void | importFacets (const std::set< unsigned int > &setOfFacets) |
Insert all facets stored in the argument. More... | |
void | exportFacets (std::set< unsigned int > &setOfFacets) const |
Store all facets in a set. More... | |
void | removeFacet (unsigned int i) |
Remove the i-th facet in list. More... | |
unsigned int | getFacet (unsigned int i) const |
Return the i-th facet number. More... | |
void | removeCurrentLinearConstraint (unsigned int LC) |
Remove the facet LC in list. More... | |
unsigned int | getRawFacet (unsigned int i) |
Return the i-th facet. No check is performed! More... | |
bool | isFacetInside (unsigned int F) const |
Check whether the given half-space is inside the generator's list. More... | |
unsigned int | numberOfFacets () const |
Return the total number of support faces. More... | |
void | orderFacets () |
std::vector< unsigned int >::const_iterator | facetsBegin () const |
std::vector< unsigned int >::const_iterator | facetsEnd () const |
std::vector< unsigned int >::const_iterator | fuzzyFacetsBegin () const |
std::vector< unsigned int >::const_iterator | fuzzyFacetsEnd () const |
void | makeDiff (const boost::shared_ptr< Generator_Rn_SD > &gn1, const boost::shared_ptr< Generator_Rn_SD > &gn2) |
void | makeSum (const boost::shared_ptr< Generator_Rn_SD > &gn1, const boost::shared_ptr< Generator_Rn_SD > &gn2) |
void | makeCoefSum (const boost::shared_ptr< Generator_Rn_SD > &gn1, const boost::shared_ptr< Generator_Rn_SD > &gn2, double coef1, double coef2) |
double | getNormalDistance (const boost::shared_ptr< Generator_Rn_SD > &gn1, double coef, unsigned int RnDIM) |
double | normalize () |
double | distanceFrom (const Generator_Rn_SD &P) |
void | dump (std::ostream &this_ostream) const |
void | load (std::istream &this_istream) |
void | save (std::ostream &this_ostream) const |
Protected Attributes | |
boost::numeric::ublas::vector< double > | _coordinates |
The set of coordinates. More... | |
std::vector< unsigned int > | _supportIntFacets |
The list of all support facets. More... | |
std::vector< unsigned int > | _fuzzyFacets |
The list of all fuzzy facets i.e. the facets whose distance to the current generator is close to the tolerance. More... | |
unsigned int | _generatorNumber |
The SD generator embeds its own number. More... | |
Status | _status |
The SD generator embeds its status to trace the operations (UNCHANGED,MODIFIED,CREATED,CREATED_AND_MODIFIED,DELETED,UNKNOWN) More... | |
HalfSpace_Rn::State | _currentState |
The state of the generator SD with respect to a given half-space (hs_ON,hs_IN,hs_OUT,hs_UNKNOWN,hs_IN_OR_OUT,hs_OUT_TO_ON) More... | |
double | _scalarProduct |
The scalar product with the current half-space. More... | |
Friends | |
class | Generator_Rn |
A n-coordinates generator for internal data structure. It can be a vertex or an edge whether it is embedded in a polytope or a polyhedral cone. It contains all of its support facets.
Definition at line 280 of file Generator_Rn.h.
Enumerator | |
---|---|
UNCHANGED | |
MODIFIED | |
CREATED | |
CREATED_AND_MODIFIED | |
DELETED | |
UNKNOWN |
Definition at line 285 of file Generator_Rn.h.
|
inline |
Creates a n-coordinates generator.
Definition at line 300 of file Generator_Rn.h.
|
inline |
Creates a n-coordinates generator.
Definition at line 307 of file Generator_Rn.h.
|
inline |
Copy constructor.
Definition at line 314 of file Generator_Rn.h.
|
inline |
Constructor with a Generator_Rn.
Definition at line 322 of file Generator_Rn.h.
|
inline |
Empty constructor.
Definition at line 328 of file Generator_Rn.h.
|
inline |
Destructor.
Definition at line 333 of file Generator_Rn.h.
|
inline |
Definition at line 384 of file Generator_Rn.h.
|
inline |
Definition at line 335 of file Generator_Rn.h.
|
inline |
Definition at line 547 of file Generator_Rn.h.
|
inline |
Definition at line 554 of file Generator_Rn.h.
|
inline |
Definition at line 386 of file Generator_Rn.h.
|
inline |
Store all facets in a set.
Definition at line 447 of file Generator_Rn.h.
|
inline |
Definition at line 506 of file Generator_Rn.h.
|
inline |
Definition at line 508 of file Generator_Rn.h.
|
inline |
Test if fuzzy facets exist in this generator. Fuzzy facets distance to the current generator is close to the tolerance.
Definition at line 418 of file Generator_Rn.h.
|
inline |
Definition at line 510 of file Generator_Rn.h.
|
inline |
Definition at line 512 of file Generator_Rn.h.
|
inline |
Definition at line 420 of file Generator_Rn.h.
|
inline |
Return all support facets of the current generator.
Definition at line 435 of file Generator_Rn.h.
|
inline |
|
inline |
Return the i-th facet number.
Definition at line 462 of file Generator_Rn.h.
|
inline |
Definition at line 361 of file Generator_Rn.h.
|
inline |
Return the square distance of the generator gn1 to the straight line defined by _coordinates and passing through the origin.
Definition at line 532 of file Generator_Rn.h.
|
inline |
Return the i-th facet. No check is performed!
Definition at line 489 of file Generator_Rn.h.
|
inline |
Definition at line 381 of file Generator_Rn.h.
|
inline |
The state of the generator SD with respect to a given half-space (hs_ON,hs_IN,hs_OUT,hs_UNKNOWN,hs_IN_OR_OUT)
Definition at line 380 of file Generator_Rn.h.
|
inline |
Definition at line 368 of file Generator_Rn.h.
|
inline |
The status is used for traceability through the operations and can be equal to: UNCHANGED,MODIFIED,CREATED,CREATED_AND_MODIFIED,DELETED,UNKNOWN.
Definition at line 367 of file Generator_Rn.h.
|
inline |
Insert all facets stored in the argument.
Definition at line 438 of file Generator_Rn.h.
|
inline |
Definition at line 337 of file Generator_Rn.h.
|
inline |
|
inline |
|
inline |
Check whether the given half-space is inside the generator's list.
Definition at line 492 of file Generator_Rn.h.
|
inline |
|
inline |
Definition at line 522 of file Generator_Rn.h.
|
inline |
Definition at line 514 of file Generator_Rn.h.
|
inline |
To make a Generator_Rn out of a Generator_Rn_SD.
Definition at line 347 of file Generator_Rn.h.
|
inline |
Definition at line 518 of file Generator_Rn.h.
|
inline |
Definition at line 390 of file Generator_Rn.h.
|
inline |
Definition at line 541 of file Generator_Rn.h.
|
inline |
Return the total number of support faces.
Definition at line 502 of file Generator_Rn.h.
|
inline |
Definition at line 504 of file Generator_Rn.h.
|
inline |
Remove the facet LC in list.
Definition at line 473 of file Generator_Rn.h.
|
inline |
Remove the i-th facet in list.
Definition at line 455 of file Generator_Rn.h.
|
inline |
Definition at line 377 of file Generator_Rn.h.
|
inline |
|
inline |
Insert new support facets in the current generator erasing the others.
Definition at line 432 of file Generator_Rn.h.
|
inline |
|
inline |
Definition at line 357 of file Generator_Rn.h.
|
inline |
Insert a new support facet in the current generator.
Definition at line 426 of file Generator_Rn.h.
|
inline |
Insert new support facets in the current generator at the end of the existing list.
Definition at line 429 of file Generator_Rn.h.
|
inline |
Insert a new fuzzy facet for the current generator.
Definition at line 423 of file Generator_Rn.h.
|
inline |
Definition at line 359 of file Generator_Rn.h.
|
inline |
Definition at line 382 of file Generator_Rn.h.
|
inline |
The state of the generator SD with respect to a given half-space (hs_ON,hs_IN,hs_OUT,hs_UNKNOWN,hs_IN_OR_OUT)
Definition at line 371 of file Generator_Rn.h.
|
inline |
Definition at line 372 of file Generator_Rn.h.
|
inline |
The status is used for traceability through the operations and can be equal to: UNCHANGED,MODIFIED,CREATED,CREATED_AND_MODIFIED,DELETED,UNKNOWN.
Definition at line 364 of file Generator_Rn.h.
|
inline |
Definition at line 388 of file Generator_Rn.h.
|
friend |
Definition at line 281 of file Generator_Rn.h.
|
protected |
The set of coordinates.
Definition at line 588 of file Generator_Rn.h.
|
protected |
The state of the generator SD with respect to a given half-space (hs_ON,hs_IN,hs_OUT,hs_UNKNOWN,hs_IN_OR_OUT,hs_OUT_TO_ON)
Definition at line 600 of file Generator_Rn.h.
|
protected |
The list of all fuzzy facets i.e. the facets whose distance to the current generator is close to the tolerance.
Definition at line 592 of file Generator_Rn.h.
|
protected |
The SD generator embeds its own number.
Definition at line 596 of file Generator_Rn.h.
|
protected |
The scalar product with the current half-space.
Definition at line 602 of file Generator_Rn.h.
|
protected |
The SD generator embeds its status to trace the operations (UNCHANGED,MODIFIED,CREATED,CREATED_AND_MODIFIED,DELETED,UNKNOWN)
Definition at line 598 of file Generator_Rn.h.
|
protected |
The list of all support facets.
Definition at line 590 of file Generator_Rn.h.