PPL
1.2
|
An std::set of variables' indexes. More...
#include <Variables_Set_defs.hh>
Public Member Functions | |
Variables_Set () | |
Builds the empty set of variable indexes. More... | |
Variables_Set (const Variable v) | |
Builds the singleton set of indexes containing v.id() ;. More... | |
Variables_Set (const Variable v, const Variable w) | |
Builds the set of variables's indexes in the range from v.id() to w.id() . More... | |
dimension_type | space_dimension () const |
Returns the dimension of the smallest vector space enclosing all the variables whose indexes are in the set. More... | |
void | insert (Variable v) |
Inserts the index of variable v into the set. More... | |
bool | ascii_load (std::istream &s) |
Loads from s an ASCII representation (as produced by ascii_dump(std::ostream&) const) and sets *this accordingly. Returns true if successful, false otherwise. More... | |
memory_size_type | total_memory_in_bytes () const |
Returns the total size in bytes of the memory occupied by *this . More... | |
memory_size_type | external_memory_in_bytes () const |
Returns the size in bytes of the memory managed by *this . More... | |
bool | OK () const |
Checks if all the invariants are satisfied. More... | |
void | ascii_dump () const |
Writes to std::cerr an ASCII representation of *this . More... | |
void | ascii_dump (std::ostream &s) const |
Writes to s an ASCII representation of *this . More... | |
void | print () const |
Prints *this to std::cerr using operator<< . More... | |
Static Public Member Functions | |
static dimension_type | max_space_dimension () |
Returns the maximum space dimension a Variables_Set can handle. More... | |
Private Types | |
typedef std::set< dimension_type > | Base |
Related Functions | |
(Note that these are not member functions.) | |
std::ostream & | operator<< (std::ostream &s, const Variables_Set &vs) |
std::ostream & | operator<< (std::ostream &s, const Variables_Set &vs) |
Output operator. More... | |
An std::set of variables' indexes.
Definition at line 47 of file Variables_Set_defs.hh.
|
private |
Definition at line 50 of file Variables_Set_defs.hh.
|
inline |
Builds the empty set of variable indexes.
Definition at line 33 of file Variables_Set_inlines.hh.
|
inlineexplicit |
Builds the singleton set of indexes containing v.id()
;.
Definition at line 43 of file Variables_Set_inlines.hh.
References insert().
Builds the set of variables's indexes in the range from v.id()
to w.id()
.
If v.id() <= w.id()
, this constructor builds the set of variables' indexes v.id()
, v.id()+1
, ..., w.id()
. The empty set is built otherwise.
Definition at line 30 of file Variables_Set.cc.
References Parma_Polyhedra_Library::Variable::id(), and insert().
void Parma_Polyhedra_Library::Variables_Set::ascii_dump | ( | ) | const |
Writes to std::cerr
an ASCII representation of *this
.
void Parma_Polyhedra_Library::Variables_Set::ascii_dump | ( | std::ostream & | s | ) | const |
Writes to s
an ASCII representation of *this
.
Definition at line 65 of file Variables_Set.cc.
bool Parma_Polyhedra_Library::Variables_Set::ascii_load | ( | std::istream & | s | ) |
Loads from s
an ASCII representation (as produced by ascii_dump(std::ostream&) const) and sets *this
accordingly. Returns true
if successful, false
otherwise.
Definition at line 77 of file Variables_Set.cc.
|
inline |
Returns the size in bytes of the memory managed by *this
.
Definition at line 60 of file Variables_Set_inlines.hh.
Referenced by total_memory_in_bytes().
|
inline |
Inserts the index of variable v
into the set.
Definition at line 38 of file Variables_Set_inlines.hh.
References Parma_Polyhedra_Library::Variable::id().
Referenced by Parma_Polyhedra_Library::MIP_Problem::choose_branching_variable(), Parma_Polyhedra_Library::Polyhedron::drop_some_non_integer_points(), Parma_Polyhedra_Library::PIP_Solution_Node::generate_cut(), Parma_Polyhedra_Library::PIP_Solution_Node::update_tableau(), Variables_Set(), and Parma_Polyhedra_Library::Implementation::wrap_assign().
|
inlinestatic |
Returns the maximum space dimension a Variables_Set can handle.
Definition at line 49 of file Variables_Set_inlines.hh.
References Parma_Polyhedra_Library::Variable::max_space_dimension().
bool Parma_Polyhedra_Library::Variables_Set::OK | ( | ) | const |
Checks if all the invariants are satisfied.
Definition at line 38 of file Variables_Set.cc.
References Parma_Polyhedra_Library::Variable::OK().
void Parma_Polyhedra_Library::Variables_Set::print | ( | ) | const |
Prints *this
to std::cerr
using operator<<
.
|
inline |
Returns the dimension of the smallest vector space enclosing all the variables whose indexes are in the set.
Definition at line 54 of file Variables_Set_inlines.hh.
Referenced by Parma_Polyhedra_Library::MIP_Problem::add_to_integer_space_dimensions(), Parma_Polyhedra_Library::PIP_Problem::add_to_parameter_space_dimensions(), Parma_Polyhedra_Library::Expression_Hide_Last< T >::all_zeroes(), Parma_Polyhedra_Library::MIP_Problem::choose_branching_variable(), Parma_Polyhedra_Library::Box< ITV >::drop_some_non_integer_points(), Parma_Polyhedra_Library::Octagonal_Shape< T >::drop_some_non_integer_points(), Parma_Polyhedra_Library::BD_Shape< T >::drop_some_non_integer_points(), Parma_Polyhedra_Library::Grid::drop_some_non_integer_points(), Parma_Polyhedra_Library::Box< ITV >::fold_space_dimensions(), Parma_Polyhedra_Library::Octagonal_Shape< T >::fold_space_dimensions(), Parma_Polyhedra_Library::BD_Shape< T >::fold_space_dimensions(), Parma_Polyhedra_Library::Grid::fold_space_dimensions(), Parma_Polyhedra_Library::Polyhedron::fold_space_dimensions(), Parma_Polyhedra_Library::MIP_Problem::MIP_Problem(), Parma_Polyhedra_Library::PIP_Problem::PIP_Problem(), Parma_Polyhedra_Library::Linear_Expression_Impl< Row >::remove_space_dimensions(), Parma_Polyhedra_Library::Linear_System< Row >::remove_space_dimensions(), Parma_Polyhedra_Library::Grid_Generator::remove_space_dimensions(), Parma_Polyhedra_Library::Generator::remove_space_dimensions(), Parma_Polyhedra_Library::Box< ITV >::remove_space_dimensions(), Parma_Polyhedra_Library::Octagonal_Shape< T >::remove_space_dimensions(), Parma_Polyhedra_Library::BD_Shape< T >::remove_space_dimensions(), Parma_Polyhedra_Library::Grid::remove_space_dimensions(), Parma_Polyhedra_Library::Polyhedron::remove_space_dimensions(), Parma_Polyhedra_Library::Box< ITV >::unconstrain(), Parma_Polyhedra_Library::Polyhedron::unconstrain(), Parma_Polyhedra_Library::Octagonal_Shape< T >::unconstrain(), Parma_Polyhedra_Library::Grid::unconstrain(), Parma_Polyhedra_Library::BD_Shape< T >::unconstrain(), Parma_Polyhedra_Library::Implementation::wrap_assign(), Parma_Polyhedra_Library::Box< ITV >::wrap_assign(), and Parma_Polyhedra_Library::Grid::wrap_assign().
|
inline |
Returns the total size in bytes of the memory occupied by *this
.
Definition at line 69 of file Variables_Set_inlines.hh.
References external_memory_in_bytes().
|
related |
Output operator.
|
related |
Definition at line 50 of file Variables_Set.cc.