17 const std::string mpdDir );
53 CglClique(
bool setPacking =
false,
bool justOriginalRows =
false);
128 double *all_edgecost;
131 nodenum(0), edgenum(0), density(0),
132 min_deg_node(0), min_degree(0), max_deg_node(0), max_degree(0),
133 nodes(0), all_nbr(0), all_edgecost(0) {}
216 void selectFractionalBinaries(
const OsiSolverInterface& si);
219 void selectFractionals(
const OsiSolverInterface& si);
221 void selectRowCliques(
const OsiSolverInterface& si,
int numOriginalRows);
223 void createSetPackingSubMatrix(
const OsiSolverInterface& si);
225 void createFractionalGraph();
227 int createNodeNode();
229 void deleteSetPackingSubMatrix();
231 void deleteFractionalGraph();
233 void find_scl(OsiCuts& cs);
235 void find_rcl(OsiCuts& cs);
237 int scl_choose_next_node(
const int current_nodenum,
238 const int *current_indices,
239 const int *current_degrees,
240 const double *current_values);
242 void scl_delete_node(
const int del_ind,
int& current_nodenum,
243 int *current_indices,
int *current_degrees,
244 double *current_values);
246 int enumerate_maximal_cliques(
int& pos,
bool* scl_label, OsiCuts& cs);
248 int greedy_maximal_clique(OsiCuts& cs);
250 void recordClique(
const int len,
int* indices, OsiCuts& cs);
259 const std::string mpdDir);
274 generateCuts(
const OsiSolverInterface& si, OsiCuts & cs,
296 CglFakeClique(OsiSolverInterface * solver=NULL,
bool setPacking =
false);
300 void assignSolver(OsiSolverInterface * fakeSolver);
OsiSolverInterface * fakeSolver_
fake solver to use
double getMinViolation() const
int * cl_del_indices
An array of nodes discarded from the candidate list.
Information about where the cut generator is invoked from.
virtual void generateCuts(const OsiSolverInterface &si, OsiCuts &cs, const CglTreeInfo info=CglTreeInfo())
Generate cuts for the model data contained in si.
bool rcl_report_result
whether to give a detailed statistics on the row clique method
int cl_length
The length of cl_indices.
void setStarCliqueNextNodeMethod(scl_next_node_method method)
virtual std::string generateCpp(FILE *fp)
Create C++ lines to get to current state.
CglProbing * probing_
Probing object.
void setStarCliqueCandidateLengthThreshold(int maxlen)
int cl_perm_length
The length of cl_perm_indices.
int * cl_indices
List of indices that should be considered for extending the ones listed in cl_perm_indices.
const int * cl_perm_indices
variables/arrays that are used across many methods
Cut Generator Base Class.
scl_next_node_method
possible choices for selecting the next node in the star clique search
void setRowCliqueReport(bool yesno=true)
int sp_numrows
pieces of the set packing part of the solverinterface
bool scl_report_result
whether to give a detailed statistics on the star clique method
virtual ~CglClique()
Destructor.
virtual CglCutGenerator * clone() const
Clone.
bool do_star_clique
whether to do the star clique algorithm or not.
CglClique(const CglClique &rhs)
Copy constructor.
void setStarCliqueReport(bool yesno=true)
friend void CglCliqueUnitTest(const OsiSolverInterface *siP, const std::string mpdDir)
A function that tests the methods in the CglClique class.
int cl_del_length
The length of cl_del_indices.
scl_next_node_method scl_next_node_rule
How the next node to be added to the star clique should be selected.
frac_graph fgraph
the intersection graph corresponding to the set packing problem
void setDoRowClique(bool yesno=true)
bool do_row_clique
data for the star clique algorithm
CglClique & operator=(const CglClique &rhs)
Assignment operator.
void setDoStarClique(bool yesno=true)
void setRowCliqueCandidateLengthThreshold(int maxlen)
void setMinViolation(double minviol)
bool * node_node
the node-node incidence matrix of the intersection graph.
int rcl_candidate_length_threshold
In the row clique method the maximal length of the candidate list (those nodes that can extend the ro...
double petol
The primal tolerance in the solverinterface.
bool setPacking_
An indicator showing whether the whole matrix in the solverinterface is a set packing problem or not...
void considerRows(const int numRows, const int *rowInd)
int scl_candidate_length_threshold
In the star clique method the maximal length of the candidate list (those nodes that are in a star...
Probing Cut Generator Class.
bool justOriginalRows_
True if just look at original rows.