24 #ifndef PPL_PIP_Problem_templates_hh
25 #define PPL_PIP_Problem_templates_hh 1
31 template <
typename In>
35 : external_space_dim(dim),
36 internal_space_dim(0),
37 status(PARTIALLY_SATISFIABLE),
40 first_pending_constraint(0),
48 s <<
"PPL::PIP_Problem::PIP_Problem(dim, first, last, p_vars):\n"
50 <<
" and p_vars.space_dimension() == "
52 <<
" are dimension incompatible.";
53 throw std::invalid_argument(s.str());
58 throw std::length_error(
"PPL::PIP_Problem::"
59 "PIP_Problem(dim, first, last, p_vars):\n"
60 "dim exceeds the maximum allowed "
64 for (In i = first; i != last; ++i) {
65 if (i->space_dimension() > dim) {
67 s <<
"PPL::PIP_Problem::"
68 <<
"PIP_Problem(dim, first, last, p_vars):\n"
69 <<
"range [first, last) contains a constraint having space "
70 <<
"dimension == " << i->space_dimension()
71 <<
" that exceeds this->space_dimension == " << dim <<
".";
72 throw std::invalid_argument(s.str());
82 #endif // !defined(PPL_PIP_Problem_templates_hh)
dimension_type space_dimension() const
Returns the dimension of the smallest vector space enclosing all the variables whose indexes are in t...
static dimension_type max_space_dimension()
Returns the maximum space dimension a PIP_Problem can handle.
size_t dimension_type
An unsigned integral type for representing space dimensions.
PIP_Problem(dimension_type dim=0)
Builds a trivial PIP problem.
An std::set of variables' indexes.
dimension_type not_a_dimension()
Returns a value that does not designate a valid dimension.
dimension_type external_space_dim
The dimension of the vector space.
bool OK() const
Checks if all the invariants are satisfied.
void control_parameters_init()
Initializes the control parameters with default values.
Constraint_Sequence input_cs
The sequence of constraints describing the feasible region.
The entire library is confined to this namespace.