Click or drag to resize

XPRBctr Class

Methods for initialisation and handling of XPRB constraint objects.
Inheritance Hierarchy
SystemObject
  BCLXPRBctr

Namespace: BCL
Assembly: xprbdn (in xprbdn.dll) Version: 47.01.01+0ba4e76731516b80760698bbaa939494dae84e49
Syntax
public class XPRBctr

The XPRBctr type exposes the following members.

Constructors
 NameDescription
Public methodXPRBctrInitializes a new instance of the XPRBctr class
Obsolete
Public methodXPRBctr(IntPtr)Initializes a new instance of the XPRBctr class
Obsolete
Public methodXPRBctr(XPRBprob)Initializes a new instance of the XPRBctr class
Public methodXPRBctr(IntPtr, XPRBprob)Initializes a new instance of the XPRBctr class
Public methodXPRBctr(IntPtr, XPRBrelation)Initializes a new instance of the XPRBctr class
Obsolete
Public methodXPRBctr(IntPtr, XPRBrelation, XPRBprob)Initializes a new instance of the XPRBctr class
Top
Properties
 NameDescription
Public propertysize The number of (non-zero) linear and quadratic terms in the constraint.
Top
Methods
 NameDescription
Public methodCode exampleadd This adds an XPRBexpr expression to the constraint.
Public methodaddTerm(Double) 
Public methodaddTerm(XPRBvar) 
Public methodaddTerm(Double, XPRBvar) 
Public methodCode exampleaddTerm(XPRBvar, Double) This adds a term to the XPRBctr constraint. The term can be constructed from an XPRBvar object, a double or a combination of the two.
Public methodaddTerm(XPRBvar, XPRBvar, Double) 
Public methodCode exampleassign Sets the constraint from a list of terms in an XPRBrelation.
Public methodCode exampledelTerm This deletes a term in the XPRBctr constraint relating to a specific XPRBvar variable.
Public methodEqualsDetermines whether the specified object is equal to the current object.
(Inherited from Object)
Protected methodFinalizeAllows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
(Inherited from Object)
Public methodCode examplegetAct Retrieves the activity value.
Public methodCode examplegetCoefficient(XPRBvar) Get the coefficient of a linear constraint term.
Public methodCode examplegetCoefficient(XPRBvar, XPRBvar) Get the coefficient of a quadratic constraint term. This method returns the coefficient of a given pair of variables in the constraint or 0 if the term does not occur.
Public methodCode examplegetCRef Return the constraint reference pointer.
Public methodCode examplegetctrRef Return the constraint reference pointer.
Public methodCode examplegetDual Retrieves the dual value.
Public methodGetHashCodeServes as the default hash function.
(Inherited from Object)
Public methodgetIndicator Get the indicator type of a constraint.
Public methodgetIndVar Get the indicator variable of a constraint.
Public methodCode examplegetName Returns the constraint name.
Public methodgetQTerms 
Public methodCode examplegetRange Retrieves the constraint range.
Public methodCode examplegetRangeL Retrieves the lower constraint range.
Public methodCode examplegetRangeU Retrieves the upper constraint range.
Public methodCode examplegetRHS Retrieves the right hand side value of a constraint.
Public methodCode examplegetRNG Compute (if required) ranges and return a row range.
Public methodCode examplegetRowNum Retrieves the row index for a constraint.
Public methodCode examplegetSlack Retrieves the slack value.
Public methodgetTerms 
Public methodCode examplegetType Retrieves the constraint type.
Public methodGetTypeGets the Type of the current instance.
(Inherited from Object)
Public methodisDelayed Determines whether the constraint is a delayed constraint.
Public methodCode exampleisIncludeVars Test the type of a constraint. This method indicates whether this constraint is an 'include vars' constraint or an ordinary constraint.
Public methodisIndicator This tests whether the constraint is an indicator constraint or an ordinary constraint.
Public methodCode exampleisModCut Gets the model cut status of a constraint.
Public methodCode exampleisValid Checks whether the constraint object is valid.
Protected methodMemberwiseCloneCreates a shallow copy of the current Object.
(Inherited from Object)
Public methodCode exampleprint Print out the constraint.
Public methodCode examplereset Reset the constraint object.
Public methodsetDelayed Sets a constraint as a delayed constraint.
Public methodCode examplesetIncludeVars Set the contstraint type. This method changes the type of a previously defined constraint from ordinary constraint to 'include vars' and vice versa. 'include vars' constraints are non-binding (type N) constraints used only to force loading of their variables into the optimizer. Constraint properties 'model cut', 'delayed constraint', 'indicator constraint' and 'include vars' are mutually exclusive. When changing one of this types to another you must first reset the corresponding type to 0.
Public methodsetIndicator(Int32) Set the indicator constraint type.
Public methodsetIndicator(Int32, XPRBvar) Set the indicator constraint type.
Public methodsetIndicator(XPRBvar, Int32) Set the indicator constraint type.
Public methodCode examplesetModCut Sets the model cut status of a constraint.
Public methodCode examplesetRange Sets the constraint range.
Public methodsetTerm(Double) 
Public methodsetTerm(XPRBvar) 
Public methodsetTerm(Double, XPRBvar) 
Public methodCode examplesetTerm(XPRBvar, Double) This sets a term in the XPRBctr constraint. The term can be constructed from an XPRBvar object, a double or a combination of the two.
Public methodCode examplesetType Sets the constraint type.
Public methodToString
(Overrides ObjectToString)
Top
Operators
 NameDescription
Public operatorStatic memberCode exampleAddition(XPRBctr, XPRBexpr) Add an XPRBexpr to a constraint.
Public operatorStatic memberCode exampleAddition(XPRBctr, XPRBterm) Add an XPRBterm to a constraint.
Public operatorStatic memberCode exampleAddition(XPRBctr, XPRBvar) Add an XPRBvar to a constraint.
Public operatorStatic memberCode exampleAddition(XPRBctr, Double) Add a double to a constraint.
Public operatorStatic memberCode exampleSubtraction(XPRBctr, XPRBexpr) Subtract an XPRBexpr from a constraint.
Public operatorStatic memberCode exampleSubtraction(XPRBctr, XPRBterm) Subtract an XPRBterm from a constraint.
Public operatorStatic memberCode exampleSubtraction(XPRBctr, XPRBvar) Subtract an XPRBvar from a constraint.
Public operatorStatic memberCode exampleSubtraction(XPRBctr, Double) Subtract a double from a constraint.
Top
Remarks
All terms in a constraint must belong to the same problem as the constraint itself.
See Also

Reference

BCL Namespace