/home/coin/SVN-release/CoinAll-1.1.0/Bcp/src/include/BCP_vg.hpp

Go to the documentation of this file.
00001 // Copyright (C) 2000, International Business Machines
00002 // Corporation and others.  All Rights Reserved.
00003 #ifndef _BCP_VG_H
00004 #define _BCP_VG_H
00005 
00006 // This file is fully docified.
00007 
00008 #include <cfloat>
00009 
00010 #include "BCP_math.hpp"
00011 #include "BCP_message_tag.hpp"
00012 #include "BCP_vector.hpp"
00013 #include "BCP_buffer.hpp"
00014 #include "BCP_vg_param.hpp"
00015 #include "BCP_parameters.hpp"
00016 #include "BCP_process.hpp"
00017 
00018 class BCP_vg_user;
00019 class BCP_message_environment;
00020 class BCP_proc_id;
00021 class BCP_problem_core;
00022 class BCP_var;
00023 class BCP_cut;
00024 
00032 class BCP_vg_prob : public BCP_process {
00033 private:
00037    BCP_vg_prob(const BCP_vg_prob&);
00039    BCP_vg_prob& operator=(const BCP_vg_prob&);
00042 public:
00045    // User provided members--------------------------------------------------
00049    BCP_vg_user* user;
00053    BCP_message_environment* msg_env;
00054 
00056    BCP_buffer  msg_buf;
00057 
00059    BCP_parameter_set<BCP_vg_par> par;
00060 
00062    BCP_problem_core* core;
00063    
00065     //   BCP_proc_id* tree_manager;
00066 
00068    double upper_bound;
00069 
00070    // the cuts and corresponding dual values in the LP formulation that were
00071    // sent over to generate variables from. Also, the sender and which node
00072    // in which iteration do these cuts/duals belong to.
00078    BCP_vec<BCP_cut*> cuts;
00080    BCP_vec<double>   pi;
00082    BCP_proc_id*      sender;
00083 
00085    int phase;
00087    int node_level;
00089    int node_index;
00092    int node_iteration;
00093 
00096 public:
00101    BCP_vg_prob(BCP_proc_id* my_id, BCP_proc_id* parent);
00103    virtual ~BCP_vg_prob();
00109    inline bool has_ub() const { return upper_bound < BCP_DBL_MAX / 10; }
00112    inline double ub() const   { return upper_bound; }
00118    inline void ub(const double bd) { upper_bound = bd; }
00119 
00122    bool probe_messages();
00127    BCP_cut* unpack_cut();
00128    //--------------------------------------------------------------------------
00129    virtual BCP_buffer& get_message_buffer() { return msg_buf; }
00130    virtual void process_message();
00131 };
00132 
00133 // This function is used only internally.
00134 bool
00135 BCP_vg_process_message(BCP_vg_prob& p, BCP_buffer& buf);
00136 
00137 #endif

Generated on Sun Nov 14 14:06:30 2010 for Coin-All by  doxygen 1.4.7