30 #ifndef BlisConGenerator_h_
31 #define BlisConGenerator_h_
133 {
name_ =
"UNKNOWN"; }
138 const char *
name = NULL,
143 bool infeasible =
false);
void setCutGenerationFreq(int freq)
Set the con generation strategy.
int calls_
The times of calling this generator.
int cutGenerationFreq() const
Get the con generation interval.
void addTime(double t)
Increase Cpu time used.
int numConsGenerated_
Number of cons generated.
void addCalls(int n=1)
Increase the number of called.
BlisModel * model_
The client model.
bool normal_
Whether to call the generator in the normal place.
bool whenInfeasible() const
Get whether the con generator should be called when the subproblem is found to be infeasible...
int cutGenerationFrequency_
The frequency of calls to the cut generator.
bool whenInfeasible_
Whether to call generator when a subproblem is found to be infeasible.
double time() const
Cpu time used.
bool normal() const
Get whether the con generator should be called in the normal place.
BlisConGenerator & operator=(const BlisConGenerator &rhs)
Assignment operator.
char * name_
Name of generator.
void setNormal(bool value)
Set whether the con generator should be called in the normal place.
BlisModel * getModel()
Set the client model.
void refreshModel(BlisModel *model)
Set the client model.
virtual ~BlisConGenerator()
Destructor.
std::string name() const
return name of generator.
int numConsGenerated()
Get number of generated cons.
Interface between Blis and Cut Generation Library.
int calls() const
Number called.
int numConsUsed()
Get number of used cons.
void addNumConsUsed(int n)
Increase the number of generated cons.
BlisConGenerator()
Default constructor.
bool atSolution() const
Get whether the con generator should be called when a solution is found.
int strategy_
When to call CglCutGenerator::generateCuts routine.
void setStrategy(BlisCutStrategy value)
Set the con generation strategy.
void addNumConsGenerated(int n)
Increase the number of generated cons.
BlisCutStrategy strategy() const
Get the con generation interval.
Cut Generator Base Class.
void setName(const char *str)
return name of generator.
void setWhenInfeasible(bool value)
Set whether the con generator should be called when the subproblem is found to be infeasible...
bool atSolution_
Whether to call the generator when a new solution is found.
const char * name() const
return name of generator.
void addNoConsCalls(int n=1)
Increase the number of no cons called.
int noConsCalls() const
Number called and no cons found.
Validate cuts against a known solution.
void setAtSolution(bool value)
Set whether the con generator should be called when a solution is found.
double time_
Used CPU/User time.
void setModel(BlisModel *m)
Set the model.
int numConsUsed_
Number of cons used.
int strategy() const
Get the con generation interval.
int noConsCalls_
The times of calling this generator and no cons found.
virtual bool generateConstraints(BcpsConstraintPool &conPool)
Generate cons for the client model.
CglCutGenerator * generator_
The CglCutGenerator object.
std::string name_
Name of generator.
CglCutGenerator * generator() const
Get the CglCutGenerator bound to this BlisConGenerator.
BlisCutStrategy strategy_
When to call CglCutGenerator::generateCuts routine.