#include <lpbase.hxx>

Public Member Functions | |
| BaseAlgorithm () | |
| virtual | ~BaseAlgorithm ()=0 |
| virtual void | solve ()=0 |
| Model * | getModel () const |
| void | setModel (Model *) |
| Model * | getCanonicalModel () const |
| ::scsolver::numeric::Matrix | getSolution () const |
| void | setSolution (const ::scsolver::numeric::Matrix &) |
| void | setCanonicalSolution (const ::scsolver::numeric::Matrix &mx) |
Private Attributes | |
| ::std::auto_ptr < BaseAlgorithmImpl > | m_pImpl |
Definition at line 43 of file lpbase.hxx.
| scsolver::numeric::lp::BaseAlgorithm::BaseAlgorithm | ( | ) |
Definition at line 234 of file lpbase.cxx.
| scsolver::numeric::lp::BaseAlgorithm::~BaseAlgorithm | ( | ) | [pure virtual] |
Definition at line 239 of file lpbase.cxx.
| virtual void scsolver::numeric::lp::BaseAlgorithm::solve | ( | ) | [pure virtual] |
| Model * scsolver::numeric::lp::BaseAlgorithm::getModel | ( | ) | const |
Definition at line 243 of file lpbase.cxx.
References m_pImpl.
Referenced by scsolver::numeric::lp::RevisedSimplexImpl::getModel(), scsolver::numeric::lp::UnoAlgorithm::solve(), and scsolver::numeric::lp::LpSolve::solve().
| void scsolver::numeric::lp::BaseAlgorithm::setModel | ( | Model * | p | ) |
| Model * scsolver::numeric::lp::BaseAlgorithm::getCanonicalModel | ( | ) | const |
This method returns a pointer to a canonical version of stored model. A canonical model is an original model with all its constant equivalent variables taken out. Note that when this method is used to obtain a model, then the solution reached needs to be set via setCanonicalSolution() call, or else the behavior is undefined.
Definition at line 253 of file lpbase.cxx.
References m_pImpl.
Referenced by scsolver::numeric::lp::BoundedRevisedSimplexImpl::initialize(), and scsolver::numeric::lp::RevisedSimplexImpl::solve().
| Matrix scsolver::numeric::lp::BaseAlgorithm::getSolution | ( | ) | const |
Definition at line 258 of file lpbase.cxx.
References m_pImpl.
Referenced by scsolver::numeric::lp::RevisedSimplexImpl::solve().
| void scsolver::numeric::lp::BaseAlgorithm::setSolution | ( | const ::scsolver::numeric::Matrix & | ) |
Referenced by scsolver::numeric::lp::UnoAlgorithm::solve(), and scsolver::numeric::lp::LpSolve::solve().
| void scsolver::numeric::lp::BaseAlgorithm::setCanonicalSolution | ( | const ::scsolver::numeric::Matrix & | mx | ) |
This method must be called to set a final solution if a canonical model is solved instead of an original model. When this is called, it reconstructs a solution for the original model by bringing back those constant equivalent variables which have been removed when getCanonicalModel() method was called.
| mx | solution matrix |
Referenced by scsolver::numeric::lp::BoundedRevisedSimplexImpl::solve(), and scsolver::numeric::lp::RevisedSimplexImpl::solve().
::std::auto_ptr<BaseAlgorithmImpl> scsolver::numeric::lp::BaseAlgorithm::m_pImpl [private] |
Reimplemented in scsolver::numeric::lp::RevisedSimplex, scsolver::numeric::lp::BoundedRevisedSimplex, scsolver::numeric::lp::LpSolve, and scsolver::numeric::lp::UnoAlgorithm.
Definition at line 80 of file lpbase.hxx.
Referenced by getCanonicalModel(), getModel(), getSolution(), and setModel().
1.5.3