Solving Constraint Integer Programs

cons_lop.h File Reference

Detailed Description

constraint handler for linear ordering constraints

Marc Pfetsch

This constraint ensures that a given square matrix of binary variables corresponds to a tournament, i.e., it is an acyclic orientation of the complete graph. This encodes a linear order as follows. The rows and columns correspond to the elements of the set to be ordered. A variable x[i][j] is 1 if and only if element i appears before j in the order.

In this constraint handler we only add the symmetry equations and separate the triangle inequalities yielding a correct IP model.

The variables on the diagonal are ignored.

Definition in file cons_lop.h.

#include <scip/scip.h>

Go to the source code of this file.


SCIP_RETCODE SCIPincludeConshdlrLOP (SCIP *scip)
SCIP_RETCODE SCIPcreateConsLOP (SCIP *scip, SCIP_CONS **cons, const char *name, int n, SCIP_VAR ***vars, SCIP_Bool initial, SCIP_Bool separate, SCIP_Bool enforce, SCIP_Bool check, SCIP_Bool propagate, SCIP_Bool local, SCIP_Bool modifiable, SCIP_Bool dynamic, SCIP_Bool removable, SCIP_Bool stickingatnode)

Function Documentation

◆ SCIPincludeConshdlrLOP()

◆ SCIPcreateConsLOP()

SCIP_CONS **  cons,
const char *  name,
int  n,
SCIP_VAR ***  vars,
SCIP_Bool  initial,
SCIP_Bool  separate,
SCIP_Bool  enforce,
SCIP_Bool  check,
SCIP_Bool  propagate,
SCIP_Bool  local,
SCIP_Bool  modifiable,
SCIP_Bool  dynamic,
SCIP_Bool  removable,
SCIP_Bool  stickingatnode 

creates and captures a linear ordering constraint

scipSCIP data structure
conspointer to hold the created constraint
namename of constraint
nnumber of elements
varsn x n matrix of binary variables
initialshould the LP relaxation of constraint be in the initial LP?
separateshould the constraint be separated during LP processing?
enforceshould the constraint be enforced during node processing?
checkshould the constraint be checked for feasibility?
propagateshould the constraint be propagated during node processing?
localis constraint only valid locally?
modifiableis constraint modifiable (subject to column generation)?
dynamicis constraint subject to aging?
removableshould the relaxation be removed from the LP due to aging or cleanup?
stickingatnodeshould the constraint always be kept at the node where it was added, even if it may be moved to a more global node?

Definition at line 1205 of file cons_lop.c.

References CONSHDLR_NAME, NULL, SCIP_CALL, SCIP_OKAY, SCIP_PLUGINNOTFOUND, SCIPallocBlockMemory, SCIPallocBlockMemoryArray, SCIPcreateCons(), SCIPerrorMessage, and SCIPfindConshdlr().

Referenced by SCIP_DECL_CONSCOPY(), SCIP_DECL_READERREAD(), and SCIPincludeConshdlrLOP().