problem.getindicators
problem.getindicators |
Purpose
Returns the indicator constraint condition (indicator variable and complement flag) associated to the rows in a given range.
Synopsis
problem.getindicators (inds, comps, first, last)
Arguments
inds
|
Array of length
last-first+1 where the column indices of the indicator variables are to be placed.
|
||||||
comps
|
Array of length
last-first+1 where the indicator complement flags will be returned:
|
||||||
first
|
First row in the range.
|
||||||
last
|
Last row in the range (inclusive).
|
Example
The following example retrieves information about three indicator constraints in the problem and prints a list of their indices.
inds = [] comps = [] p.getindicators (inds, comps, 2, 4) print ("indices:", inds) print ("complement flags:", comps)
Related topics