Class for storing a primal-dual solution with basis information. More...
#include <solbase.h>
Public Member Functions | |
bool | isPrimalFeasible () const |
is the stored solution primal feasible? More... | |
bool | getPrimalSol (VectorBase< R > &vector) const |
gets the primal solution vector; returns true on success More... | |
bool | getSlacks (VectorBase< R > &vector) const |
gets the vector of slack values; returns true on success More... | |
bool | hasPrimalRay () const |
is a primal unbounded ray available? More... | |
bool | getPrimalRaySol (VectorBase< R > &vector) const |
gets the primal unbounded ray if available; returns true on success More... | |
bool | isDualFeasible () const |
is a dual solution available? More... | |
bool | getDualSol (VectorBase< R > &vector) const |
gets the dual solution vector; returns true on success More... | |
bool | getRedCostSol (VectorBase< R > &vector) const |
gets the vector of reduced cost values if available; returns true on success More... | |
bool | hasDualFarkas () const |
is a dual farkas ray available? More... | |
bool | getDualFarkasSol (VectorBase< R > &vector) const |
gets the Farkas proof if available; returns true on success More... | |
int | totalSizePrimal (const int base=2) const |
returns total size of primal solution More... | |
int | totalSizeDual (const int base=2) const |
returns total size of dual solution More... | |
int | dlcmSizePrimal (const int base=2) const |
returns size of least common multiple of denominators in primal solution More... | |
int | dlcmSizeDual (const int base=2) const |
returns size of least common multiple of denominators in dual solution More... | |
int | dmaxSizePrimal (const int base=2) const |
returns size of largest denominator in primal solution More... | |
int | dmaxSizeDual (const int base=2) const |
returns size of largest denominator in dual solution More... | |
void | invalidate () |
invalidate solution More... | |
Private Member Functions | |
SolBase () | |
default constructor only for friends More... | |
SolBase< R > & | operator= (const SolBase< R > &sol) |
assignment operator only for friends More... | |
template<class S > | |
SolBase< R > & | operator= (const SolBase< S > &sol) |
assignment operator only for friends More... | |
Private Attributes | |
VectorBase< R > | _primal |
VectorBase< R > | _slacks |
VectorBase< R > | _primalRay |
VectorBase< R > | _dual |
VectorBase< R > | _redCost |
VectorBase< R > | _dualFarkas |
R | _objVal |
unsigned int | _isPrimalFeasible: 1 |
unsigned int | _hasPrimalRay: 1 |
unsigned int | _isDualFeasible: 1 |
unsigned int | _hasDualFarkas: 1 |
Friends | |
template<class T > | |
class | SoPlexBase |
template<class S > | |
class | SolBase |
Class for storing a primal-dual solution with basis information.
|
private |
default constructor only for friends
Definition at line 244 of file solbase.h.
References SolBase< R >::invalidate().
int dlcmSizeDual | ( | const int | base = 2 | ) | const |
returns size of least common multiple of denominators in dual solution
Definition at line 178 of file solbase.h.
References SolBase< R >::_dual, SolBase< R >::_dualFarkas, SolBase< R >::_hasDualFarkas, SolBase< R >::_isDualFeasible, and soplex::dlcmSizeRational().
int dlcmSizePrimal | ( | const int | base = 2 | ) | const |
returns size of least common multiple of denominators in primal solution
Definition at line 164 of file solbase.h.
References SolBase< R >::_hasPrimalRay, SolBase< R >::_isPrimalFeasible, SolBase< R >::_primal, SolBase< R >::_primalRay, and soplex::dlcmSizeRational().
int dmaxSizeDual | ( | const int | base = 2 | ) | const |
returns size of largest denominator in dual solution
Definition at line 206 of file solbase.h.
References SolBase< R >::_dual, SolBase< R >::_dualFarkas, SolBase< R >::_hasDualFarkas, SolBase< R >::_isDualFeasible, and soplex::dmaxSizeRational().
int dmaxSizePrimal | ( | const int | base = 2 | ) | const |
returns size of largest denominator in primal solution
Definition at line 192 of file solbase.h.
References SolBase< R >::_hasPrimalRay, SolBase< R >::_isPrimalFeasible, SolBase< R >::_primal, SolBase< R >::_primalRay, and soplex::dmaxSizeRational().
bool getDualFarkasSol | ( | VectorBase< R > & | vector | ) | const |
gets the Farkas proof if available; returns true on success
Definition at line 127 of file solbase.h.
References SolBase< R >::_dualFarkas, and SolBase< R >::_hasDualFarkas.
bool getDualSol | ( | VectorBase< R > & | vector | ) | const |
gets the dual solution vector; returns true on success
Definition at line 105 of file solbase.h.
References SolBase< R >::_dual, and SolBase< R >::_isDualFeasible.
bool getPrimalRaySol | ( | VectorBase< R > & | vector | ) | const |
gets the primal unbounded ray if available; returns true on success
Definition at line 90 of file solbase.h.
References SolBase< R >::_hasPrimalRay, and SolBase< R >::_primalRay.
bool getPrimalSol | ( | VectorBase< R > & | vector | ) | const |
gets the primal solution vector; returns true on success
Definition at line 68 of file solbase.h.
References SolBase< R >::_isPrimalFeasible, and SolBase< R >::_primal.
bool getRedCostSol | ( | VectorBase< R > & | vector | ) | const |
gets the vector of reduced cost values if available; returns true on success
Definition at line 113 of file solbase.h.
References SolBase< R >::_isDualFeasible, and SolBase< R >::_redCost.
bool getSlacks | ( | VectorBase< R > & | vector | ) | const |
gets the vector of slack values; returns true on success
Definition at line 76 of file solbase.h.
References SolBase< R >::_isPrimalFeasible, and SolBase< R >::_slacks.
bool hasDualFarkas | ( | ) | const |
is a dual farkas ray available?
Definition at line 121 of file solbase.h.
References SolBase< R >::_hasDualFarkas.
bool hasPrimalRay | ( | ) | const |
is a primal unbounded ray available?
Definition at line 84 of file solbase.h.
References SolBase< R >::_hasPrimalRay.
void invalidate | ( | ) |
invalidate solution
Definition at line 220 of file solbase.h.
References SolBase< R >::_hasDualFarkas, SolBase< R >::_hasPrimalRay, SolBase< R >::_isDualFeasible, and SolBase< R >::_isPrimalFeasible.
Referenced by SolBase< R >::SolBase().
bool isDualFeasible | ( | ) | const |
is a dual solution available?
Definition at line 99 of file solbase.h.
References SolBase< R >::_isDualFeasible.
bool isPrimalFeasible | ( | ) | const |
is the stored solution primal feasible?
Definition at line 62 of file solbase.h.
References SolBase< R >::_isPrimalFeasible.
assignment operator only for friends
Definition at line 251 of file solbase.h.
References SolBase< R >::_dual, SolBase< R >::_dualFarkas, SolBase< R >::_hasDualFarkas, SolBase< R >::_hasPrimalRay, SolBase< R >::_isDualFeasible, SolBase< R >::_isPrimalFeasible, SolBase< R >::_objVal, SolBase< R >::_primal, SolBase< R >::_primalRay, SolBase< R >::_redCost, and SolBase< R >::_slacks.
assignment operator only for friends
Definition at line 281 of file solbase.h.
References SolBase< R >::_dual, SolBase< R >::_dualFarkas, SolBase< R >::_hasDualFarkas, SolBase< R >::_hasPrimalRay, SolBase< R >::_isDualFeasible, SolBase< R >::_isPrimalFeasible, SolBase< R >::_objVal, SolBase< R >::_primal, SolBase< R >::_primalRay, SolBase< R >::_redCost, and SolBase< R >::_slacks.
int totalSizeDual | ( | const int | base = 2 | ) | const |
returns total size of dual solution
Definition at line 150 of file solbase.h.
References SolBase< R >::_dual, SolBase< R >::_dualFarkas, SolBase< R >::_hasDualFarkas, SolBase< R >::_isDualFeasible, and soplex::totalSizeRational().
int totalSizePrimal | ( | const int | base = 2 | ) | const |
returns total size of primal solution
Definition at line 136 of file solbase.h.
References SolBase< R >::_hasPrimalRay, SolBase< R >::_isPrimalFeasible, SolBase< R >::_primal, SolBase< R >::_primalRay, and soplex::totalSizeRational().
|
friend |
|
private |
Definition at line 232 of file solbase.h.
Referenced by SolBase< R >::dlcmSizeDual(), SolBase< R >::dmaxSizeDual(), SolBase< R >::getDualSol(), SolBase< R >::operator=(), and SolBase< R >::totalSizeDual().
|
private |
Definition at line 234 of file solbase.h.
Referenced by SolBase< R >::dlcmSizeDual(), SolBase< R >::dmaxSizeDual(), SolBase< R >::getDualFarkasSol(), SolBase< R >::operator=(), and SolBase< R >::totalSizeDual().
|
private |
Definition at line 241 of file solbase.h.
Referenced by SolBase< R >::dlcmSizeDual(), SolBase< R >::dmaxSizeDual(), SolBase< R >::getDualFarkasSol(), SolBase< R >::hasDualFarkas(), SolBase< R >::invalidate(), SolBase< R >::operator=(), and SolBase< R >::totalSizeDual().
|
private |
Definition at line 239 of file solbase.h.
Referenced by SolBase< R >::dlcmSizePrimal(), SolBase< R >::dmaxSizePrimal(), SolBase< R >::getPrimalRaySol(), SolBase< R >::hasPrimalRay(), SolBase< R >::invalidate(), SolBase< R >::operator=(), and SolBase< R >::totalSizePrimal().
|
private |
Definition at line 240 of file solbase.h.
Referenced by SolBase< R >::dlcmSizeDual(), SolBase< R >::dmaxSizeDual(), SolBase< R >::getDualSol(), SolBase< R >::getRedCostSol(), SolBase< R >::invalidate(), SolBase< R >::isDualFeasible(), SolBase< R >::operator=(), and SolBase< R >::totalSizeDual().
|
private |
Definition at line 238 of file solbase.h.
Referenced by SolBase< R >::dlcmSizePrimal(), SolBase< R >::dmaxSizePrimal(), SolBase< R >::getPrimalSol(), SolBase< R >::getSlacks(), SolBase< R >::invalidate(), SolBase< R >::isPrimalFeasible(), SolBase< R >::operator=(), and SolBase< R >::totalSizePrimal().
|
private |
Definition at line 236 of file solbase.h.
Referenced by SolBase< R >::operator=().
|
private |
Definition at line 229 of file solbase.h.
Referenced by SolBase< R >::dlcmSizePrimal(), SolBase< R >::dmaxSizePrimal(), SolBase< R >::getPrimalSol(), SolBase< R >::operator=(), and SolBase< R >::totalSizePrimal().
|
private |
Definition at line 231 of file solbase.h.
Referenced by SolBase< R >::dlcmSizePrimal(), SolBase< R >::dmaxSizePrimal(), SolBase< R >::getPrimalRaySol(), SolBase< R >::operator=(), and SolBase< R >::totalSizePrimal().
|
private |
Definition at line 233 of file solbase.h.
Referenced by SolBase< R >::getRedCostSol(), and SolBase< R >::operator=().
|
private |
Definition at line 230 of file solbase.h.
Referenced by SolBase< R >::getSlacks(), and SolBase< R >::operator=().