Detailed Description
relaxation based column selection primal heuristic
Definition in file heur_relaxcolsel.c.
#include <assert.h>#include "gcg/heur_relaxcolsel.h"#include "gcg/gcg.h"#include "gcg/pricer_gcg.h"Go to the source code of this file.
Data Structures | |
| struct | SCIP_HeurData |
Macros | |
| #define | HEUR_NAME "relaxcolsel" |
| #define | HEUR_DESC "column selection heuristic that tries to round a master LP solution in promising directions" |
| #define | HEUR_DISPCHAR 'x' |
| #define | HEUR_PRIORITY -100 |
| #define | HEUR_FREQ 1 |
| #define | HEUR_FREQOFS 0 |
| #define | HEUR_MAXDEPTH -1 |
| #define | HEUR_TIMING SCIP_HEURTIMING_AFTERLPNODE |
| #define | HEUR_USESSUBSCIP FALSE |
| #define | DEFAULT_MINCOLUMNS 200 |
| #define | heurCopyRelaxcolsel NULL |
| #define | heurInitsolRelaxcolsel NULL |
| #define | heurExitsolRelaxcolsel NULL |
Functions | |
| static SCIP_RETCODE | initializeStartsol (GCG *gcg, SCIP_SOL *mastersol, SCIP_SOL *origsol, int *blocknr, int *mastercands, SCIP_Real *candfracs, int *nmastercands, SCIP_Bool *success) |
| static SCIP_RETCODE | searchZeroMastervar (SCIP *scip, int block, SCIP_VAR **zeromastervar) |
| static SCIP_RETCODE | getZeroMastervar (SCIP *scip, SCIP_HEURDATA *heurdata, int block, SCIP_VAR **zeromastervar) |
| static | SCIP_DECL_HEURFREE (heurFreeRelaxcolsel) |
| static | SCIP_DECL_HEURINIT (heurInitRelaxcolsel) |
| static | SCIP_DECL_HEUREXIT (heurExitRelaxcolsel) |
| static | SCIP_DECL_HEUREXEC (heurExecRelaxcolsel) |
| SCIP_RETCODE | GCGincludeHeurRelaxcolsel (GCG *gcg) |
Macro Definition Documentation
◆ HEUR_NAME
| #define HEUR_NAME "relaxcolsel" |
Definition at line 43 of file heur_relaxcolsel.c.
◆ HEUR_DESC
| #define HEUR_DESC "column selection heuristic that tries to round a master LP solution in promising directions" |
Definition at line 44 of file heur_relaxcolsel.c.
◆ HEUR_DISPCHAR
| #define HEUR_DISPCHAR 'x' |
Definition at line 45 of file heur_relaxcolsel.c.
◆ HEUR_PRIORITY
| #define HEUR_PRIORITY -100 |
Definition at line 46 of file heur_relaxcolsel.c.
◆ HEUR_FREQ
| #define HEUR_FREQ 1 |
Definition at line 47 of file heur_relaxcolsel.c.
◆ HEUR_FREQOFS
| #define HEUR_FREQOFS 0 |
Definition at line 48 of file heur_relaxcolsel.c.
◆ HEUR_MAXDEPTH
| #define HEUR_MAXDEPTH -1 |
Definition at line 49 of file heur_relaxcolsel.c.
◆ HEUR_TIMING
| #define HEUR_TIMING SCIP_HEURTIMING_AFTERLPNODE |
Definition at line 50 of file heur_relaxcolsel.c.
◆ HEUR_USESSUBSCIP
| #define HEUR_USESSUBSCIP FALSE |
Definition at line 51 of file heur_relaxcolsel.c.
◆ DEFAULT_MINCOLUMNS
| #define DEFAULT_MINCOLUMNS 200 |
minimum number of columns to regard in the master problem
Definition at line 53 of file heur_relaxcolsel.c.
◆ heurCopyRelaxcolsel
| #define heurCopyRelaxcolsel NULL |
copy method for primal heuristic plugins (called when SCIP copies plugins)
Definition at line 455 of file heur_relaxcolsel.c.
Referenced by GCGincludeHeurRelaxcolsel().
◆ heurInitsolRelaxcolsel
| #define heurInitsolRelaxcolsel NULL |
solving process initialization method of primal heuristic (called when branch and bound process is about to begin)
Definition at line 534 of file heur_relaxcolsel.c.
Referenced by GCGincludeHeurRelaxcolsel().
◆ heurExitsolRelaxcolsel
| #define heurExitsolRelaxcolsel NULL |
solving process deinitialization method of primal heuristic (called before branch and bound process data is freed)
Definition at line 538 of file heur_relaxcolsel.c.
Referenced by GCGincludeHeurRelaxcolsel().
Function Documentation
◆ initializeStartsol()
|
static |
initialize working solution as the rounded down master LP solution (and its original counterpart) and the master variable candidates for rounding up
Definition at line 88 of file heur_relaxcolsel.c.
References assert(), frac, GCGgetMasterprob(), GCGgetNPricingprobs(), GCGgetOrigprob(), GCGlinkingVarGetPricingVars(), GCGmasterVarGetNOrigvars(), GCGmasterVarGetOrigvals(), GCGmasterVarGetOrigvars(), GCGmasterVarIsArtificial(), GCGmasterVarIsRay(), GCGoriginalVarGetMastervars(), GCGoriginalVarGetPricingVar(), GCGoriginalVarIsLinking(), GCGpricingVarGetNOrigvars(), GCGpricingVarGetOrigvars(), GCGvarGetBlock(), GCGvarIsMaster(), GCGvarIsOriginal(), GCGvarIsPricing(), i, initializeStartsol(), j, masterprob, mastervars, nmastervars, origprob, SCIP_CALL(), SCIPdebugMessage(), SCIPfreeBufferArray(), solval, and success.
Referenced by initializeStartsol(), and SCIP_DECL_HEUREXEC().
◆ searchZeroMastervar()
|
static |
for a given block, search if there is a master variable corresponding to the zero solution;
Definition at line 378 of file heur_relaxcolsel.c.
References GCGmasterVarGetNOrigvars(), GCGmasterVarGetOrigvals(), GCGvarGetBlock(), i, j, mastervars, nmastervars, SCIP_CALL(), and searchZeroMastervar().
◆ getZeroMastervar()
|
static |
for a given block, return the master variable corresponding to the zero solution, or NULL is there is no such variable available
Definition at line 430 of file heur_relaxcolsel.c.
References getZeroMastervar(), heurdata, SCIP_CALL(), searchZeroMastervar(), and SCIP_HeurData::zerovars.
◆ SCIP_DECL_HEURFREE()
|
static |
destructor of primal heuristic to free user data (called when SCIP is exiting)
Definition at line 459 of file heur_relaxcolsel.c.
References assert(), heurdata, and SCIPfreeMemory().
◆ SCIP_DECL_HEURINIT()
|
static |
initialization method of primal heuristic (called after problem was transformed)
Definition at line 480 of file heur_relaxcolsel.c.
References assert(), SCIP_HeurData::gcg, GCGgetNPricingprobs(), heurdata, i, SCIP_HeurData::lastncols, SCIP_HeurData::maxzerovars, SCIP_CALL(), and SCIP_HeurData::zerovars.
◆ SCIP_DECL_HEUREXIT()
|
static |
deinitialization method of primal heuristic (called before transformed problem is freed)
Definition at line 515 of file heur_relaxcolsel.c.
References assert(), heurdata, SCIP_HeurData::maxzerovars, and SCIP_HeurData::zerovars.
◆ SCIP_DECL_HEUREXEC()
|
static |
execution method of primal heuristic
Definition at line 543 of file heur_relaxcolsel.c.
References assert(), frac, SCIP_HeurData::gcg, GCGgetNIdenticalBlocks(), GCGgetNPricingprobs(), GCGgetOrigprob(), GCGlinkingVarGetPricingVars(), GCGmasterVarGetNOrigvars(), GCGmasterVarGetOrigvals(), GCGmasterVarGetOrigvars(), GCGoriginalVarGetMastervars(), GCGoriginalVarGetPricingVar(), GCGoriginalVarIsLinking(), GCGpricingVarGetNOrigvars(), GCGpricingVarGetOrigvars(), GCGvarGetBlock(), GCGvarIsOriginal(), GCGvarIsPricing(), getZeroMastervar(), heurdata, i, initializeStartsol(), j, SCIP_HeurData::lastncols, mastervars, SCIP_HeurData::mincolumns, nmastervars, origprob, result, SCIP_CALL(), SCIPdebugMessage(), SCIPfreeBufferArray(), and success.
◆ GCGincludeHeurRelaxcolsel()
| SCIP_RETCODE GCGincludeHeurRelaxcolsel | ( | GCG * | gcg | ) |
creates the relaxation based column selection primal heuristic and includes it in SCIP
- Parameters
-
gcg GCG data structure
Definition at line 970 of file heur_relaxcolsel.c.
References DEFAULT_MINCOLUMNS, SCIP_HeurData::gcg, GCGgetMasterprob(), GCGincludeHeurRelaxcolsel(), HEUR_DESC, HEUR_DISPCHAR, HEUR_FREQ, HEUR_FREQOFS, HEUR_MAXDEPTH, HEUR_NAME, HEUR_PRIORITY, HEUR_TIMING, HEUR_USESSUBSCIP, heurCopyRelaxcolsel, heurdata, heurExitsolRelaxcolsel, heurInitsolRelaxcolsel, masterprob, SCIP_HeurData::maxzerovars, SCIP_HeurData::mincolumns, SCIP_CALL(), and SCIP_HeurData::zerovars.
Referenced by GCGincludeHeurRelaxcolsel(), and GCGincludeMasterPlugins().