Abstracts a CBC LP solver that can solve a scheduling instance.
More...
#include <cbc_fractional_scheduler.h>
Abstracts a CBC LP solver that can solve a scheduling instance.
Creates a CBC fractional scheduler with given scheduling instance.
- Parameters
-
si | The scheduling instance of the CBC LP scheduler. |
void delphos::CBCFractionalScheduler::AddSetting |
( |
const string & |
setting | ) |
|
Adds a setting for the solve process.
- Parameters
-
setting | The setting to be added. |
void delphos::CBCFractionalScheduler::ComputeExpectedTime |
( |
const string |
column | ) |
|
|
virtual |
Computes the expected times.
- Parameters
-
column | The column name in which the expected times are saved. |
Reimplemented from delphos::FractionalScheduler.
bool delphos::CBCFractionalScheduler::CreateModel |
( |
| ) |
|
Inits the solver and load the model in CBC.
Return true if the model has been successfully loaded in CBC.
const double delphos::CBCFractionalScheduler::GetDual |
( |
const string & |
cname | ) |
|
|
virtual |
Returns the dual value of given constraint.
- Parameters
-
cname | The name of the constraint of which the dual value is returned. |
the cname of constraint of original name name can be name_lower and name_upper that corresponds to lower bound constraint and upper bound constraint.
Reimplemented from delphos::FractionalScheduler.
bool delphos::CBCFractionalScheduler::Run |
( |
| ) |
|
|
virtual |
Generates the model in CBC and optimize it.
Return true only if the model has been successfully optimized.
Reimplemented from delphos::FractionalScheduler.
void delphos::CBCFractionalScheduler::SetLogFile |
( |
const string & |
name | ) |
|
|
virtual |
void delphos::CBCFractionalScheduler::SetLogLevel |
( |
const unsigned int & |
level | ) |
|
Set the nivel of log.
- Parameters
-
level | The nivel of log to be set. |
void delphos::CBCFractionalScheduler::SetNumThread |
( |
const unsigned int & |
nthreads | ) |
|
Set the number of threads used by CBC.
- Parameters
-
nthreads | The number of threads to be used by CBC. |
void delphos::CBCFractionalScheduler::SetOptimizationSense |
( |
const Model::OptimizationSense & |
sense | ) |
|
Set the sense of the optimization model.
- Parameters
-
sense | The sense of the optimization. The sense can be Model::OptimizationSense::MINIMIZATION or Model::OptimizationSense::MAXIMIZATION. |
void delphos::CBCFractionalScheduler::WriteLP |
( |
const string |
outfile | ) |
|
Writes the LP model in given file.
- Parameters
-
outfile | The name of the outfile in which the model is writen in LP format. Return true only if the model has been successfully writen in the LP format in given file. This method can only be used after the method InitSolver. |
The documentation for this class was generated from the following files:
- /home/gmorales/dev/MineLink/BlockScheduling/core/trunk/solvers/scheduling/fractional_scheduler/cbc_fractional_scheduler.h
- /home/gmorales/dev/MineLink/BlockScheduling/core/trunk/solvers/scheduling/fractional_scheduler/cbc_fractional_scheduler.cpp