Click or drag to resize

XPRBctradd Method

This adds an XPRBexpr expression to the constraint.

Namespace: BCL
Assembly: xprbdn (in xprbdn.dll) Version: 47.01.01+0ba4e76731516b80760698bbaa939494dae84e49
Syntax
public void add(
	XPRBexpr l
)

Parameters

l  XPRBexpr
The XPRBexpr object to add to the constraint.
Example
C#
XPRBprob prob = new XPRBprob("NewProb");
XPRBvar x;
XPRBvar y;
x = prob.newVar("x");
y = prob.newVar("y");
XPRBctr ctr = prob.newCtr("Constraint1", 5.0 * x + 20.0 * y);
...
XPRBvar a, b;
a = prob.newVar("a");
b = prob.newVar("b");
ctr.add(2.3*a - 4.8*b);
See Also