Cbc
2.10.13
Toggle main menu visibility
Loading...
Searching...
No Matches
Cbc
src
CbcHeuristicVND.hpp
Go to the documentation of this file.
1
// $Id$
2
// Copyright (C) 2006, International Business Machines
3
// Corporation and others. All Rights Reserved.
4
// This code is licensed under the terms of the Eclipse Public License (EPL).
5
6
// edwin 12/5/09 carved out of CbcHeuristicRINS
7
8
#ifndef CbcHeuristicVND_H
9
#define CbcHeuristicVND_H
10
11
#include "
CbcHeuristic.hpp
"
12
15
16
class
CbcHeuristicVND
:
public
CbcHeuristic
{
17
public
:
18
// Default Constructor
19
CbcHeuristicVND
();
20
21
/* Constructor with model - assumed before cuts
22
Initial version does not do Lps
23
*/
24
CbcHeuristicVND
(
CbcModel
&
model
);
25
26
// Copy constructor
27
CbcHeuristicVND
(
const
CbcHeuristicVND
&);
28
29
// Destructor
30
~CbcHeuristicVND
();
31
33
virtual
CbcHeuristic
*
clone
()
const
;
34
36
CbcHeuristicVND
&
operator=
(
const
CbcHeuristicVND
&rhs);
37
39
virtual
void
generateCpp
(FILE *fp);
40
42
virtual
void
resetModel
(
CbcModel
*
model
);
43
45
virtual
void
setModel
(
CbcModel
*
model
);
46
47
using
CbcHeuristic::solution
;
52
virtual
int
solution
(
double
&
objectiveValue
,
53
double
*newSolution);
55
int
solutionFix
(
double
&
objectiveValue
,
56
double
*newSolution,
57
const
int
*keep);
58
60
inline
void
setHowOften
(
int
value)
61
{
62
howOften_
= value;
63
}
64
65
inline
double
*
baseSolution
()
const
66
{
67
return
baseSolution_
;
68
}
69
70
protected
:
71
// Data
72
74
int
numberSolutions_
;
76
int
howOften_
;
78
int
numberSuccesses_
;
80
int
numberTries_
;
82
int
lastNode_
;
84
int
stepSize_
;
85
int
k_
;
86
int
kmax_
;
87
int
nDifferent_
;
89
double
*
baseSolution_
;
90
};
91
92
#endif
93
94
/* vi: softtabstop=2 shiftwidth=2 expandtab tabstop=2
95
*/
CbcHeuristic.hpp
objectiveValue
double objectiveValue() const
Definition
CbcNode.hpp:221
model
CbcModel * model() const
Return model.
Definition
CbcObject.hpp:252
CbcHeuristicVND::generateCpp
virtual void generateCpp(FILE *fp)
Create C++ lines to get to current state.
CbcHeuristicVND::numberSuccesses_
int numberSuccesses_
Number of successes.
Definition
CbcHeuristicVND.hpp:78
CbcHeuristicVND::~CbcHeuristicVND
~CbcHeuristicVND()
CbcHeuristicVND::lastNode_
int lastNode_
Node when last done.
Definition
CbcHeuristicVND.hpp:82
CbcHeuristicVND::setHowOften
void setHowOften(int value)
Sets how often to do it.
Definition
CbcHeuristicVND.hpp:60
CbcHeuristicVND::stepSize_
int stepSize_
Step size for decomposition.
Definition
CbcHeuristicVND.hpp:84
CbcHeuristicVND::baseSolution_
double * baseSolution_
Base solution.
Definition
CbcHeuristicVND.hpp:89
CbcHeuristicVND::numberSolutions_
int numberSolutions_
Number of solutions so we can do something at solution.
Definition
CbcHeuristicVND.hpp:74
CbcHeuristicVND::clone
virtual CbcHeuristic * clone() const
Clone.
CbcHeuristicVND::solutionFix
int solutionFix(double &objectiveValue, double *newSolution, const int *keep)
This version fixes stuff and does IP.
CbcHeuristicVND::setModel
virtual void setModel(CbcModel *model)
update model (This is needed if cliques update matrix etc)
CbcHeuristicVND::nDifferent_
int nDifferent_
Definition
CbcHeuristicVND.hpp:87
CbcHeuristicVND::resetModel
virtual void resetModel(CbcModel *model)
Resets stuff if model changes.
CbcHeuristicVND::solution
virtual int solution(double &objectiveValue, double *newSolution)
returns 0 if no solution, 1 if valid solution.
CbcHeuristicVND::k_
int k_
Definition
CbcHeuristicVND.hpp:85
CbcHeuristicVND::CbcHeuristicVND
CbcHeuristicVND()
CbcHeuristicVND::baseSolution
double * baseSolution() const
base solution array so we can set
Definition
CbcHeuristicVND.hpp:65
CbcHeuristicVND::operator=
CbcHeuristicVND & operator=(const CbcHeuristicVND &rhs)
Assignment operator.
CbcHeuristicVND::CbcHeuristicVND
CbcHeuristicVND(const CbcHeuristicVND &)
CbcHeuristicVND::howOften_
int howOften_
How often to do (code can change).
Definition
CbcHeuristicVND.hpp:76
CbcHeuristicVND::numberTries_
int numberTries_
Number of tries.
Definition
CbcHeuristicVND.hpp:80
CbcHeuristicVND::CbcHeuristicVND
CbcHeuristicVND(CbcModel &model)
CbcHeuristicVND::kmax_
int kmax_
Definition
CbcHeuristicVND.hpp:86
CbcHeuristic::solution
virtual int solution(double &objectiveValue, double *newSolution)=0
returns 0 if no solution, 1 if valid solution with better objective value than one passed in Sets sol...
CbcHeuristic::CbcHeuristic
CbcHeuristic()
CbcModel
Simple Branch and bound class.
Definition
CbcModel.hpp:100
Generated by
1.17.0