13 #ifndef CouenneFPpool_hpp
14 #define CouenneFPpool_hpp
19 #include "CoinFinite.hpp"
25 class CouenneFeasPump;
65 const int n ()
const {
return n_;}
68 const double *
x ()
const {
return x_;}
96 std::set <CouenneFPsolution, compareSol>
set_;
114 std::set <CouenneFPsolution, compareSol> &
Set ()
~CouenneFPsolution()
destructor
CouenneFPsolution(CouenneProblem *p, CouNumber *x, bool copied=false)
CouenneProblem-aware constructor.
CouNumber maxNLinf_
maximum NL infeasibility
bool operator()(const CouenneFPsolution &one, const CouenneFPsolution &two) const
compare, base version
std::set< CouenneFPsolution, compareSol > & Set()
return the main object in this class
bool compare(const CouenneFPsolution &other, enum what_to_compare comparedTerm) const
basic comparison procedure – what to compare depends on user's choice
class for comparing solutions (used in tabu list)
int n_
number of variables (for independence from CouenneProblem)
int nNLinf_
number of NL infeasibilities
what_to_compare
what term to compare: the sum of infeasibilities, the sum of numbers of infeasible terms...
CouenneFPsolution & operator=(const CouenneFPsolution &src)
assignment
Class containing a solution with infeasibility evaluation.
void findClosestAndReplace(double *&sol, const double *nSol, int nvars)
finds, in pool, solution x closest to sol; removes it from the pool and overwrites it to sol ...
CouenneFPpool(CouenneProblem *p, enum what_to_compare c)
simple constructor (empty pool)
CouenneFPpool & operator=(const CouenneFPpool &src)
assignment
static enum Couenne::what_to_compare comparedTerm_
bool copied_
This is a temporary copy, not really a solution holder.
CouenneProblem * problem_
Problem pointer.
const int n() const
returns size
Class for MINLP problems with symbolic information.
const double * x() const
returns vector
CouenneProblem * Problem()
return the problem pointer
double CouNumber
main number type in Couenne
CouNumber objVal_
objective function value
int nIinf_
number of integer infeasibilities
std::set< CouenneFPsolution, compareSol > set_
Pool.
CouenneProblem * problem_
holds pointer to problem to check integrality in comparison of integer variables
CouNumber maxIinf_
maximum integer infeasibility
bool operator<(const CouenneScalar &first, const CouenneScalar &second)