Bonmin  1.8.8
BonHeuristicDiveMIPVectorLength.hpp
Go to the documentation of this file.
1 // Copyright (C) 2007, International Business Machines Corporation and others.
2 // All Rights Reserved.
3 // This code is published under the Eclipse Public License.
4 //
5 // Authors :
6 // Joao P. Goncalves, International Business Machines Corporation
7 //
8 // Date : November 12, 2007
9 
10 #ifndef BonHeuristicDiveMIPVectorLength_H
11 #define BonHeuristicDiveMIPVectorLength_H
12 
13 #include "BonBonminSetup.hpp"
14 #include "BonHeuristicDiveMIP.hpp"
15 
19 namespace Bonmin
20 {
22  public:
25 
28 
31 
34  {
35  delete [] columnLength_;
36  }
37 
40 
42  virtual CbcHeuristic * clone() const;
43 
45  virtual void setSetup(BonminSetup * setup){
47  Initialize(setup->options());
48  }
49 
51  virtual void setInternalVariables(TMINLP2TNLP* minlp);
52 
54 
56  virtual void selectVariableToBranch(TMINLP2TNLP* minlp,
57  const vector<int> & integerColumns,
58  const double* newSolution,
59  int& bestColumn,
60  int& bestRound);
61 
63  static void registerOptions(Ipopt::SmartPtr<Bonmin::RegisteredOptions> roptions);
64 
66  void Initialize(Ipopt::SmartPtr<Ipopt::OptionsList> options);
67 
68  private:
71 
72  };
73 }
74 #endif
int * columnLength_
the number of nonzero elements in each column
void Initialize(Ipopt::SmartPtr< Ipopt::OptionsList > options)
Initiaize using passed options.
HeuristicDiveMIPVectorLength()
Default Constructor.
virtual CbcHeuristic * clone() const
Clone.
virtual void setSetup(BonminSetup *setup)
Change setup used for heuristic.
HeuristicDiveMIPVectorLength & operator=(const HeuristicDiveMIPVectorLength &rhs)
Assignment operator.
virtual void setSetup(BonminSetup *setup)
Change setup used for heuristic.
Ipopt::SmartPtr< Ipopt::OptionsList > options()
Acces list of Options.
virtual void setInternalVariables(TMINLP2TNLP *minlp)
sets internal variables
This is an adapter class that converts a TMINLP to a TNLP to be solved by Ipopt.
virtual void selectVariableToBranch(TMINLP2TNLP *minlp, const vector< int > &integerColumns, const double *newSolution, int &bestColumn, int &bestRound)
Selects the next variable to branch on.
static void registerOptions(Ipopt::SmartPtr< Bonmin::RegisteredOptions > roptions)
Register the options common to all local search based heuristics.