#include <CutGen.hpp>

Public Member Functions | |
| CutGen (const int, const int, const int, const double, const double *, const double *, const double **, const double **, const double *, const char *, const double *, const double *, const double *, const double *, OsiSolverInterface *si, Timer *globaltimer, Tracer *tracer) | |
| ~CutGen () | |
| CutGen * | clone () const |
| sparsify_trace | get_sparsify_trace () |
| double | currObj () const |
| double | bestObj () const |
| double * | bestSol () const |
| void | set_max_nb_cuts (const int max_c) |
| void | generateCuts (const OsiSolverInterface &, OsiCuts &, const CglTreeInfo=CglTreeInfo()) const |
| void | updateSol () |
| void | setIter (int iter) |
Private Member Functions | |
| void | compareSparsify (const OsiSolverInterface &si, int n, int m, const double *sol, double *z, double *w, FILE *out) const |
| void | sparsify2 (const int n, const double *sol, double **sparse_v_mat, int *card_v_mat, int min_nz, int *evdec_num) const |
| void | genSDPcut (const OsiSolverInterface &si, OsiCuts &cs, double *v1, double *v2, bool checkduplicates, int *duplicate_cuts) const |
| void | additionalSDPcuts (const OsiSolverInterface &si, OsiCuts &cs, int np, const double *A, const double *vector, int *duplicate_cuts) const |
| void | zero_comp (const int ind_i, const double delta, const int np, const int *selected, int *loc_selected, int *ploc_card_selected, int *ploc_card_new_selected, double *ploc_lhs, double *locmargin, double **locmat, const double *sol, double *locv, const int evidx, bool wise, int *evdec_num, double *recomp_gap, double *threshold) const |
| void | zero_valid_delta (const int np, const int *order, const int *selected, const int min_card_new_selected, const double min_delta, const int start_point, const int curr_i, int *loc_selected, int *ploc_card_selected, int *ploc_card_new_selected, double *ploc_lhs, double *locmargin, double **locmat, int *pnchanged, const double *sol, double *locv, const int evidx, bool wise, double *recomp_gap, double *threshold, int *pcard_selected, int *pnew_selected, int *trace_bin, const int trace_bin_size, double **sparse_v_mat, int *pcard_v_mat, const int init_card_selected, int *has_init_vect, int *evdec_num) const |
| void | zero_selected (const int np, const int *order, const int *selected, const int min_card_new_selected, const double min_delta, const int start_point, const int curr_i, int *loc_selected, int *ploc_card_selected, int *ploc_card_new_selected, double *ploc_lhs, double *locmargin, double **locmat, int *pnchanged, const double *sol, double *locv, const int evidx, bool wise, double *recomp_gap, double *threshold, int *pcard_selected, int *pnew_selected, int *trace_bin, const int trace_bin_size, double **sparse_v_mat, int *pcard_v_mat, const int init_card_selected, int *has_init_vect, int *evdec_num) const |
| void | zero_pos_delta (const int np, const int *order, const int *selected, const int min_card_new_selected, const int start_point, const int curr_i, int *loc_selected, int *ploc_card_selected, int *ploc_card_new_selected, double *ploc_lhs, double *locmargin, double **locmat, int *pnchanged, const double *sol, double *locv, const int evidx, bool wise, double *recomp_gap, double *threshold, int *pcard_selected, int *pnew_selected, int *trace_bin, const int trace_bin_size, double **sparse_v_mat, int *pcard_v_mat, const int init_card_selected, int *has_init_vect, int *evdec_num) const |
| void | add_v_cut (const int np, const int *loc_selected, const int loc_card_selected, const double *locv, const int init_card_selected, int *has_init_vect, int *selected, int *pcard_selected, int *pnew_selected, int *trace_bin, const int trace_bin_size, double **sparse_v_mat, int *pcard_v_mat) const |
| void | update_sparsify_structures (const int np, const double *sol, double *v, double *margin, double **mat, double *lhs, const int *zeroed, int evidx, bool decompose, int *evdec_num) const |
| void | sparsify (const int evidx, const double eigen_val, const double *v, const int n, const double *sol, double **sparse_v_mat, int *card_v_mat, double *work_ev, bool wise, int *evdec_num) const |
| void | sparsify_new (const int evidx, const double eigen_val, const double *v, const int n, const double *sol, double **sparse_v_mat, int *card_v_mat, double *work_ev, bool wise, int *evdec_num) const |
| void | myremoveBestOneRowCol (double *matrix, int n, int running_n, int min_nz, bool *del_idx, double **sparse_v_mat, int *card_v_mat, int *evdec_num) const |
Private Attributes | |
| int | n_ |
| int | t_ |
| int | N_ |
| int | cons_ |
| double | objConst_ |
| double * | b_ |
| double * | c_ |
| double ** | Q_ |
| double ** | origMat_ |
| double * | origRhs_ |
| char * | origSense_ |
| double * | xlb_ |
| double * | xub_ |
| double * | ylb_ |
| double * | yub_ |
| OsiSolverInterface * | si_ |
| Heuristics * | heuristics_ |
| Timer * | globaltimer_ |
| Tracer * | tracer_ |
| int * | seed_ |
| int | _iter |
| int | max_nb_cuts |
| bool | removeduplicates_ |
| sparsify_trace | spartrace |
Definition at line 56 of file CutGen.hpp.
| CutGen::CutGen | ( | const int | n, | |
| const int | t, | |||
| const int | cons, | |||
| const double | objConst, | |||
| const double * | b, | |||
| const double * | c, | |||
| const double ** | Q, | |||
| const double ** | origMat, | |||
| const double * | origRhs, | |||
| const char * | origSense, | |||
| const double * | xlb, | |||
| const double * | xub, | |||
| const double * | ylb, | |||
| const double * | yub, | |||
| OsiSolverInterface * | si, | |||
| Timer * | globaltimer, | |||
| Tracer * | tracer | |||
| ) |
Definition at line 928 of file CutGen.cpp.
| CutGen::~CutGen | ( | ) |
Definition at line 1056 of file CutGen.cpp.
| CutGen* CutGen::clone | ( | ) | const [inline] |
Definition at line 104 of file CutGen.hpp.
| sparsify_trace CutGen::get_sparsify_trace | ( | ) | [inline] |
Definition at line 109 of file CutGen.hpp.
| double CutGen::currObj | ( | ) | const [inline] |
Definition at line 112 of file CutGen.hpp.
| double CutGen::bestObj | ( | ) | const [inline] |
Definition at line 115 of file CutGen.hpp.
| double* CutGen::bestSol | ( | ) | const [inline] |
Definition at line 118 of file CutGen.hpp.
| void CutGen::set_max_nb_cuts | ( | const int | max_c | ) | [inline] |
Definition at line 121 of file CutGen.hpp.
| void CutGen::generateCuts | ( | const OsiSolverInterface & | si, | |
| OsiCuts & | cs, | |||
| const CglTreeInfo | info = CglTreeInfo () | |||
| ) | const |
Definition at line 27 of file CutGen.cpp.
| void CutGen::updateSol | ( | ) |
Definition at line 922 of file CutGen.cpp.
| void CutGen::setIter | ( | int | iter | ) | [inline] |
Definition at line 136 of file CutGen.hpp.
| void CutGen::compareSparsify | ( | const OsiSolverInterface & | si, | |
| int | n, | |||
| int | m, | |||
| const double * | sol, | |||
| double * | z, | |||
| double * | w, | |||
| FILE * | out | |||
| ) | const [private] |
Definition at line 395 of file CutGen.cpp.
| void CutGen::sparsify2 | ( | const int | n, | |
| const double * | sol, | |||
| double ** | sparse_v_mat, | |||
| int * | card_v_mat, | |||
| int | min_nz, | |||
| int * | evdec_num | |||
| ) | const [private] |
Definition at line 1239 of file CutGen.cpp.
| void CutGen::genSDPcut | ( | const OsiSolverInterface & | si, | |
| OsiCuts & | cs, | |||
| double * | v1, | |||
| double * | v2, | |||
| bool | checkduplicates, | |||
| int * | duplicate_cuts | |||
| ) | const [private] |
Definition at line 853 of file CutGen.cpp.
| void CutGen::additionalSDPcuts | ( | const OsiSolverInterface & | si, | |
| OsiCuts & | cs, | |||
| int | np, | |||
| const double * | A, | |||
| const double * | vector, | |||
| int * | duplicate_cuts | |||
| ) | const [private] |
Definition at line 1259 of file CutGen.cpp.
| void CutGen::zero_comp | ( | const int | ind_i, | |
| const double | delta, | |||
| const int | np, | |||
| const int * | selected, | |||
| int * | loc_selected, | |||
| int * | ploc_card_selected, | |||
| int * | ploc_card_new_selected, | |||
| double * | ploc_lhs, | |||
| double * | locmargin, | |||
| double ** | locmat, | |||
| const double * | sol, | |||
| double * | locv, | |||
| const int | evidx, | |||
| bool | wise, | |||
| int * | evdec_num, | |||
| double * | recomp_gap, | |||
| double * | threshold | |||
| ) | const [private] |
Definition at line 1425 of file CutGen.cpp.
| void CutGen::zero_valid_delta | ( | const int | np, | |
| const int * | order, | |||
| const int * | selected, | |||
| const int | min_card_new_selected, | |||
| const double | min_delta, | |||
| const int | start_point, | |||
| const int | curr_i, | |||
| int * | loc_selected, | |||
| int * | ploc_card_selected, | |||
| int * | ploc_card_new_selected, | |||
| double * | ploc_lhs, | |||
| double * | locmargin, | |||
| double ** | locmat, | |||
| int * | pnchanged, | |||
| const double * | sol, | |||
| double * | locv, | |||
| const int | evidx, | |||
| bool | wise, | |||
| double * | recomp_gap, | |||
| double * | threshold, | |||
| int * | pcard_selected, | |||
| int * | pnew_selected, | |||
| int * | trace_bin, | |||
| const int | trace_bin_size, | |||
| double ** | sparse_v_mat, | |||
| int * | pcard_v_mat, | |||
| const int | init_card_selected, | |||
| int * | has_init_vect, | |||
| int * | evdec_num | |||
| ) | const [private] |
Definition at line 1459 of file CutGen.cpp.
| void CutGen::zero_selected | ( | const int | np, | |
| const int * | order, | |||
| const int * | selected, | |||
| const int | min_card_new_selected, | |||
| const double | min_delta, | |||
| const int | start_point, | |||
| const int | curr_i, | |||
| int * | loc_selected, | |||
| int * | ploc_card_selected, | |||
| int * | ploc_card_new_selected, | |||
| double * | ploc_lhs, | |||
| double * | locmargin, | |||
| double ** | locmat, | |||
| int * | pnchanged, | |||
| const double * | sol, | |||
| double * | locv, | |||
| const int | evidx, | |||
| bool | wise, | |||
| double * | recomp_gap, | |||
| double * | threshold, | |||
| int * | pcard_selected, | |||
| int * | pnew_selected, | |||
| int * | trace_bin, | |||
| const int | trace_bin_size, | |||
| double ** | sparse_v_mat, | |||
| int * | pcard_v_mat, | |||
| const int | init_card_selected, | |||
| int * | has_init_vect, | |||
| int * | evdec_num | |||
| ) | const [private] |
Definition at line 1515 of file CutGen.cpp.
| void CutGen::zero_pos_delta | ( | const int | np, | |
| const int * | order, | |||
| const int * | selected, | |||
| const int | min_card_new_selected, | |||
| const int | start_point, | |||
| const int | curr_i, | |||
| int * | loc_selected, | |||
| int * | ploc_card_selected, | |||
| int * | ploc_card_new_selected, | |||
| double * | ploc_lhs, | |||
| double * | locmargin, | |||
| double ** | locmat, | |||
| int * | pnchanged, | |||
| const double * | sol, | |||
| double * | locv, | |||
| const int | evidx, | |||
| bool | wise, | |||
| double * | recomp_gap, | |||
| double * | threshold, | |||
| int * | pcard_selected, | |||
| int * | pnew_selected, | |||
| int * | trace_bin, | |||
| const int | trace_bin_size, | |||
| double ** | sparse_v_mat, | |||
| int * | pcard_v_mat, | |||
| const int | init_card_selected, | |||
| int * | has_init_vect, | |||
| int * | evdec_num | |||
| ) | const [private] |
Definition at line 1563 of file CutGen.cpp.
| void CutGen::add_v_cut | ( | const int | np, | |
| const int * | loc_selected, | |||
| const int | loc_card_selected, | |||
| const double * | locv, | |||
| const int | init_card_selected, | |||
| int * | has_init_vect, | |||
| int * | selected, | |||
| int * | pcard_selected, | |||
| int * | pnew_selected, | |||
| int * | trace_bin, | |||
| const int | trace_bin_size, | |||
| double ** | sparse_v_mat, | |||
| int * | pcard_v_mat | |||
| ) | const [private] |
Definition at line 1618 of file CutGen.cpp.
| void CutGen::update_sparsify_structures | ( | const int | np, | |
| const double * | sol, | |||
| double * | v, | |||
| double * | margin, | |||
| double ** | mat, | |||
| double * | lhs, | |||
| const int * | zeroed, | |||
| int | evidx, | |||
| bool | decompose, | |||
| int * | evdec_num | |||
| ) | const [private] |
Definition at line 1330 of file CutGen.cpp.
| void CutGen::sparsify | ( | const int | evidx, | |
| const double | eigen_val, | |||
| const double * | v, | |||
| const int | n, | |||
| const double * | sol, | |||
| double ** | sparse_v_mat, | |||
| int * | card_v_mat, | |||
| double * | work_ev, | |||
| bool | wise, | |||
| int * | evdec_num | |||
| ) | const [private] |
Definition at line 1692 of file CutGen.cpp.
| void CutGen::sparsify_new | ( | const int | evidx, | |
| const double | eigen_val, | |||
| const double * | v, | |||
| const int | n, | |||
| const double * | sol, | |||
| double ** | sparse_v_mat, | |||
| int * | card_v_mat, | |||
| double * | work_ev, | |||
| bool | wise, | |||
| int * | evdec_num | |||
| ) | const [private] |
Definition at line 1962 of file CutGen.cpp.
| void CutGen::myremoveBestOneRowCol | ( | double * | matrix, | |
| int | n, | |||
| int | running_n, | |||
| int | min_nz, | |||
| bool * | del_idx, | |||
| double ** | sparse_v_mat, | |||
| int * | card_v_mat, | |||
| int * | evdec_num | |||
| ) | const [private] |
Definition at line 1115 of file CutGen.cpp.
int CutGen::n_ [private] |
Definition at line 60 of file CutGen.hpp.
int CutGen::t_ [private] |
Definition at line 61 of file CutGen.hpp.
int CutGen::N_ [private] |
Definition at line 62 of file CutGen.hpp.
int CutGen::cons_ [private] |
Definition at line 63 of file CutGen.hpp.
double CutGen::objConst_ [private] |
Definition at line 64 of file CutGen.hpp.
double* CutGen::b_ [private] |
Definition at line 65 of file CutGen.hpp.
double* CutGen::c_ [private] |
Definition at line 66 of file CutGen.hpp.
double** CutGen::Q_ [private] |
Definition at line 67 of file CutGen.hpp.
double** CutGen::origMat_ [private] |
Definition at line 68 of file CutGen.hpp.
double* CutGen::origRhs_ [private] |
Definition at line 69 of file CutGen.hpp.
char* CutGen::origSense_ [private] |
Definition at line 70 of file CutGen.hpp.
double* CutGen::xlb_ [private] |
Definition at line 71 of file CutGen.hpp.
double* CutGen::xub_ [private] |
Definition at line 72 of file CutGen.hpp.
double* CutGen::ylb_ [private] |
Definition at line 73 of file CutGen.hpp.
double* CutGen::yub_ [private] |
Definition at line 74 of file CutGen.hpp.
OsiSolverInterface* CutGen::si_ [private] |
Definition at line 75 of file CutGen.hpp.
Heuristics* CutGen::heuristics_ [private] |
Definition at line 76 of file CutGen.hpp.
Timer* CutGen::globaltimer_ [private] |
Definition at line 78 of file CutGen.hpp.
Tracer* CutGen::tracer_ [private] |
Definition at line 80 of file CutGen.hpp.
int* CutGen::seed_ [private] |
Definition at line 82 of file CutGen.hpp.
int CutGen::_iter [private] |
Definition at line 84 of file CutGen.hpp.
int CutGen::max_nb_cuts [private] |
Definition at line 87 of file CutGen.hpp.
bool CutGen::removeduplicates_ [private] |
Definition at line 89 of file CutGen.hpp.
sparsify_trace CutGen::spartrace [private] |
Definition at line 91 of file CutGen.hpp.
1.6.1