VarUnaryNegation Operator

Negates the variable, returns the term where the coefficient is one.
C#
Set i = ...;
VarD1 x = ...;
Assert.Equal(-x[i], (-1) * x[i]);

Definition

Namespace: Orx.MathProg
Assembly: Orx.MathProg (in Orx.MathProg.dll) Version: 1.0.0
C#
public static Term operator -(
	Var variable
)

Parameters

variable  Var
Variable to negate.

Return Value

Term

See Also