Couenne  0.2
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
CouenneBab.hpp
Go to the documentation of this file.
1 /* $Id: CouenneBab.hpp 888 2012-08-06 18:43:55Z stefan $
2  *
3  * Name: CouenneBab.hpp
4  * Author: Pietro Belotti
5  * Purpose: B&B object
6  * Created: 2012-01-25
7  *
8  * This file is licensed under the Eclipse Public License (EPL)
9  */
10 
11 #ifndef COUENNEBAB_H
12 #define COUENNEBAB_H
13 
14 #include "BonCbc.hpp"
15 #include "BonBabSetupBase.hpp"
16 
17 namespace Couenne {
18 
19  class CouenneProblem;
20 
21  class CouenneBab: public Bonmin::Bab {
22 
23  public:
24 
25  CouenneBab ();
26 
27  virtual ~CouenneBab();
28 
29  void setProblem (CouenneProblem *p);
30 
31  virtual void branchAndBound (Bonmin::BabSetupBase &s);
32 
36  const double * bestSolution() const;
37 
39  double bestObj() const;
40 
42  double bestBound() { return CoinMin(Bonmin::Bab::bestBound(), bestObj()); }
43 
44  protected:
45 
47 
48  };
49 }
50 
51 #endif
const double * bestSolution() const
Get the best solution known to the problem (is optimal if MipStatus is FeasibleOptimal).
virtual ~CouenneBab()
Destructor.
CouenneProblem * problem_
Definition: CouenneBab.hpp:46
virtual void branchAndBound(Bonmin::BabSetupBase &s)
Carry out branch and bound.
Class for MINLP problems with symbolic information.
void setProblem(CouenneProblem *p)
CouenneBab()
Constructor.
double bestBound()
return the best known lower bound on the objective value
Definition: CouenneBab.hpp:42
double bestObj() const
Return objective value of the bestSolution.