Alps 1.5.11
Loading...
Searching...
No Matches
Public Member Functions | Private Attributes | List of all members
AbcSolution Class Reference

This class holds a MIP feasible primal solution. More...

#include <AbcSolution.h>

+ Inheritance diagram for AbcSolution:
+ Collaboration diagram for AbcSolution:

Public Member Functions

 AbcSolution ()
 
 AbcSolution (const int s, const double *val, const double obj)
 
 ~AbcSolution ()
 
double getObjValue () const
 Get the objective value value.
 
virtual double getQuality () const
 
int getSize () const
 Get the size of the solution.
 
const double * getColSolution () const
 Get the column solution.
 
double getColSolution (int i) const
 Get item i in the solution vector.
 
virtual void print (std::ostream &os) const
 Print out the solution.
 
virtual AlpsEncodedencode () const
 The method that encodes the solution into a encoded object.
 
virtual AlpsKnowledgedecode (AlpsEncoded &) const
 The method that decodes the solution from a encoded object.
 
 AbcSolution ()
 
 AbcSolution (const int s, const double *val, const double obj)
 
 ~AbcSolution ()
 
double getObjValue () const
 Get the objective value value.
 
virtual double getQuality () const
 
int getSize () const
 Get the size of the solution.
 
const double * getColSolution () const
 Get the column solution.
 
double getColSolution (int i) const
 Get item i in the solution vector.
 
virtual void print (std::ostream &os) const
 Print out the solution.
 
virtual AlpsEncodedencode () const
 The method that encodes the solution into a encoded object.
 
virtual AlpsKnowledgedecode (AlpsEncoded &) const
 The method that decodes the solution from a encoded object.
 
- Public Member Functions inherited from AlpsSolution
 AlpsSolution ()
 Default constructor.
 
 AlpsSolution (const AlpsNodeIndex_t i, const int d)
 Constructor to set index and depth.
 
virtual ~AlpsSolution ()
 Destructor.
 
AlpsNodeIndex_t getIndex ()
 Get index where solution was found.
 
void setIndex (const AlpsNodeIndex_t i)
 Set index where solution was found.
 
int getDepth ()
 Get depth where solution was found.
 
void setDepth (const int d)
 Set depth where solution was found.
 
- Public Member Functions inherited from AlpsKnowledge
 AlpsKnowledge ()
 
virtual ~AlpsKnowledge ()
 
KnowledgeType getType ()
 
void setType (KnowledgeType t)
 
virtual AlpsReturnStatus encode (AlpsEncoded *encoded)
 Pack into a encode object.
 
AlpsEncodedgetEncoded () const
 Get/set encoded.
 
void setEncoded (AlpsEncoded *e)
 

Private Attributes

int size_
 
double * value_
 
double objective_
 

Additional Inherited Members

- Protected Attributes inherited from AlpsKnowledge
KnowledgeType type_
 

Detailed Description

This class holds a MIP feasible primal solution.

Definition at line 31 of file AbcSolution.h.

Constructor & Destructor Documentation

◆ AbcSolution() [1/4]

AbcSolution::AbcSolution ( )
inline

Definition at line 38 of file AbcSolution.h.

◆ AbcSolution() [2/4]

AbcSolution::AbcSolution ( const int s,
const double * val,
const double obj )
inline

Definition at line 44 of file AbcSolution.h.

◆ ~AbcSolution() [1/2]

AbcSolution::~AbcSolution ( )
inline

Definition at line 54 of file AbcSolution.h.

◆ AbcSolution() [3/4]

AbcSolution::AbcSolution ( )
inline

Definition at line 38 of file AbcSolution.h.

◆ AbcSolution() [4/4]

AbcSolution::AbcSolution ( const int s,
const double * val,
const double obj )
inline

Definition at line 44 of file AbcSolution.h.

◆ ~AbcSolution() [2/2]

AbcSolution::~AbcSolution ( )
inline

Definition at line 54 of file AbcSolution.h.

Member Function Documentation

◆ getObjValue() [1/2]

double AbcSolution::getObjValue ( ) const
inline

Get the objective value value.

Definition at line 62 of file AbcSolution.h.

◆ getQuality() [1/2]

virtual double AbcSolution::getQuality ( ) const
inlinevirtual

Definition at line 64 of file AbcSolution.h.

◆ getSize() [1/2]

int AbcSolution::getSize ( ) const
inline

Get the size of the solution.

Definition at line 67 of file AbcSolution.h.

◆ getColSolution() [1/4]

const double * AbcSolution::getColSolution ( ) const
inline

Get the column solution.

Definition at line 70 of file AbcSolution.h.

◆ getColSolution() [2/4]

double AbcSolution::getColSolution ( int i) const
inline

Get item i in the solution vector.

Definition at line 74 of file AbcSolution.h.

◆ print() [1/2]

virtual void AbcSolution::print ( std::ostream & os) const
virtual

Print out the solution.

Reimplemented from AlpsSolution.

◆ encode() [1/2]

virtual AlpsEncoded * AbcSolution::encode ( ) const
virtual

The method that encodes the solution into a encoded object.

Reimplemented from AlpsKnowledge.

◆ decode() [1/2]

virtual AlpsKnowledge * AbcSolution::decode ( AlpsEncoded & ) const
virtual

The method that decodes the solution from a encoded object.

Reimplemented from AlpsKnowledge.

◆ getObjValue() [2/2]

double AbcSolution::getObjValue ( ) const
inline

Get the objective value value.

Definition at line 62 of file AbcSolution.h.

◆ getQuality() [2/2]

virtual double AbcSolution::getQuality ( ) const
inlinevirtual

Definition at line 64 of file AbcSolution.h.

◆ getSize() [2/2]

int AbcSolution::getSize ( ) const
inline

Get the size of the solution.

Definition at line 67 of file AbcSolution.h.

◆ getColSolution() [3/4]

const double * AbcSolution::getColSolution ( ) const
inline

Get the column solution.

Definition at line 70 of file AbcSolution.h.

◆ getColSolution() [4/4]

double AbcSolution::getColSolution ( int i) const
inline

Get item i in the solution vector.

Definition at line 74 of file AbcSolution.h.

◆ print() [2/2]

virtual void AbcSolution::print ( std::ostream & os) const
virtual

Print out the solution.

Reimplemented from AlpsSolution.

◆ encode() [2/2]

virtual AlpsEncoded * AbcSolution::encode ( ) const
virtual

The method that encodes the solution into a encoded object.

Reimplemented from AlpsKnowledge.

◆ decode() [2/2]

virtual AlpsKnowledge * AbcSolution::decode ( AlpsEncoded & ) const
virtual

The method that decodes the solution from a encoded object.

Reimplemented from AlpsKnowledge.

Member Data Documentation

◆ size_

int AbcSolution::size_
private

Definition at line 33 of file AbcSolution.h.

◆ value_

double * AbcSolution::value_
private

Definition at line 34 of file AbcSolution.h.

◆ objective_

double AbcSolution::objective_
private

Definition at line 35 of file AbcSolution.h.


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