coin-Bcp
BCP_warmstart_basis.hpp
Go to the documentation of this file.
1 // Copyright (C) 2000, International Business Machines
2 // Corporation and others. All Rights Reserved.
3 #ifndef _BCP_WARMSTART_BASIS_H
4 #define _BCP_WARMSTART_BASIS_H
5 
6 #include "BCP_warmstart.hpp"
7 #include "BCP_vector_change.hpp"
8 
9 /* NOTE:
10  Doxygen gracefully generates description for all inherited methods if they
11  are not documented here. So the virtual methods are documented ONLY if they
12  have something additional to say.
13 */
14 
15 //#############################################################################
16 
25 private:
28 
34 
35 private:
40 
41 public:
50  BCP_warmstart_basis(const char* vfirst, const char* vlast,
51  const char* cfirst, const char* clast) :
52  _var_stat(vfirst, vlast), _cut_stat(cfirst, clast) {}
56 
60  // Inherited methods --------------------------------------------------------
61 
65  virtual CoinWarmStart* convert_to_CoinWarmStart() const;
66 
67  virtual BCP_storage_t storage() const;
68 
69  virtual BCP_warmstart* clone() const {
70  return new BCP_warmstart_basis(*this);
71  }
72 
73  virtual BCP_warmstart* empty_wrt_this() const {
74  // The default constructor creates an empty WrtParent warmstart info
75  // (i.e., no change wrt the parent)
76  return new BCP_warmstart_basis();
77  }
78 
79  virtual int storage_size() const {
81  }
82 
83  virtual void update(const BCP_warmstart* const change);
84 
85  virtual BCP_warmstart* as_change(const BCP_warmstart* const old_ws,
86  const BCP_vec<int>& del_vars,
87  const BCP_vec<int>& del_cuts,
88  const double petol,
89  const double detol) const;
90 
91  // Not inherited methods ----------------------------------------------------
92 
94  void pack(BCP_buffer& buf) const {
95  _var_stat.pack(buf);
96  _cut_stat.pack(buf);
97  }
98 };
99 
100 #endif
virtual void update(const BCP_warmstart *const change)
Update the current data with the one in the argument.
virtual CoinWarmStart * convert_to_CoinWarmStart() const
Return an CoinwarmStart object that can be fed to the LP engine.
virtual BCP_warmstart * empty_wrt_this() const
Create a warmstart info describing that no change should be done.
BCP_vec_change< char > _var_stat
The stati of the variables stored as a vector 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
Return a pointer to a warmstart info describing the currently stored data as a change with respect to...
int storage_size() const
Return how much memory it&#39;ll take to pack this info.
BCP_warmstart_basis(const BCP_warmstart_basis &ws)
Copy constructor.
Warmstarting information for the LP solver.
BCP_warmstart_basis & operator=(const BCP_warmstart_basis &)
The assignment operator is declared but not defined to disable it.
BCP_warmstart_basis()
The default constructor creates an empty WrtParent warmstart info (i.e., no change wrt the parent)...
void pack(BCP_buffer &buf) const
Pack the warmstart info into a buffer.
virtual int storage_size() const
Return how much memory it&#39;ll take to pack this warmstart info.
The data stored is with respect to the same kind of data in the parent of the search tree node...
Definition: BCP_enum.hpp:91
BCP_warmstart_basis(const char *vfirst, const char *vlast, const char *cfirst, const char *clast)
Create an explicitly stored warmstart info by considering the two character arrays ([vfirst...
virtual BCP_storage_t storage() const
Return how the warmstarting info is stored.
BCP_vec_change< char > _cut_stat
The stati of the cuts stored as a vector change.
virtual BCP_warmstart * clone() const
Make a replica of the current warmstart information.
Abstract base class for warm start information.
This class describes the message buffer used for all processes of BCP.
Definition: BCP_buffer.hpp:39
This class describes a warmstart information that consists of basis information for structural and ar...
BCP_storage_t
This enumerative constant describes how to store certain data for a search tree node.
Definition: BCP_enum.hpp:84
void pack(BCP_buffer &buf) const
Pack the data into a buffer.
~BCP_warmstart_basis()
Create the object by unpacking it from a buffer.
BCP_warmstart_basis(BCP_buffer &buf)
Create the object by unpacking it from a buffer.