public interface CpObjectiveProtoOrBuilder
extends com.google.protobuf.MessageOrBuilder
Modifier and Type | Method and Description |
---|---|
long |
getCoeffs(int index)
repeated int64 coeffs = 4; |
int |
getCoeffsCount()
repeated int64 coeffs = 4; |
java.util.List<java.lang.Long> |
getCoeffsList()
repeated int64 coeffs = 4; |
long |
getDomain(int index)
If non-empty, only look for an objective value in the given domain.
|
int |
getDomainCount()
If non-empty, only look for an objective value in the given domain.
|
java.util.List<java.lang.Long> |
getDomainList()
If non-empty, only look for an objective value in the given domain.
|
long |
getIntegerAfterOffset()
int64 integer_after_offset = 9; |
long |
getIntegerBeforeOffset()
Internal fields to recover a bound on the original integer objective from
the presolved one.
|
long |
getIntegerScalingFactor()
int64 integer_scaling_factor = 8; |
double |
getOffset()
The displayed objective is always:
scaling_factor * (sum(coefficients[i] * objective_vars[i]) + offset).
|
double |
getScalingFactor()
double scaling_factor = 3; |
boolean |
getScalingWasExact()
Internal field.
|
int |
getVars(int index)
The linear terms of the objective to minimize.
|
int |
getVarsCount()
The linear terms of the objective to minimize.
|
java.util.List<java.lang.Integer> |
getVarsList()
The linear terms of the objective to minimize.
|
findInitializationErrors, getAllFields, getDefaultInstanceForType, getDescriptorForType, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
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 scaling_factor to -1.
repeated int32 vars = 1;
int getVarsCount()
The linear terms of the objective to minimize. For a maximization problem, one can negate all coefficients in the objective and set scaling_factor to -1.
repeated int32 vars = 1;
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 scaling_factor to -1.
repeated int32 vars = 1;
index
- The index of the element to return.java.util.List<java.lang.Long> getCoeffsList()
repeated int64 coeffs = 4;
int getCoeffsCount()
repeated int64 coeffs = 4;
long getCoeffs(int index)
repeated int64 coeffs = 4;
index
- The index of the element to return.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;
double getScalingFactor()
double scaling_factor = 3;
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;
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;
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;
index
- The index of the element to return.boolean getScalingWasExact()
Internal field. Do not set. When we scale a FloatObjectiveProto to a integer version, we set this to true if the scaling was exact (i.e. all original coeff were integer for instance). TODO(user): Put the error bounds we computed instead?
bool scaling_was_exact = 6;
long getIntegerBeforeOffset()
Internal fields to recover a bound on the original integer objective from the presolved one. Basically, initially the integer objective fit on an int64 and is in [Initial_lb, Initial_ub]. During presolve, we might change the linear expression to have a new domain [Presolved_lb, Presolved_ub] that will also always fit on an int64. The two domain will always be linked with an affine transformation between the two of the form: old = (new + before_offset) * integer_scaling_factor + after_offset. Note that we use both offsets to always be able to do the computation while staying in the int64 domain. In particular, the after_offset will always be in (-integer_scaling_factor, integer_scaling_factor).
int64 integer_before_offset = 7;
long getIntegerAfterOffset()
int64 integer_after_offset = 9;
long getIntegerScalingFactor()
int64 integer_scaling_factor = 8;
Copyright © 2025. All rights reserved.