15 #ifndef AP3_DECOMPAPP_INCLUDED
16 #define AP3_DECOMPAPP_INCLUDED
19 #include "DecompApp.h"
73 map<int, DecompConstraintSet*> & modelCore,
74 map<
int, vector<DecompConstraintSet*> > & modelRelax);
82 const double * redCostX,
83 const double * origCost,
89 list<DecompVar*> & vars);
93 ostream * os = &cout)
const ;
113 return (i * n * n) + (j * n) + k;
119 return (i * n * n) + (j * n) + k;
125 return (i * n * n) + (j * n) + k;
137 indexMod = index % nsq;
144 const int ind2)
const {
146 return (ind1 * n) + ind2;
152 return make_pair(index / n, index % n);
int indexIJK(const int i, const int j, const int k) const
Global index for column (i,j,k) in 3D case.
double ** m_assigncostMin
double m_optBound
Known optimal bound (for debugging)
const string getInstanceName() const
Get name of instance.
int index2(const int ind1, const int ind2) const
Global index for column (ind1, ind2) in 2D case.
void index3Inv(const int index, int &ind1, int &ind2, int &ind3) const
Global index for column (ind1, ind2, ind3) in 3D case.
Relaxation is 2-D Assignment Problem over IxJ.
int indexKIJ(const int k, const int i, const int j) const
Get optimal (or best known) objective.
map< int, vector< int > > m_intersection
Helper data for fast cut separation.
AP3_DecompApp(const AP3_DecompApp &)
void createModelPart(const int modelType, int *rowInd, double *rowEls, DecompConstraintSet *modelCore, DecompConstraintSet *modelRelax)
Create constraint system for one relaxation.
DecompStatus APPsolveRelaxed(const int whichModel, const double *redCostX, const double *origCost, const double alpha, const int n_origCols, const bool checkRC, const bool checkDup, OsiSolverInterface *m_subprobSI, list< DecompVar * > &vars)
Solve the relaxed problem.
void APPcreateModel(double *&objCoeff, map< int, DecompConstraintSet * > &modelCore, map< int, vector< DecompConstraintSet * > > &modelRelax)
Create the application model(s).
pair< int, int > index2Inv(const int index) const
Return the indices (ind1, ind2) for 2D case.
void printOriginalColumn(const int index, ostream *os=&cout) const
Print an original column.
int m_dimension
The dimension of the instance.
Relaxation is 2-D Assignment Problem over JxK.
string m_instance
Name of AP3 instance.
virtual void initializeApp()
Initialize applications.
Abstract Base Class for describing an interface to a solver.
Relaxation is 2-D Assignment Problem over IxK.
OsiSolverInterface * m_siAP
Helper data for fast construction of relaxed problems.
Error Class thrown by an exception.
virtual ~AP3_DecompApp()
Default constructor.
AP3_DecompParam m_appParam
Application specific parameters.
AP3_DecompApp & operator=(const AP3_DecompApp &)
const double getOptBound() const
Return the known optimal bound.
AP3_DecompApp(UtilParameters &utilParam)
Default constructor.
AP3_Instance m_ap3data
AP3 problem instance data.
const string m_classTag
Class id tag (for log / debugging).
int indexJIK(const int j, const int i, const int k) const
Get optimal (or best known) objective.
const double getKnownOptimalBound() const
Get optimal (or best known) objective.
The main application class.