Java Reference
Java Reference
Detailed Description
Definition at line 6 of file CpObjectiveProtoOrBuilder.java.
Public Member Functions | |
| java.util.List< java.lang.Integer > | getVarsList () |
| int | getVarsCount () |
| int | getVars (int index) |
| java.util.List< java.lang.Long > | getCoeffsList () |
repeated int64 coeffs = 4; More... | |
| int | getCoeffsCount () |
repeated int64 coeffs = 4; More... | |
| long | getCoeffs (int index) |
repeated int64 coeffs = 4; More... | |
| double | getOffset () |
| double | getScalingFactor () |
double scaling_factor = 3; More... | |
| java.util.List< java.lang.Long > | getDomainList () |
| int | getDomainCount () |
| long | getDomain (int index) |
Member Function Documentation
◆ getCoeffs()
| long getCoeffs | ( | int | index | ) |
repeated int64 coeffs = 4;
- Parameters
-
index The index of the element to return.
- Returns
- The coeffs at the given index.
Implemented in CpObjectiveProto.Builder, and CpObjectiveProto.
◆ getCoeffsCount()
| int getCoeffsCount | ( | ) |
repeated int64 coeffs = 4;
- Returns
- The count of coeffs.
Implemented in CpObjectiveProto.Builder, and CpObjectiveProto.
◆ getCoeffsList()
| java.util.List<java.lang.Long> getCoeffsList | ( | ) |
repeated int64 coeffs = 4;
- Returns
- A list containing the coeffs.
Implemented in CpObjectiveProto.Builder, and CpObjectiveProto.
◆ getDomain()
| long getDomain | ( | int | index | ) |
If non-empty, only look for an objective value in the given domain. Note that this does not depend on the offset or scaling factor, it is a domain on the sum of the objective terms only.
repeated int64 domain = 5;
- Parameters
-
index The index of the element to return.
- Returns
- The domain at the given index.
Implemented in CpObjectiveProto.Builder, and CpObjectiveProto.
◆ getDomainCount()
| int getDomainCount | ( | ) |
If non-empty, only look for an objective value in the given domain. Note that this does not depend on the offset or scaling factor, it is a domain on the sum of the objective terms only.
repeated int64 domain = 5;
- Returns
- The count of domain.
Implemented in CpObjectiveProto.Builder, and CpObjectiveProto.
◆ getDomainList()
| java.util.List<java.lang.Long> getDomainList | ( | ) |
If non-empty, only look for an objective value in the given domain. Note that this does not depend on the offset or scaling factor, it is a domain on the sum of the objective terms only.
repeated int64 domain = 5;
- Returns
- A list containing the domain.
Implemented in CpObjectiveProto.Builder, and CpObjectiveProto.
◆ getOffset()
| double getOffset | ( | ) |
The displayed objective is always: scaling_factor * (sum(coefficients[i] * objective_vars[i]) + offset). This is needed to have a consistent objective after presolve or when scaling a double problem to express it with integers. Note that if scaling_factor is zero, then it is assumed to be 1, so that by default these fields have no effect.
double offset = 2;
- Returns
- The offset.
Implemented in CpObjectiveProto.Builder, and CpObjectiveProto.
◆ getScalingFactor()
| double getScalingFactor | ( | ) |
double scaling_factor = 3;
- Returns
- The scalingFactor.
Implemented in CpObjectiveProto.Builder, and CpObjectiveProto.
◆ getVars()
| int getVars | ( | int | index | ) |
The linear terms of the objective to minimize. For a maximization problem, one can negate all coefficients in the objective and set a scaling_factor to -1.
repeated int32 vars = 1;
- Parameters
-
index The index of the element to return.
- Returns
- The vars at the given index.
Implemented in CpObjectiveProto.Builder, and CpObjectiveProto.
◆ getVarsCount()
| int getVarsCount | ( | ) |
The linear terms of the objective to minimize. For a maximization problem, one can negate all coefficients in the objective and set a scaling_factor to -1.
repeated int32 vars = 1;
- Returns
- The count of vars.
Implemented in CpObjectiveProto.Builder, and CpObjectiveProto.
◆ getVarsList()
| java.util.List<java.lang.Integer> getVarsList | ( | ) |
The linear terms of the objective to minimize. For a maximization problem, one can negate all coefficients in the objective and set a scaling_factor to -1.
repeated int32 vars = 1;
- Returns
- A list containing the vars.
Implemented in CpObjectiveProto.Builder, and CpObjectiveProto.
The documentation for this interface was generated from the following file: