Parameters

Parameters control the operation of the Cardinal Optimizer. They can be modified before the optimization begins. Each parameter has its own default value and value range. Before starting the solution, user can set the parameters to different values, so as to put forward specific requirements on the solution algorithm and solution process. Of course, the default settings can also be maintained.

According to the task performed by the solver COPT and the optimization problem solved, it can be divided into different types of parameters.

This chapter will introduce the parameters constants provided by COPT and their meanings.

Limits and tolerances

Table 16 Limits and tolerances parameters

Name

Type

Description

TimeLimit

Double

Time limit of the optimization

SolTimeLimit

Double

Time limit if a primal feasible solution has been found

NodeLimit

Integer

Node limit of the optimization

BarIterLimit

Integer

Iteration limit of barrier method

MatrixTol

Double

Input matrix coefficient tolerance

FeasTol

Double

The feasibility tolerance

DualTol

Double

The tolerance for dual solutions and reduced cost

IntTol

Double

The integrality tolerance for variables

RelGap

Double

The relative gap of optimization

AbsGap

Double

The absolute gap of optimization

  • TimeLimit

    Double parameter.

    Time limit of the optimization.

    Default: 1e20

    Minimal: 0

    Maximal: 1e20

  • SolTimeLimit

    Double parameter.

    Time limit if a primal feasible solution has been found.

    Default: 1e20

    Minimal: 0

    Maximal: 1e20

  • NodeLimit

    Integer parameter.

    Node limit of the optimization.

    Default: -1 (Choose automatically)

    Minimal: -1 (Choose automatically)

    Maximal: INT_MAX

  • BarIterLimit

    Integer parameter.

    Iteration limit of barrier method.

    Default: 500

    Minimal: 0

    Maximal: INT_MAX

  • MatrixTol

    Double parameter.

    Input matrix coefficient tolerance.

    Default: 1e-10

    Minimal: 0

    Maximal: 1e-7

  • FeasTol

    Double parameter.

    The feasibility tolerance.

    Default: 1e-6

    Minimal: 1e-9.

    Maximal: 1e-4

  • DualTol

    Double parameter.

    The tolerance for dual solutions and reduced cost.

    Default: 1e-6

    Minimal: 1e-9

    Maximal: 1e-4

  • IntTol

    Double parameter.

    The integrality tolerance for variables.

    Default: 1e-6

    Minimal: 1e-9

    Maximal: 1e-1

  • RelGap

    Double parameter.

    The relative gap of optimization.

    Default: 1e-4

    Minimal: 0

    Maximal: DBL_MAX

  • AbsGap

    Double parameter.

    The absolute gap of optimization.

    Default: 1e-6

    Minimal: 0

    Maximal: DBL_MAX

Presolving and scaling

Table 17 Presolving and scaling parameters

Name

Type

Description

Presolve

Integer

Level of presolving before solving a model

Scaling

Integer

Whether to perform scaling before solving a problem

Dualize

Integer

Whether to dualize a problem before solving it

  • Presolve

    Integer parameter.

    Level of presolving before solving a model.

    Default: -1

    Possible values:

    -1: Choose automatically.

    0: Off.

    1: Fast.

    2: Normal.

    3: Aggressive.

    4: No Limitations, continues until the model cannot be modified (may be very time-consuming).

  • Scaling

    Integer parameter.

    Whether to perform scaling before solving a problem.

    Default: -1

    Possible values:

    -1: Choose automatically.

    0: No scaling.

    1: Apply scaling.

  • Dualize

    Integer parameter.

    Whether to dualize a problem before solving it.

    Default: -1

    Possible values:

    -1: Choose automatically.

    0: No dualizing.

    1: Dualizing the problem.

Other parameters

  • Logging

    Integer parameter.

    Whether to print optimization logs.

    Default: 1

    Possible values:

    0: No optimization logs.

    1: Print optimization logs.

  • LogToConsole

    Integer parameter.

    Whether to print optimization logs to console.

    Default: 1

    Possible values:

    0: No optimization logs to console.

    1: Print optimization logs to console.

Methods for accessing and setting parameters

In different programming interfaces, the ways to access and set parameters are slightly different. For details, please refer to the corresponding chapters of each programming language API reference manual: