Couenne::CouenneSdpCuts Class Reference

These are cuts of the form. More...

#include <CouenneSdpCuts.hpp>

Collaboration diagram for Couenne::CouenneSdpCuts:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 CouenneSdpCuts (CouenneProblem *, JnlstPtr, const Ipopt::SmartPtr< Ipopt::OptionsList >)
 Constructor.
 ~CouenneSdpCuts ()
 Destructor.
CouenneSdpCutsoperator= (const CouenneSdpCuts &)
 Assignment.
 CouenneSdpCuts (const CouenneSdpCuts &)
 Copy constructor.
virtual CglCutGenerator * clone () const
 Cloning constructor.
const bool doNotUse () const
virtual void generateCuts (const OsiSolverInterface &, OsiCuts &, const CglTreeInfo=CglTreeInfo()) const
 The main CglCutGenerator.
void updateSol ()

Static Public Member Functions

static void registerOptions (Ipopt::SmartPtr< Bonmin::RegisteredOptions > roptions)
 Add list of options to be read from file.

Protected Attributes

CouenneProblemproblem_
 pointer to problem info
bool doNotUse_
 after construction, true if there are enough product terms to justify application.
std::vector< CouenneExprMatrix * > minors_
 minors on which to apply cuts
int numEigVec_
 number of eigenvectors to be used (default: n)
bool onlyNegEV_
 only use negative eigenvalues (default: yes)
bool useSparsity_
 Sparsify eigenvalues before writing inequality (default: no).
bool fillMissingTerms_
 If minor not fully dense, create fictitious auxiliary variables that will be used in sdp cuts only (tighter than sdp cuts without).

Private Types

enum  zero_type { POS_DELTA, SELECTED, VALID_DELTA }

Private Member Functions

void genCutSingle (CouenneExprMatrix *const &, const OsiSolverInterface &, OsiCuts &, const CglTreeInfo=CglTreeInfo()) const
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 *A, double **sparse_v_mat, int *card_v_mat, int min_nz, int *evdec_num) const
void genSDPcut (const OsiSolverInterface &si, OsiCuts &cs, CouenneExprMatrix *XX, double *v1, double *v2, int **) const
void additionalSDPcuts (const OsiSolverInterface &si, OsiCuts &cs, CouenneExprMatrix *minor, int np, const double *A, const double *vector, int **) 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, double *locv, const int evidx, bool wise, int *evdec_num, double *recomp_gap, double *threshold) const
void zero_unified (enum zero_type type, 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, double *locv, const int evidx, bool wise, double *recomp_gap, double *threshold, 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, double **sparse_v_mat, int *pcard_v_mat) const
void update_sparsify_structures (const int np, double *v, double *margin, double *A, double *lhs, const int *zeroed, int evidx, bool decompose, int *evdec_num) const
void sparsify (bool 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, int *evdec_num) const

Detailed Description

These are cuts of the form.

a' X a >= 0

where X is a matrix constrained to be PSD.

Typical application is in problems with products forming a matrix of auxiliary variables X0 = (x_ij)_{i,j in N}, and x_ij is the auxiliary variable for x_i * x_j. After reformulation, matrices like X0 arise naturally and can be used to separate cuts that help strengthen the lower bound. See Sherali and Fraticelli for the base idea, and Qualizza, Belotti and Margot for an efficient rework and its implementation. Andrea Qualizza's code has been made open source and is used here (thanks Andrea!).

Definition at line 43 of file CouenneSdpCuts.hpp.


Member Enumeration Documentation

Enumerator:
POS_DELTA 
SELECTED 
VALID_DELTA 

Definition at line 121 of file CouenneSdpCuts.hpp.


Constructor & Destructor Documentation

CouenneSdpCuts::CouenneSdpCuts ( CouenneProblem p,
JnlstPtr  jnlst,
const Ipopt::SmartPtr< Ipopt::OptionsList >  options 
)

Constructor.

either it is x_i x_j

or it is x_i ^ 2

Definition at line 31 of file CouenneSdpCuts.cpp.

CouenneSdpCuts::~CouenneSdpCuts (  ) 

Destructor.

Definition at line 253 of file CouenneSdpCuts.cpp.

CouenneSdpCuts::CouenneSdpCuts ( const CouenneSdpCuts rhs  ) 

Copy constructor.

Definition at line 264 of file CouenneSdpCuts.cpp.


Member Function Documentation

CouenneSdpCuts & CouenneSdpCuts::operator= ( const CouenneSdpCuts rhs  ) 

Assignment.

Definition at line 282 of file CouenneSdpCuts.cpp.

CglCutGenerator * CouenneSdpCuts::clone (  )  const [virtual]

Cloning constructor.

clone constructor

Definition at line 302 of file CouenneSdpCuts.cpp.

const bool Couenne::CouenneSdpCuts::doNotUse (  )  const [inline]

Definition at line 76 of file CouenneSdpCuts.hpp.

void CouenneSdpCuts::generateCuts ( const OsiSolverInterface &  si,
OsiCuts &  cs,
const CglTreeInfo  info = CglTreeInfo () 
) const [virtual]

The main CglCutGenerator.

Definition at line 40 of file CutGen.cpp.

void CouenneSdpCuts::registerOptions ( Ipopt::SmartPtr< Bonmin::RegisteredOptions roptions  )  [static]

Add list of options to be read from file.

Definition at line 307 of file CouenneSdpCuts.cpp.

void Couenne::CouenneSdpCuts::updateSol (  ) 
void CouenneSdpCuts::genCutSingle ( CouenneExprMatrix *const &  minor,
const OsiSolverInterface &  si,
OsiCuts &  cs,
const CglTreeInfo  info = CglTreeInfo () 
) const [private]

Definition at line 64 of file CutGen.cpp.

void Couenne::CouenneSdpCuts::compareSparsify ( const OsiSolverInterface &  si,
int  n,
int  m,
const double *  sol,
double *  z,
double *  w,
FILE *  out 
) const [private]
void CouenneSdpCuts::sparsify2 ( const int  n,
const double *  A,
double **  sparse_v_mat,
int *  card_v_mat,
int  min_nz,
int *  evdec_num 
) const [private]

construct two matrices T and Tcopy that cut k-th row and k-th column

Definition at line 45 of file CutGenSparse.cpp.

void CouenneSdpCuts::genSDPcut ( const OsiSolverInterface &  si,
OsiCuts &  cs,
CouenneExprMatrix XX,
double *  v1,
double *  v2,
int **  indA 
) const [private]

Definition at line 274 of file CutGen.cpp.

void CouenneSdpCuts::additionalSDPcuts ( const OsiSolverInterface &  si,
OsiCuts &  cs,
CouenneExprMatrix minor,
int  np,
const double *  A,
const double *  vector,
int **  indA 
) const [private]

Definition at line 214 of file CutGenSparse.cpp.

void CouenneSdpCuts::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,
double *  locv,
const int  evidx,
bool  wise,
int *  evdec_num,
double *  recomp_gap,
double *  threshold 
) const [private]

Definition at line 387 of file CutGenSparse.cpp.

void CouenneSdpCuts::zero_unified ( enum zero_type  type,
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,
double *  locv,
const int  evidx,
bool  wise,
double *  recomp_gap,
double *  threshold,
int *  evdec_num 
) const [private]

Definition at line 428 of file CutGenSparse.cpp.

void CouenneSdpCuts::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,
double **  sparse_v_mat,
int *  pcard_v_mat 
) const [private]

Definition at line 483 of file CutGenSparse.cpp.

void CouenneSdpCuts::update_sparsify_structures ( const int  np,
double *  v,
double *  margin,
double *  A,
double *  lhs,
const int *  zeroed,
int  evidx,
bool  decompose,
int *  evdec_num 
) const [private]

Definition at line 288 of file CutGenSparse.cpp.

void CouenneSdpCuts::sparsify ( bool  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,
int *  evdec_num 
) const [private]

Knuth shuffle for creating a random order

Definition at line 531 of file CutGenSparse.cpp.


Member Data Documentation

pointer to problem info

Definition at line 47 of file CouenneSdpCuts.hpp.

after construction, true if there are enough product terms to justify application.

If not, do not add this cut generator

Definition at line 49 of file CouenneSdpCuts.hpp.

minors on which to apply cuts

Definition at line 53 of file CouenneSdpCuts.hpp.

number of eigenvectors to be used (default: n)

Definition at line 55 of file CouenneSdpCuts.hpp.

only use negative eigenvalues (default: yes)

Definition at line 57 of file CouenneSdpCuts.hpp.

Sparsify eigenvalues before writing inequality (default: no).

Definition at line 59 of file CouenneSdpCuts.hpp.

If minor not fully dense, create fictitious auxiliary variables that will be used in sdp cuts only (tighter than sdp cuts without).

Definition at line 61 of file CouenneSdpCuts.hpp.


The documentation for this class was generated from the following files:

Generated on 5 Jul 2015 by  doxygen 1.6.1