This class describes a warmstart information that consists solely of the dual vector. More...
#include <BCP_warmstart_primaldual.hpp>
Public Member Functions | |
virtual CoinWarmStart * | convert_to_CoinWarmStart () const |
Return an CoinWarmStart object that can be fed to the LP engine. | |
virtual BCP_storage_t | storage () const |
Return how the warmstarting info is stored. | |
virtual BCP_warmstart * | clone () const |
Make a replica of the current warmstart information. | |
virtual BCP_warmstart * | empty_wrt_this () const |
Create a warmstart info describing that no change should be done. | |
virtual int | storage_size () const |
Return how much memory it'll take to pack this warmstart info. | |
virtual void | update (const BCP_warmstart *const change) |
virtual BCP_warmstart * | as_change (const BCP_warmstart *const old_ws, const BCP_vec< int > &del_vars, const BCP_vec< int > &del_cuts, const double petol, const double detol) const |
void | pack (BCP_buffer &buf) const |
Pack the warmstart info into a buffer. | |
Constructors and destructor | |
BCP_warmstart_primaldual (BCP_buffer &buf) | |
Create the object by unpacking it from a buffer. | |
BCP_warmstart_primaldual (const double *pfirst, const double *plast, const double *dfirst, const double *dlast) | |
Create an explicitly stored warmstart info by considering the double arrays [fpirst,plast) and [dpirst,dlast) as the primal and dual vectors. | |
BCP_warmstart_primaldual (const BCP_warmstart_primaldual &ws) | |
Copy constructor. | |
virtual | ~BCP_warmstart_primaldual () |
Create the object by unpacking it from a buffer. | |
Private Member Functions | |
BCP_warmstart_primaldual & | operator= (const BCP_warmstart_primaldual &) |
The assignment operator is declared but not defined to disable it. | |
BCP_warmstart_primaldual () | |
The default constructor creates an empty WrtParent warmstart info (i.e., no change wrt the parent). | |
Private Attributes | |
BCP_vec_change< double > | _primal |
The primal vector stored as a vector change. | |
BCP_vec_change< double > | _dual |
The dual vector stored as a vector change. |
This class describes a warmstart information that consists solely of the dual vector.
Definition at line 21 of file BCP_warmstart_primaldual.hpp.
BCP_warmstart_primaldual::BCP_warmstart_primaldual | ( | ) | [inline, private] |
The default constructor creates an empty WrtParent warmstart info (i.e., no change wrt the parent).
This is a private method since only the empty_wrt_this() method should be able to use this form of creation.
Definition at line 29 of file BCP_warmstart_primaldual.hpp.
Referenced by clone(), and empty_wrt_this().
BCP_warmstart_primaldual::BCP_warmstart_primaldual | ( | BCP_buffer & | buf | ) | [inline] |
Create the object by unpacking it from a buffer.
Definition at line 43 of file BCP_warmstart_primaldual.hpp.
BCP_warmstart_primaldual::BCP_warmstart_primaldual | ( | const double * | pfirst, | |
const double * | plast, | |||
const double * | dfirst, | |||
const double * | dlast | |||
) | [inline] |
Create an explicitly stored warmstart info by considering the double arrays [fpirst,plast)
and [dpirst,dlast)
as the primal and dual vectors.
Definition at line 47 of file BCP_warmstart_primaldual.hpp.
BCP_warmstart_primaldual::BCP_warmstart_primaldual | ( | const BCP_warmstart_primaldual & | ws | ) | [inline] |
Copy constructor.
Definition at line 51 of file BCP_warmstart_primaldual.hpp.
virtual BCP_warmstart_primaldual::~BCP_warmstart_primaldual | ( | ) | [inline, virtual] |
Create the object by unpacking it from a buffer.
Definition at line 54 of file BCP_warmstart_primaldual.hpp.
BCP_warmstart_primaldual& BCP_warmstart_primaldual::operator= | ( | const BCP_warmstart_primaldual & | ) | [private] |
The assignment operator is declared but not defined to disable it.
virtual CoinWarmStart* BCP_warmstart_primaldual::convert_to_CoinWarmStart | ( | ) | const [virtual] |
Return an CoinWarmStart object that can be fed to the LP engine.
The implementation for this class will return an CoinWarmStartDual object.
Implements BCP_warmstart.
virtual BCP_storage_t BCP_warmstart_primaldual::storage | ( | ) | const [inline, virtual] |
Return how the warmstarting info is stored.
Implements BCP_warmstart.
Definition at line 63 of file BCP_warmstart_primaldual.hpp.
References _dual, _primal, BCP_Storage_Explicit, BCP_Storage_NoData, BCP_Storage_WrtParent, and BCP_vec_change< T >::storage().
virtual BCP_warmstart* BCP_warmstart_primaldual::clone | ( | ) | const [inline, virtual] |
Make a replica of the current warmstart information.
Implements BCP_warmstart.
Definition at line 82 of file BCP_warmstart_primaldual.hpp.
References BCP_warmstart_primaldual().
virtual BCP_warmstart* BCP_warmstart_primaldual::empty_wrt_this | ( | ) | const [inline, virtual] |
Create a warmstart info describing that no change should be done.
This is really the task of a constructor, but BCP does not know the type of warmstart the user will use, so it will invoke this method for a warmstart that was created by the user. Tricky, isn't it?
Implements BCP_warmstart.
Definition at line 86 of file BCP_warmstart_primaldual.hpp.
References BCP_warmstart_primaldual().
virtual int BCP_warmstart_primaldual::storage_size | ( | ) | const [inline, virtual] |
Return how much memory it'll take to pack this warmstart info.
It is used when comparing which sort of storage is smaller.
Implements BCP_warmstart.
Definition at line 92 of file BCP_warmstart_primaldual.hpp.
References _dual, _primal, and BCP_vec_change< T >::storage_size().
virtual void BCP_warmstart_primaldual::update | ( | const BCP_warmstart *const | change | ) | [virtual] |
virtual BCP_warmstart* BCP_warmstart_primaldual::as_change | ( | const BCP_warmstart *const | old_ws, | |
const BCP_vec< int > & | del_vars, | |||
const BCP_vec< int > & | del_cuts, | |||
const double | petol, | |||
const double | detol | |||
) | const [virtual] |
void BCP_warmstart_primaldual::pack | ( | BCP_buffer & | buf | ) | const [inline] |
Pack the warmstart info into a buffer.
Definition at line 107 of file BCP_warmstart_primaldual.hpp.
References _dual, _primal, and BCP_vec_change< T >::pack().
BCP_vec_change<double> BCP_warmstart_primaldual::_primal [private] |
The primal vector stored as a vector change.
Definition at line 34 of file BCP_warmstart_primaldual.hpp.
Referenced by pack(), storage(), and storage_size().
BCP_vec_change<double> BCP_warmstart_primaldual::_dual [private] |
The dual vector stored as a vector change.
Definition at line 36 of file BCP_warmstart_primaldual.hpp.
Referenced by pack(), storage(), and storage_size().