Go to the documentation of this file.
6 #ifndef CbcHeuristicFeasibilityPump_H
7 #define CbcHeuristicFeasibilityPump_H
10 #include "OsiClpSolverInterface.hpp"
22 double downValue = 0.5,
bool roundExpensive =
false);
64 virtual int solution(
double &objectiveValue,
70 int maxAround = 1,
bool fixSatisfied =
false);
301 int numberIntegers,
const int *integerVariable,
304 double downValue = 0.5,
int *flip = 0);
315 class CbcDisasterHandler :
public OsiClpDisasterHandler {
321 virtual void intoSimplex();
324 virtual bool check()
const;
326 virtual void saveInfo();
328 virtual int typeOfDisaster();
336 CbcDisasterHandler(
CbcModel *model = NULL);
338 virtual ~CbcDisasterHandler();
340 CbcDisasterHandler(
const CbcDisasterHandler &);
342 CbcDisasterHandler &operator=(
const CbcDisasterHandler &);
344 virtual ClpDisasterHandler *clone()
const;
void setFixOnReducedCosts(int value)
Set whether to fix variables on known solution 0 - do not fix 1 - fix integers on reduced costs 2 - f...
void setFakeCutoff(double value)
Set fake cutoff (default COIN_DBL_MAX == off)
void setDefaultRounding(double value)
Set default rounding (default 0.5)
virtual int solution(double &objectiveValue, double *newSolution)
returns 0 if no solution, 1 if valid solution with better objective value than one passed in Sets sol...
double maximumTime_
Maximum Cpu seconds.
void setWeightFactor(double value)
Set weight factor (default 0.1)
void setRelativeIncrement(double value)
Set relative increment (default 0.0 == off)
int maximumPasses() const
Get maximum passes (default 100)
int fixOnReducedCosts_
Set whether to fix variables on known solution 0 - do not fix 1 - fix integers on reduced costs 2 - f...
void setMaximumRetries(int value)
Set maximum retries (default 1)
void setArtificialCost(double value)
Set threshold cost for using original cost - even on continuous (default infinity)
double maximumTime() const
Get maximum Time (default 0.0 == time limit off)
double initialWeight() const
Get initial weight (default 0.0 == off)
int maximumPasses_
Maximum number of passes.
int maximumRetries_
Maximum number of retries if we find a solution.
int solutionGeneral(double &objectiveValue, double *newSolution, int maxAround=1, bool fixSatisfied=false)
If general integers then adds variables to turn into binaries round solution.
double artificialCost() const
Get threshold cost for using original cost - even on continuous (default infinity)
double relativeIncrement() const
Get relative increment (default 0.0 == off)
double reducedCostMultiplier() const
Get reduced cost multiplier.
double iterationRatio() const
Get iteration to size ratio.
int solutionInternal(double &objectiveValue, double *newSolution)
Does real work.
double artificialCost_
Threshold cost for using original cost - even on continuous.
double startTime_
Start time.
int accumulate() const
Get accumulation option.
void setInitialWeight(double value)
Set initial weight (default 0.0 == off)
double defaultRounding() const
Get default rounding (default 0.5)
double weightFactor_
Factor for decreasing weight.
void setMaximumPasses(int value)
Set maximum passes (default 100)
CbcHeuristicFPump & operator=(const CbcHeuristicFPump &rhs)
Assignment operator.
double initialWeight_
Initial weight for true objective.
Simple Branch and bound class.
int accumulate_
Set use of multiple solutions and solves 0 - do not reuse solves, do not accumulate integer solutions...
double reducedCostMultiplier_
Reduced cost multiplier 1.0 as normal <1.0 (x) - pretend gap is x* actual gap - just for fixing.
virtual void generateCpp(FILE *fp)
Create C++ lines to get to current state.
int maximumRetries() const
Get maximum retries (default 1)
double absoluteIncrement_
If positive carry on after solution expecting gain of at least this.
void setReducedCostMultiplier(double value)
Set reduced cost multiplier 1.0 as normal <1.0 (x) - pretend gap is x* actual gap - just for fixing.
int rounds(OsiSolverInterface *solver, double *solution, int numberIntegers, const int *integerVariable, int passNumber, double downValue=0.5, int *flip=0)
Rounds solution - down if < downValue If roundExpensive then always to more expnsive.
double fakeCutoff_
Fake cutoff value.
virtual void setModel(CbcModel *model)
update model (This is needed if cliques update matrix etc)
void setIterationRatio(double value)
Set iteration to size ratio.
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...
void setMaximumTime(double value)
Set maximum Time (default off) - also sets starttime to current.
virtual CbcHeuristic * clone() const
Clone.
double fakeCutoff() const
Get fake cutoff (default 0.0 == off)
double relativeIncrement_
If positive carry on after solution expecting gain of at least this times objective.
double absoluteIncrement() const
Get absolute increment (default 0.0 == off)
void setAbsoluteIncrement(double value)
Set absolute increment (default 0.0 == off)
virtual void resetModel(CbcModel *model)
Resets stuff if model changes.
bool roundExpensive_
If true round to expensive.
int fixOnReducedCosts() const
Get reduced cost option.
void setAccumulate(int value)
Set use of multiple solutions and solves 0 - do not reuse solves, do not accumulate integer solutions...
double defaultRounding_
Default is round up if > this.
double iterationRatio_
If iterationRatio >0 use instead of maximumPasses_ test is iterations > ratio*(2*nrow+ncol)
double weightFactor() const
Get weight factor (default 0.1)