Click or drag to resize
Accord.NET (logo)

QuadraticConstraint Constructor

Constructs a new quadratic constraint in the form x'Ax + x'b.

Namespace:  Accord.Math.Optimization
Assembly:  Accord.Math (in Accord.Math.dll) Version: 3.8.0
Syntax
public QuadraticConstraint(
	IObjectiveFunction objective,
	double[,] quadraticTerms,
	double[] linearTerms = null,
	ConstraintType shouldBe = ConstraintType.LesserThanOrEqualTo,
	double value = 0,
	double withinTolerance = 0
)
Request Example View Source

Parameters

objective
Type: Accord.Math.OptimizationIObjectiveFunction
The objective function to which this constraint refers.
quadraticTerms
Type: SystemDouble
The matrix of A quadratic terms.
linearTerms (Optional)
Type: SystemDouble
The vector b of linear terms.
shouldBe (Optional)
Type: Accord.Math.OptimizationConstraintType
How the left hand side of the constraint should be compared to the given value.
value (Optional)
Type: SystemDouble
The right hand side of the constraint equation.
withinTolerance (Optional)
Type: SystemDouble
The tolerance for violations of the constraint. Equality constraints should set this to a small positive value. Default is 0.
See Also