public abstract class LinearConstraints extends Object implements Constraints
Constructor and Description |
---|
LinearConstraints(Matrix A,
Vector b)
Construct a collection of linear constraints.
|
Modifier and Type | Method and Description |
---|---|
ImmutableMatrix |
A()
Get the constraint coefficients.
|
ImmutableVector |
b()
Get the constraint values.
|
static LinearConstraints |
concat(LinearConstraints... groups)
Concatenate collections of linear constraints into one collection.
|
int |
dimension()
Get the number of variables.
|
Matrix |
getActiveConstraints(Vector x,
double epsilon)
Get the active constraint.
|
ArrayList<Integer> |
getActiveRows(Vector x,
double epsilon)
Get the active constraint indices.
|
List<RealScalarFunction> |
getConstraints()
Get the list of constraint functions.
|
int |
size()
Get the number of constraints.
|
String |
toString() |
public List<RealScalarFunction> getConstraints()
Constraints
getConstraints
in interface Constraints
public int dimension()
Constraints
dimension
in interface Constraints
public int size()
Constraints
size
in interface Constraints
public ImmutableMatrix A()
public ImmutableVector b()
public ArrayList<Integer> getActiveRows(Vector x, double epsilon)
x
- a point or a potential solutionepsilon
- a precision parameter: when a number |x| ≤ ε, it is considered 0public Matrix getActiveConstraints(Vector x, double epsilon)
x
- a point or a potential solutionepsilon
- a precision parameter: when a number |x| ≤ ε, it is considered 0public static LinearConstraints concat(LinearConstraints... groups)
groups
- collections of linear constraintsCopyright © 2010-2020 NM FinTech Ltd.. All Rights Reserved.