Purpose
Reads a
directives file to help direct the
global search.
Synopsis
int XPRS_CC XPRSreaddirs(XPRSprob prob, const char *filename);
READDIRS [filename]
Arguments
prob
|
The current problem.
|
filename
|
A string of up to 200 characters containing the file name from which the directives are to be read. If omitted (or NULL), the default problem_name is used with a .dir extension.
|
Related Controls
Double
|
Default pseudo cost in node degradation estimation.
|
Example 1 (Library)
The following example reads in directives from the file sue.dir for use with the problem, steve:
XPRSreadprob(prob,"steve","");
XPRSreaddirs(prob,"sue");
XPRSminim(prob,"g");
Example 2 (Console)
READPROB
READDIRS
MINIM -g
This is the most usual form at the console. It will attempt to read in a directives file with the current problem name and
an extension of .dir.
Further information
1. Directives cannot be read in after a model has been presolved, so unless
presolve has been disabled by setting
PRESOLVE to
0, this
command must be issued before
XPRSmaxim (
MAXIM) or
XPRSminim (
MINIM).
2. Directives can be given relating to
priorities, forced
branching directions,
pseudo
costs and
model cuts. There is a priority value associated with each
global entity. The
lower the number, the
more likely the entity is to be selected for
branching; the
higher, the
less likely. By default, all global entities have a
priority value of
500 which can be altered with a priority entry in the directives file.
In general, it is advantageous for the entity's priority to reflect its relative importance in the
model. Priority entries with values in excess of
1000 are illegal and are ignored. A full
description of the directives file format may be found in
The Directives (.dir) File.
3. By default,
XPRSglobal
(
GLOBAL) will explore the branch expected to yield the best integer
solution from each node, irrespective of whether this forces the global entity up or down. This can
be overridden with an
UP or
DN entry in the directives file, which forces
XPRSglobal (
GLOBAL) to branch up first or down first on the specified entity.
4. Pseudo-costs are estimates of the unit cost of forcing an entity up or down. By
default
XPRSglobal (
GLOBAL) uses dual information to calculate estimates of the
unit up and down costs and these are added to the default pseudo costs which are set to the
PSEUDOCOST control. The default pseudo costs can be overridden by a
PU or
PD entry in the directives file.
5. If model cuts are used, then the specified constraints are removed from the
matrix and added to the Optimizer cut pool, and only put back in the matrix when they are violated
by an LP solution at one of the nodes in the global search.
6. If creating a directives file by hand, wild cards can be used to specify several
vectors at once, for example PR x1* 2 will give all global entities whose names start with
x1 a priority of 2.
Related topics
If you have any comments or suggestions about these pages,
please send mail to docs@dashoptimization.com.