GAP_DecompApp Class Reference

#include <GAP_DecompApp.h>

Inheritance diagram for GAP_DecompApp:
Inheritance graph
[legend]
Collaboration diagram for GAP_DecompApp:
Collaboration graph
[legend]

List of all members.

Public Member Functions

DecompSolverStatus solveRelaxed (const int whichBlock, const double *redCostX, const double target, list< DecompVar * > &vars)
 Solve the relaxed problem.
void printOriginalColumn (const int index, ostream *os=&cout) const
 Print an original column (format for this app).
void printOriginalColumn (const int index, ostream *os=&cout) const
 Print an original column (format for this app).
Helper functions (public).



void initializeApp (UtilParameters &utilParam)
 Guts of constructor.
const int getOffsetI (const int i) const
 TODO comment.
const int getIndexIJ (const int i, const int j) const
 Guts of constructor.
pair< int, int > getIndexInv (const int index) const
 Guts of constructor.
int createModels ()
 TODO comment.
int createModelPartAP (DecompConstraintSet *model)
 Guts of constructor.
const GAP_InstancegetInstance () const
 Guts of constructor.
const GAP_DecompParamgetParam () const
 Guts of constructor.
const double * getObjective () const
 Guts of constructor.
DecompConstraintSetgetModel (string modelName) const
 Guts of constructor.
void initializeApp (UtilParameters &utilParam)
 Guts of constructor.
const int getOffsetI (const int i) const
 Helper methods for indexing.
const int getIndexIJ (const int i, const int j) const
 Guts of constructor.
pair< int, int > getIndexInv (const int index) const
 Guts of constructor.
int createModels ()
 Creation of the various model constraint systems.
int createModelPartAP (DecompConstraintSet *model)
 Guts of constructor.
int createModelPartKP (DecompConstraintSet *model)
 Guts of constructor.
int createModelPartKP (DecompConstraintSet *model, int whichKnap)
 Guts of constructor.
int createModelPartKP (DecompConstraintSet *model, vector< int > &whichKnaps)
 Guts of constructor.
const GAP_InstancegetInstance () const
 Some access methods to private data.
const GAP_DecompParamgetParam () const
 Guts of constructor.
const double * getObjective () const
 Guts of constructor.
Constructor and Destructor



 GAP_DecompApp (UtilParameters &utilParam)
 Default constructor.
virtual ~GAP_DecompApp ()
 Default constructor.
 GAP_DecompApp (UtilParameters &utilParam)
 Default constructor.
virtual ~GAP_DecompApp ()
 Default constructor.

Private Attributes

const string m_classTag
 Class id tag (for log / debugging).
GAP_Instance m_instance
 GAP problem instance data.
GAP_DecompParam m_appParam
 Application specific parameters.
vector< GAP_KnapPisinger * > m_knap
 GAP_Knapsack object for each knapsack row.
double * m_objective
 The model objective coefficients (original space).
map< string,
DecompConstraintSet * > 
m_models
 The various model constraint systems used for different algorithms, keyed by a unique string (model name).
vector< DecompConstraintSet * > m_models
 Store pointers to the various model constraint systems, so their memory can be deleted.

Detailed Description

A DecompApp for solving the Generalized Assignment Problem (GAP).

See also:
DecompApp

Definition at line 36 of file GAP_DecompApp.h.


Constructor & Destructor Documentation

GAP_DecompApp::GAP_DecompApp ( UtilParameters utilParam  )  [inline]

Default constructor.

Takes an instance of UtilParameters

Definition at line 123 of file GAP_DecompApp.h.

References initializeApp().

virtual GAP_DecompApp::~GAP_DecompApp (  )  [inline, virtual]

Default constructor.

Takes an instance of UtilParameters

Definition at line 130 of file GAP_DecompApp.h.

References m_knap, m_models, UtilDeleteMapPtr(), and UtilDeleteVectorPtr().

GAP_DecompApp::GAP_DecompApp ( UtilParameters utilParam  )  [inline]

Default constructor.

Takes an instance of UtilParameters

Definition at line 115 of file GAP_DecompApp3.h.

References initializeApp().

virtual GAP_DecompApp::~GAP_DecompApp (  )  [inline, virtual]

Default constructor.

Takes an instance of UtilParameters

Definition at line 122 of file GAP_DecompApp3.h.

References m_models, m_objective, UTIL_DELARR, and UtilDeleteVectorPtr().


Member Function Documentation

DecompSolverStatus GAP_DecompApp::solveRelaxed ( const int  whichBlock,
const double *  redCostX,
const double  target,
list< DecompVar * > &  vars 
)

Solve the relaxed problem.

void GAP_DecompApp::printOriginalColumn ( const int  index,
ostream *  os = &cout 
) const [virtual]

Print an original column (format for this app).

Reimplemented from DecompApp.

void GAP_DecompApp::initializeApp ( UtilParameters utilParam  )  [virtual]

Guts of constructor.

Reimplemented from DecompApp.

Referenced by GAP_DecompApp().

const int GAP_DecompApp::getOffsetI ( const int  i  )  const [inline]

