Java Reference
Java Reference
Detailed Description
Quadratic part of a model's objective. Added with other objectives (such as linear), this creates the model's objective function to be optimized. Note: the linear part of the objective currently needs to be specified in the MPVariableProto.objective_coefficient fields. If you'd rather have a dedicated linear array here, talk to or-core-team@
Protobuf type
Definition at line 17 of file MPQuadraticObjective.java.
Classes | |
| class | Builder |
Public Member Functions | |
| .lang.Override final com.google.protobuf.UnknownFieldSet | getUnknownFields () |
| .lang.Override java.util.List< java.lang.Integer > | getQvar1IndexList () |
| int | getQvar1IndexCount () |
| int | getQvar1Index (int index) |
| .lang.Override java.util.List< java.lang.Integer > | getQvar2IndexList () |
repeated int32 qvar2_index = 2; More... | |
| int | getQvar2IndexCount () |
repeated int32 qvar2_index = 2; More... | |
| int | getQvar2Index (int index) |
repeated int32 qvar2_index = 2; More... | |
| .lang.Override java.util.List< java.lang.Double > | getCoefficientList () |
| int | getCoefficientCount () |
| double | getCoefficient (int index) |
| .lang.Override final boolean | isInitialized () |
| .lang.Override void | writeTo (com.google.protobuf.CodedOutputStream output) throws java.io.IOException |
| .lang.Override int | getSerializedSize () |
| .lang.Override boolean | equals (final java.lang.Object obj) |
| .lang.Override int | hashCode () |
| .lang.Override Builder | newBuilderForType () |
| .lang.Override Builder | toBuilder () |
| .lang.Override com.google.protobuf.Parser< MPQuadraticObjective > | getParserForType () |
| .lang.Override com.google.ortools.linearsolver.MPQuadraticObjective | getDefaultInstanceForType () |
Static Public Member Functions | |
| static final com.google.protobuf.Descriptors.Descriptor | getDescriptor () |
| static com.google.ortools.linearsolver.MPQuadraticObjective | parseFrom (java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException |
| static com.google.ortools.linearsolver.MPQuadraticObjective | parseFrom (java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException |
| static com.google.ortools.linearsolver.MPQuadraticObjective | parseFrom (com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException |
| static com.google.ortools.linearsolver.MPQuadraticObjective | parseFrom (com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException |
| static com.google.ortools.linearsolver.MPQuadraticObjective | parseFrom (byte[] data) throws com.google.protobuf.InvalidProtocolBufferException |
| static com.google.ortools.linearsolver.MPQuadraticObjective | parseFrom (byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException |
| static com.google.ortools.linearsolver.MPQuadraticObjective | parseFrom (java.io.InputStream input) throws java.io.IOException |
| static com.google.ortools.linearsolver.MPQuadraticObjective | parseFrom (java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException |
| static com.google.ortools.linearsolver.MPQuadraticObjective | parseDelimitedFrom (java.io.InputStream input) throws java.io.IOException |
| static com.google.ortools.linearsolver.MPQuadraticObjective | parseDelimitedFrom (java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException |
| static com.google.ortools.linearsolver.MPQuadraticObjective | parseFrom (com.google.protobuf.CodedInputStream input) throws java.io.IOException |
| static com.google.ortools.linearsolver.MPQuadraticObjective | parseFrom (com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException |
| static Builder | newBuilder () |
| static Builder | newBuilder (com.google.ortools.linearsolver.MPQuadraticObjective prototype) |
| static com.google.ortools.linearsolver.MPQuadraticObjective | getDefaultInstance () |
| static com.google.protobuf.Parser< MPQuadraticObjective > | parser () |
Static Public Attributes | |
| static final int | QVAR1_INDEX_FIELD_NUMBER = 1 |
| static final int | QVAR2_INDEX_FIELD_NUMBER = 2 |
| static final int | COEFFICIENT_FIELD_NUMBER = 3 |
| .lang.Deprecated static final com.google.protobuf.Parser< MPQuadraticObjective > | PARSER |
Protected Member Functions | |
| .lang.Override java.lang.Object | newInstance (UnusedPrivateParameter unused) |
| .lang.Override com.google.protobuf.GeneratedMessageV3.FieldAccessorTable | internalGetFieldAccessorTable () |
| .lang.Override Builder | newBuilderForType (com.google.protobuf.GeneratedMessageV3.BuilderParent parent) |
Member Function Documentation
◆ equals()
|
inline |
Definition at line 352 of file MPQuadraticObjective.java.
◆ getCoefficient()
|
inline |
Must be finite.
repeated double coefficient = 3;
- Parameters
-
index The index of the element to return.
- Returns
- The coefficient at the given index.
Implements MPQuadraticObjectiveOrBuilder.
Definition at line 286 of file MPQuadraticObjective.java.
◆ getCoefficientCount()
|
inline |
Must be finite.
repeated double coefficient = 3;
- Returns
- The count of coefficient.
Implements MPQuadraticObjectiveOrBuilder.
Definition at line 274 of file MPQuadraticObjective.java.
◆ getCoefficientList()
|
inline |
Must be finite.
repeated double coefficient = 3;
- Returns
- A list containing the coefficient.
Implements MPQuadraticObjectiveOrBuilder.
Definition at line 263 of file MPQuadraticObjective.java.
◆ getDefaultInstance()
|
inlinestatic |
Definition at line 1043 of file MPQuadraticObjective.java.
◆ getDefaultInstanceForType()
|
inline |
Definition at line 1068 of file MPQuadraticObjective.java.
◆ getDescriptor()
|
inlinestatic |
Definition at line 155 of file MPQuadraticObjective.java.
◆ getParserForType()
|
inline |
Definition at line 1063 of file MPQuadraticObjective.java.
◆ getQvar1Index()
|
inline |
Sparse representation of quadratic terms in the objective function, where term i is qvar1_index[i] * qvar2_index[i] * coefficient[i]. `qvar1_index` and `qvar2_index` are variable indices w.r.t the "variable" field in MPModelProto. `qvar1_index`, `qvar2_index` and `coefficients` must have the same size. If the same unordered pair (qvar1_index, qvar2_index) appears several times, the sum of all of the associated coefficients will be applied.
repeated int32 qvar1_index = 1;
- Parameters
-
index The index of the element to return.
- Returns
- The qvar1Index at the given index.
Implements MPQuadraticObjectiveOrBuilder.
Definition at line 220 of file MPQuadraticObjective.java.
◆ getQvar1IndexCount()
|
inline |
Sparse representation of quadratic terms in the objective function, where term i is qvar1_index[i] * qvar2_index[i] * coefficient[i]. `qvar1_index` and `qvar2_index` are variable indices w.r.t the "variable" field in MPModelProto. `qvar1_index`, `qvar2_index` and `coefficients` must have the same size. If the same unordered pair (qvar1_index, qvar2_index) appears several times, the sum of all of the associated coefficients will be applied.
repeated int32 qvar1_index = 1;
- Returns
- The count of qvar1Index.
Implements MPQuadraticObjectiveOrBuilder.
Definition at line 202 of file MPQuadraticObjective.java.
◆ getQvar1IndexList()
|
inline |
Sparse representation of quadratic terms in the objective function, where term i is qvar1_index[i] * qvar2_index[i] * coefficient[i]. `qvar1_index` and `qvar2_index` are variable indices w.r.t the "variable" field in MPModelProto. `qvar1_index`, `qvar2_index` and `coefficients` must have the same size. If the same unordered pair (qvar1_index, qvar2_index) appears several times, the sum of all of the associated coefficients will be applied.
repeated int32 qvar1_index = 1;
- Returns
- A list containing the qvar1Index.
Implements MPQuadraticObjectiveOrBuilder.
Definition at line 185 of file MPQuadraticObjective.java.
◆ getQvar2Index()
|
inline |
repeated int32 qvar2_index = 2;
- Parameters
-
index The index of the element to return.
- Returns
- The qvar2Index at the given index.
Implements MPQuadraticObjectiveOrBuilder.
Definition at line 247 of file MPQuadraticObjective.java.
◆ getQvar2IndexCount()
|
inline |
repeated int32 qvar2_index = 2;
- Returns
- The count of qvar2Index.
Implements MPQuadraticObjectiveOrBuilder.
Definition at line 239 of file MPQuadraticObjective.java.
◆ getQvar2IndexList()
|
inline |
repeated int32 qvar2_index = 2;
- Returns
- A list containing the qvar2Index.
Implements MPQuadraticObjectiveOrBuilder.
Definition at line 232 of file MPQuadraticObjective.java.
◆ getSerializedSize()
|
inline |
Definition at line 317 of file MPQuadraticObjective.java.
◆ getUnknownFields()
|
inline |
Definition at line 41 of file MPQuadraticObjective.java.
◆ hashCode()
|
inline |
Definition at line 372 of file MPQuadraticObjective.java.
◆ internalGetFieldAccessorTable()
|
inlineprotected |
Definition at line 161 of file MPQuadraticObjective.java.
◆ isInitialized()
|
inline |
Definition at line 292 of file MPQuadraticObjective.java.
◆ newBuilder() [1/2]
|
inlinestatic |
Definition at line 467 of file MPQuadraticObjective.java.
◆ newBuilder() [2/2]
|
inlinestatic |
Definition at line 470 of file MPQuadraticObjective.java.
◆ newBuilderForType() [1/2]
|
inline |
Definition at line 466 of file MPQuadraticObjective.java.
◆ newBuilderForType() [2/2]
|
inlineprotected |
Definition at line 480 of file MPQuadraticObjective.java.
◆ newInstance()
|
inlineprotected |
Definition at line 34 of file MPQuadraticObjective.java.
◆ parseDelimitedFrom() [1/2]
|
inlinestatic |
Definition at line 439 of file MPQuadraticObjective.java.
◆ parseDelimitedFrom() [2/2]
|
inlinestatic |
Definition at line 444 of file MPQuadraticObjective.java.
◆ parseFrom() [1/10]
|
inlinestatic |
Definition at line 417 of file MPQuadraticObjective.java.
◆ parseFrom() [2/10]
|
inlinestatic |
Definition at line 421 of file MPQuadraticObjective.java.
◆ parseFrom() [3/10]
|
inlinestatic |
Definition at line 406 of file MPQuadraticObjective.java.
◆ parseFrom() [4/10]
|
inlinestatic |
Definition at line 411 of file MPQuadraticObjective.java.
◆ parseFrom() [5/10]
|
inlinestatic |
Definition at line 451 of file MPQuadraticObjective.java.
◆ parseFrom() [6/10]
|
inlinestatic |
Definition at line 457 of file MPQuadraticObjective.java.
◆ parseFrom() [7/10]
|
inlinestatic |
Definition at line 427 of file MPQuadraticObjective.java.
◆ parseFrom() [8/10]
|
inlinestatic |
Definition at line 432 of file MPQuadraticObjective.java.
◆ parseFrom() [9/10]
|
inlinestatic |
Definition at line 395 of file MPQuadraticObjective.java.
◆ parseFrom() [10/10]
|
inlinestatic |
Definition at line 400 of file MPQuadraticObjective.java.
◆ parser()
|
inlinestatic |
Definition at line 1058 of file MPQuadraticObjective.java.
◆ toBuilder()
|
inline |
Definition at line 474 of file MPQuadraticObjective.java.
◆ writeTo()
|
inline |
Definition at line 302 of file MPQuadraticObjective.java.
Member Data Documentation
◆ COEFFICIENT_FIELD_NUMBER
|
static |
Definition at line 251 of file MPQuadraticObjective.java.
◆ PARSER
|
static |
Definition at line 1048 of file MPQuadraticObjective.java.
◆ QVAR1_INDEX_FIELD_NUMBER
|
static |
Definition at line 167 of file MPQuadraticObjective.java.
◆ QVAR2_INDEX_FIELD_NUMBER
|
static |
Definition at line 224 of file MPQuadraticObjective.java.
The documentation for this class was generated from the following file: