- Main Page
- Related Pages
- Modules
- Namespaces
- Classes
- Files

- Class List
- Class Index
- Class Hierarchy
- Class Members

Public Member Functions | List of all members
BlisSolution Class Reference

This class contains the solutions generated by the LP solver (either primal or dual. More...

`#include <BlisSolution.h>`

Inheritance diagram for BlisSolution:
[legend]
Collaboration diagram for BlisSolution:
[legend]

## Public Member Functions
| BlisSolution ()
| Default constructor. More...
| BlisSolution (int s, const double *values, double objValue)
| Useful constructor. More...
virtual | ~BlisSolution ()
| Destructor. More...
virtual AlpsEncoded * | encode () const
| Check if IP feasible. More...
virtual AlpsKnowledge * | decode (AlpsEncoded &encoded) const
| The method that decodes the solution from a encoded object. More...
| BlisSolution ()
| Default constructor. More...
| BlisSolution (int s, const double *values, double objValue)
| Useful constructor. More...
virtual | ~BlisSolution ()
| Destructor. More...
virtual void | print (std::ostream &os) const
| Print out the solution. More...
virtual AlpsEncoded * | encode () const
| The method that encodes the solution into a encoded object. More...
virtual AlpsKnowledge * | decode (AlpsEncoded &encoded) const
| The method that decodes the solution from a encoded object. More...
Public Member Functions inherited from BcpsSolution
| BcpsSolution ()
| Default constructor. More...
| BcpsSolution (int size, const double *values, double q)
| Useful constructor. More...
| BcpsSolution (int size, BcpsObject_p *&objects, double *&values, double q)
| Construct an object using the given arrays. More...
virtual | ~BcpsSolution ()
| Distructor. More...
AlpsReturnStatus | encodeBcps (AlpsEncoded *encoded) const
| Pack Bcps part of solution into an encoded objects. More...
AlpsReturnStatus | decodeBcps (AlpsEncoded &encoded)
| Unpack Bcps part of solution from an encoded objects. More...
int | getSize () const
| Get the appropriate data member. More...
const BcpsObject_p * | getObjects () const
| Get the appropriate data member. More...
const double * | getValues () const
| Get the appropriate data member. More...
double | getQuality () const
| Get the appropriate data member. More...
void | setSize (int s)
| Set/assign the appropriate data member. More...
void | assignObjects (BcpsObject_p *&obj)
| Set/assign the appropriate data member. More...
void | setValues (const double *vs, int s)
| Set/assign the appropriate data member. More...
void | setQuality (double q)
| Set/assign the appropriate data member. More...
virtual BcpsSolution * | selectNonzeros (const double etol=1e-5) const
| Select the fractional/nonzero elements from the solution array and return a new object in compacted form. More...
virtual BcpsSolution * | selectFractional (const double etol=1e-5) const
| Select the fractional/nonzero elements from the solution array and return a new object in compacted form. More...
Public Member Functions inherited from AlpsSolution
| AlpsSolution ()
| Default constructor. More...
| AlpsSolution (const AlpsNodeIndex_t i, const int d)
| Constructor to set index and depth. More...
virtual | ~AlpsSolution ()
| Destructor. More...
AlpsNodeIndex_t | getIndex ()
| Get index where solution was found. More...
void | setIndex (const AlpsNodeIndex_t i)
| Set index where solution was found. More...
int | getDepth ()
| Get depth where solution was found. More...
void | setDepth (const int d)
| Set depth where solution was found. More...
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. More...
AlpsEncoded * | getEncoded () const
| Get/set encoded. More...
void | setEncoded (AlpsEncoded *e)

## Additional Inherited Members
Protected Attributes inherited from BcpsSolution
int | size_
| Size of values_. More...
BcpsObject_p * | objects_
| List of objects associated with values. More...
double * | values_
| Solution values. More...
double | quality_
| Quality/Objective value associated with this solution. More...
Protected Attributes inherited from AlpsKnowledge
KnowledgeType | type_

## Detailed Description

This class contains the solutions generated by the LP solver (either primal or dual.

The class exists primarily to pass solutions to the object generator(s).

Definition at line 36 of file BlisSolution.h.

## Constructor & Destructor Documentation

BlisSolution::BlisSolution | ( |  | ) |
| inline

Default constructor.

Definition at line 43 of file BlisSolution.h.

BlisSolution::BlisSolution | ( | int | s,
|  | const double * | values,
|  | double | objValue
| ) |  |
| inline

Useful constructor.

Definition at line 49 of file BlisSolution.h.

virtual BlisSolution::~BlisSolution | ( |  | ) |
| inline virtual

Destructor.

Definition at line 55 of file BlisSolution.h.

BlisSolution::BlisSolution | ( |  | ) |
| inline

Default constructor.

Definition at line 43 of file BlisSolution.h.

BlisSolution::BlisSolution | ( | int | s,
|  | const double * | values,
|  | double | objValue
| ) |  |
| inline

Useful constructor.

Definition at line 49 of file BlisSolution.h.

virtual BlisSolution::~BlisSolution | ( |  | ) |
| inline virtual

Destructor.

Definition at line 55 of file BlisSolution.h.

## Member Function Documentation

virtual AlpsEncoded* BlisSolution::encode | ( |  | ) | const
| inline virtual

Check if IP feasible.

If yes, return a IP solution; othersize, return NULL. The method that encodes the solution into a encoded object.

Reimplemented from AlpsKnowledge.

Reimplemented in VrpSolution.

Definition at line 62 of file BlisSolution.h.

virtual AlpsKnowledge* BlisSolution::decode | ( | AlpsEncoded & | encoded | ) | const
| inline virtual

The method that decodes the solution from a encoded object.

Reimplemented from AlpsKnowledge.

Reimplemented in VrpSolution.

Definition at line 70 of file BlisSolution.h.

virtual void BlisSolution::print | ( | std::ostream & | os | ) | const
| inline virtual

Print out the solution.

Print the solution.

Reimplemented from BcpsSolution.

Reimplemented in VrpSolution.

Definition at line 59 of file BlisSolution.h.

virtual AlpsEncoded* BlisSolution::encode | ( |  | ) | const
| inline virtual

The method that encodes the solution into a encoded object.

Reimplemented from AlpsKnowledge.

Reimplemented in VrpSolution.

Definition at line 80 of file BlisSolution.h.

virtual AlpsKnowledge* BlisSolution::decode | ( | AlpsEncoded & | encoded | ) | const
| inline virtual

The method that decodes the solution from a encoded object.

Reimplemented from AlpsKnowledge.

Reimplemented in VrpSolution.

Definition at line 88 of file BlisSolution.h.

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

- /tmp/CHiPPS-Blis-0.94.3/Bcps/examples/Blis/BlisSolution.h
- /tmp/CHiPPS-Blis-0.94.3/Blis/src/BlisSolution.h