TODO comment.

Definition at line 77 of file GAP_DecompApp.h.

References GAP_Instance::getNTasks(), and m_instance.

const int GAP_DecompApp::getIndexIJ ( const int  i,
const int  j 
) const [inline]

Guts of constructor.

Definition at line 80 of file GAP_DecompApp.h.

References GAP_Instance::getNTasks(), and m_instance.

pair<int, int> GAP_DecompApp::getIndexInv ( const int  index  )  const [inline]

Guts of constructor.

Definition at line 85 of file GAP_DecompApp.h.

References GAP_Instance::getNTasks(), and m_instance.

int GAP_DecompApp::createModels (  ) 

TODO comment.

Reimplemented from DecompApp.

int GAP_DecompApp::createModelPartAP ( DecompConstraintSet model  ) 

Guts of constructor.

const GAP_Instance& GAP_DecompApp::getInstance (  )  const [inline]

Guts of constructor.

Definition at line 95 of file GAP_DecompApp.h.

References m_instance.

const GAP_DecompParam& GAP_DecompApp::getParam (  )  const [inline]

Guts of constructor.

Definition at line 98 of file GAP_DecompApp.h.

References m_appParam.

const double* GAP_DecompApp::getObjective (  )  const [inline]

Guts of constructor.

Definition at line 101 of file GAP_DecompApp.h.

References m_objective.

DecompConstraintSet* GAP_DecompApp::getModel ( string  modelName  )  const [inline]

Guts of constructor.

Definition at line 104 of file GAP_DecompApp.h.

References m_models.

void GAP_DecompApp::printOriginalColumn ( const int  index,
ostream *  os = &cout 
) const [virtual]

Print an original column (format for this app).

Reimplemented from DecompApp.

void GAP_DecompApp::initializeApp ( UtilParameters utilParam  )  [virtual]

Guts of constructor.

Reimplemented from DecompApp.

const int GAP_DecompApp::getOffsetI ( const int  i  )  const [inline]

Helper methods for indexing.

Definition at line 77 of file GAP_DecompApp3.h.

References GAP_Instance::getNTasks(), and m_instance.

const int GAP_DecompApp::getIndexIJ ( const int  i,
const int  j 
) const [inline]

Guts of constructor.

Definition at line 80 of file GAP_DecompApp3.h.

References GAP_Instance::getNTasks(), and m_instance.

pair<int, int> GAP_DecompApp::getIndexInv ( const int  index  )  const [inline]

Guts of constructor.

Definition at line 85 of file GAP_DecompApp3.h.

References GAP_Instance::getNTasks(), and m_instance.

int GAP_DecompApp::createModels (  ) 

Creation of the various model constraint systems.

Reimplemented from DecompApp.

int GAP_DecompApp::createModelPartAP ( DecompConstraintSet model  ) 

Guts of constructor.

int GAP_DecompApp::createModelPartKP ( DecompConstraintSet model  ) 

Guts of constructor.

int GAP_DecompApp::createModelPartKP ( DecompConstraintSet model,
int  whichKnap 
)

Guts of constructor.

int GAP_DecompApp::createModelPartKP ( DecompConstraintSet model,
vector< int > &  whichKnaps 
)

Guts of constructor.

const GAP_Instance& GAP_DecompApp::getInstance (  )  const [inline]

Some access methods to private data.

Definition at line 101 of file GAP_DecompApp3.h.

References m_instance.

const GAP_DecompParam& GAP_DecompApp::getParam (  )  const [inline]

Guts of constructor.

Definition at line 104 of file GAP_DecompApp3.h.

References m_appParam.

const double* GAP_DecompApp::getObjective (  )  const [inline]

Guts of constructor.

Definition at line 107 of file GAP_DecompApp3.h.

References m_objective.


Member Data Documentation

const string GAP_DecompApp::m_classTag [private]

Class id tag (for log / debugging).

Reimplemented from DecompApp.

Definition at line 39 of file GAP_DecompApp.h.

GAP problem instance data.

Definition at line 42 of file GAP_DecompApp.h.

Referenced by getIndexIJ(), getIndexInv(), getInstance(), and getOffsetI().

Application specific parameters.

Definition at line 45 of file GAP_DecompApp.h.

Referenced by getParam().

GAP_Knapsack object for each knapsack row.

Definition at line 48 of file GAP_DecompApp.h.

Referenced by ~GAP_DecompApp().

double * GAP_DecompApp::m_objective [private]

The model objective coefficients (original space).

Reimplemented from DecompApp.

Definition at line 51 of file GAP_DecompApp.h.

Referenced by getObjective(), and ~GAP_DecompApp().

The various model constraint systems used for different algorithms, keyed by a unique string (model name).

Definition at line 55 of file GAP_DecompApp.h.

Referenced by getModel(), and ~GAP_DecompApp().

Store pointers to the various model constraint systems, so their memory can be deleted.

Definition at line 61 of file GAP_DecompApp3.h.


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

Generated on 3 Jun 2015 for Dip-All by  doxygen 1.6.1