# TOMVIEW  
# REGISTER (TOMVIEW)
# LOGIN  
# myTOMVIEW
TOMLAB LOGO

« Previous « Start » Next »

4  TOMVIEW /KNITRO Solver Reference

A detailed description of the TOMVIEW /KNITRO solver interface is given below.

4.1  Reference

Purpose
Solve nonlinear constrained optimization problems.

TOMVIEW /KNITRO solves problems of the form
 
min
x
f(x)  
 
s/t xL x xU  
  bL Ax bU  
  cL c(x) cU  
    (1)
where x,xL,xU ∈ RnA ∈ Rm1 × nbL,bU ∈ Rm1 and c(x), cL, cU ∈ Rm2.

Calling Syntax

assign_*.vi
tomRun.vi



Description of Inputs
Prob  Problem description structure. The following fields are used:
 
 
x_0  Starting point.
 
x_L  Lower bounds on variables.
x_U  Upper bounds on variables.
 
A  Linear constraints matrix.
b_L  Lower bounds for linear constraints.
b_U  Upper bounds for linear constraints.
 
c_L  Lower bounds for nonlinear constraints.
c_U  Upper bounds for nonlinear constraints.
 
ConsPattern  The sparse m2 × n 0-1 pattern indicating nonzero elements in the nonlinear constraint Jacobian matrix.
 
f_Low  A lower bound on the objective function value. KNITRO will stop if it finds an x for which f(x)<=fLow.
 

Description of Outputs
Result  Structure with result from optimization. The following fields are set:
 
 
  x_k  Optimal point.
  f_k  Function value at optimum.
  g_k  Gradient value at optimu.
  c_k  Nonlinear constraint values at optimum.
  H_k  The Hessian of the Lagrangian function at optimum.
  v_k  Lagrange multipliers.
 
  x_0  Starting point.
  f_0  Function value at start.
 
  xState  State of each variable: 0/1/2/3: free / on lower bnd / on upper bnd / fixed.
  bState  State of each linear constraint, values as xState .
  cState  State of each nonlinear constraint, values as xState .
 
  Iter  Number of iterations.
  FuncEv  Number of function evaluations.
  GradEv  Number of gradient evaluations.
  HessEv  Number of Hessian evaluations.
  ConstrEv  Number of constraint evaluations.
  ConJacEv  Number of constraint Jacobian evaluations.
  ConHessEv  Number of constraint Hessian evaluations.
 
  ExitFlag  Exit status. The following values are used:
  0: Optimal solution found or current point cannot be improved.
    See Result.Inform  for more information.
  1: Maximum number of iterations reached.
  2: (Possibly) unbounded problem.
  4: (Possibly) infeasible problem.
 
  Inform  Status value returned from KNITRO solver.
 
  0: Locally optimal solution found.
 
    TOMVIEW /KNITRO found a locally optimal point which satisfies the stopping criterion (see Section 5 for more detail on how this is defined). If the problem is convex (for example, a linear program), then this point corresponds to a globally optimal solution.
 
  -1: Iteration limit reached.
 
    The iteration limit was reached before being able to satisfy the required stopping criteria.
 
  -2: Convergence to an infeasible point. Problem may be locally infeasible.
 
    The algorithm has converged to an infeasible point from which it cannot further decrease the infeasibility measure. This happens when the problem is infeasible, but may also occur on occasion for feasible problems with nonlinear constraints or badly scaled problems. It is recommended to try various initial points. If this occurs for a variety of initial points, it is likely the problem is infeasible.
 
  -3: Problem appears to be unbounded.
 
    The objective function appears to be decreasing without bound, while satisfying the constraints.
 
  -4: Current point cannot be improved.
 
    No more progress can be made. If the current point is feasible it is likely it may be optimal, however the stopping tests cannot be satisfied (perhaps because of degeneracy, ill-conditioning or bad scaling).
 
  -5: Current point cannot be improved. Point appears to be optimal, but desired accuracy could not be achieved.
 
    No more progress can be made, but the stopping tests are close to being satisfied (within a factor of 100) and so the current approximate solution is believed to be optimal.
 
  -6: Time limit reached.
 
    The time limit was reached before being able to satisfy the required stopping criteria.
 
  -50 to -60: Termination values in this range imply some input error.
 
    If PRINT LEVEL>0 details of this error will be printed to the file knitro.out.
 
  -90: Callback function error.
 
    This termination value indicates that an error (i.e., negative return value) occurred in a user provided callback routine.
 
  -97: LP solver error.
 
    This termination value indicates that an unrecoverable error occurred in the LP solver used in the active-set algorithm preventing the optimization from continuing.
 
  -98: Evaluation error.
 
    This termination value indicates that an evaluation error occurred (e.g., divide by 0, taking the square root of a negative number), preventing the optimization from continuing.
 
  -99: Not enough memory available to solve problem.
 
    This termination value indicates that there was not enough memory available to solve the problem.
 
  Solver  Solver used ('KNITRO').
  SolverAlgorithm  Solver algorithm used.
 

4.2  Options

Description of Inputs
Prob  Problem description structure. The following fields are used:
 
Printing
PRINT FILE  Name of file to print solver progress and status information to. Please see PRINT LEVEL parameter described below.
 
Print Levels
PRINT LEVEL  Print level in solver. TOMVIEW /KNITRO supports solver progress information being printed to a file.
 
  For output to the file: set PRINT LEVEL to a positive value (1-6) and set PRINT FILE.
 
0: Printing of all output is suppressed (default).
 
1: Only summary information is printed.
 
2: Information every 10 major iterations is printed where a major iteration is defined by a new solution estimate.
 
3: Information at each major iteration is printed.
 
4: Information is printed at each major and minor iteration where a minor iteration is defined by a trial iterate.
 
5: In addition, the values of the solution vector x are printed.
 
6: In addition, the values of the constraints c and Lagrange multipliers lambda are printed.
 
Method 1
 
ALG  Indicates which optimization algorithm to use to solve the problem. Default 0.
 
  0: automatic algorithm selection.
 
  1: Interior/Direct algorithm.
 
  2: Interior/CG algorithm.
 
  3: Active algorithm, SLQP.
 
BARRULE  Indicates which strategy to use for modifying the barrier parameter in the interior point code. Some strategies are only available for the Interior/Direct algorithm. (see Section 7). Default 0.
 
  0: automatically choose the rule for updating the barrier parameter.
 
  1: monotonically decrease the barrier parameter.
 
  2: an adaptive rule based on the complementarity gap to determine the value of the barrier parameter at every iteration.
 
  3: uses a probing (affine-scaling) step to dynamically determine the barrier parameter value at each iteration.
 
  4: uses a Mehrotra predictor-corrector type rule to determine the barrier parameter with safeguards on the corrector step.
 
  5: uses a Mehrotra predictor-corrector type rule to determine the barrier parameter without safeguards on the corrector step.
 
  6: minimizes a quality function at each iteration to determine the barrier parameter.
 
  NOTE: Only strategies 0-2 are available for the Interior/CG algorithm. All strategies are available for the Interior/Direct algorithm. Strategies 4 and 5 are typically recommended for linear programs or convex quadratic programs. Many problems benefit from a non-default setting of this option and it is recommended to experiment with all settings. In particular we recommend trying strategy 6 when using the Interior/Direct algorithm. This parameter is not applicable to the Active algorithm..
 
LMSIZE  Specifies the number of limited memory pairs stored when approximating the Hessian using the limited-memory quasi-Newton BFGS option. The value must be between 1 and 100 and is only used when HESSOPT=6. Larger values may give a more accurate, but more expensive, Hessian approximation. Smaller values may give a less accurate, but faster, Hessian approximation. When using the limited memory BFGS approach it is recommended to experiment with different values of this parameter. See Section 8 for more details. Default value: 10
 
FEASIBLE  Indicates whether or not to use the feasible version of TOMVIEW /KNITRO.
 
  0: Iterates may be infeasible.
 
  1: Given an initial point which sufficiently satisfies all inequality constraints as defined by,
cl + tolc(x) ≤ cutol     (2)
(for cl cu), the feasible version of TOMVIEW /KNITRO ensures that all subsequent solution estimates strictly satisfy the inequality constraints. However, the iterates may not be feasible with respect to the equality constraints. The tolerance tol>0 in 2 for determining when the feasible mode is active is determined by the double precision parameter
FEASMODETOL described below. This tolerance (i.e. FEASMODETOL) must be strictly positive. That is, in order to enter feasible mode, the point given to TOMVIEW /KNITRO must be strictly feasible with respect to the inequality constraints.
  If the initial point is infeasible (or not sufficiently feasible according to 2) with respect to the inequality constraints, then TOMVIEW /KNITRO will run the infeasible version until a point is obtained which sufficiently satisfies all the inequality constraints. At this point it will switch to feasible mode.
 
  NOTE: This option can be used only when ALG=2. See Section 8.3 for more details.
 
GRADOPT  Specifies how to calculate first derivatives. In addition to the available numeric differentiation methods available in TOMVIEW, KNITRO can internally estimate forward or centered numerical derivatives.
 
  The following settings are available:
 
1: KNITRO expects the user to provide exact first derivatives (default).
 
  However, note that this can imply numerical derivatives calculated by any of the available methods in TOMVIEW. See the TOMVIEW User's Guide for more information on numerical derivatives.
 
2: KNITRO will estimate forward finite differential derivatives.
 
3: KNITRO will estimate centered finite differential derivatives.
 
4: KNITRO expects exact first derivatives and performs gradient checking by internally calculating forward finite differences.
 
5: KNITRO expects exact first derivatives and performs gradient checking by internally calculating centered finite differences.
 
  NOTE: It is highly recommended to provide exact gradients if at all possible as this greatly impacts the performance of the code. For more information on these options see Section 8.1.
 
HESSOPT  Specifies how to calculate the Hessian (Hessian-vector) of the Lagrangian function.
 
1: KNITRO expects the user to provide the exact Hessian.
 
2: KNITRO will compute a (dense) quasi-Newton BFGS Hessian approximation.
 
3: KNITRO will compute a (dense) quasi-Newton SR1 Hessian approximation.
 
4: KNITRO will compute Hessian-vector products using finite differences.
 
5: KNITRO expects the user to provide a routine to compute the Hessian-vector products. If this option is selected, the calculation is handled by the TOMVIEW function nlp_d2Lv.m .
 
6: KNITRO will compute a limited-memory quasi-Newton BFGS (default).
 
  NOTE: If exact Hessians (or exact Hessian-vector products) cannot be provided by the user but exact gradients are provided and are not too expensive to compute, option 4 above is typically recommended. The finite-difference Hessian-vector option is comparable in terms of robustness to the exact Hessian option (assuming exact gradients are provided) and typically not too much slower in terms of time if gradient evaluations are not the dominant cost.
 
  However, if exact gradients cannot be provided (i.e. finite-differences are used for the first derivatives), or gradient evaluations are expensive, it is recommended to use one of the quasi-Newton options, in the event that the exact Hessian is not available. Options 2 and 3 are only recommended for small problems (n < 1000) since they require working with a dense Hessian approximation. Option 6 should be used in the large-scale case.
  NOTE: Options HESSOPT=4 and HESSOPT=5 are not available when ALG=1. See Section 8.2 for more detail on second derivative options.
 
HONORBNDS  Indicates whether or not to enforce satisfaction of the simple bounds 1 throughout the optimization (see Section 8.4). Default 0.
 
0: TOMVIEW /KNITRO does not enforce that the bounds on the variables are satisfied at intermediate iterates.
 
1: TOMVIEW /KNITRO enforces that the initial point and all subsequent solution estimates satisfy the bounds on the variables 1.
 
INITPT  Indicates whether an initial point strategy is used. Default 0.
 
0: No initial point strategy is employed.
 
1: Initial values for the variables are computed. This option may be recommended when an initial point is not provided by the user, as is typically the case in linear and quadratic programming problems.
 
MULTISTART  Indicates whether KNITRO will solve from multiple start points to find a better local minimum. See Section 8 for details. Default 0.
 
0: TOMVIEW /KNITRO solves from a single initial point.
 
1: TOMVIEW /KNITRO solves using multiple start points.
 
MAXCGIT  Determines the maximum allowable number of inner conjugate gradient (CG) iterations per Knitro minor iteration. Default 0.
 
0: TOMVIEW /KNITRO automatically determines an upper bound on the number of allowable CG iterations based on the problem size.
 
n: At most n CG iterations may be performed during one Knitro minor iteration, where n>0.
 
MAXCROSSIT  Specifies the maximum number of crossover iterations before termination. When running one of the interior-point algorithms in KNITRO, if this value is positive, it will switch to the Active algorithm near the solution, and perform at most MAXCROSSIT iterations of the Active algorithm to try to get a more exact solution. If this value is 0 or negative, no Active crossover iterations will be performed.
  If crossover is unable to improve the approximate interior-point solution, then it will restore the interior-point solution. In some cases (especially on large-scale problems or difficult degenerate problems) the cost of the crossover procedure may be significant – for this reason, the crossover procedure is disabled by default. However, in many cases the additional cost of performing crossover is not significant and you may wish to enable this feature to obtain a more accurate solution. See Section 8 for more details on the crossover procedure. Default 0.
 
MAXIT  Specifies the maximum number of major iterations before termination. Default 10000.
 
Method 2
 
MSMAXSOLVES  Specifies how many start points to try in multistart. This option is only valid if MULTISTART=1. Default 1.
 
0: TOMVIEW /KNITRO solves from a single initial point.
 
SCALE  Performs a scaling of the objective and constraint functions based on their values at the initial point. If scaling is performed, all internal computations, including the stopping tests, are based on the scaled values. Default 1.
 
0: No scaling is performed.
 
1: The objective function and constraints may be scaled.
 
SHIFTINIT  Determines whether or not the interior-point algorithm in TOMVIEW /KNITRO shifts the given initial point to satisfy the variable bounds 1. Default 1.
 
0: TOMVIEW /KNITRO will not shift the given initial point to satisfy the variable bounds before starting the optimization.
 
1: TOMVIEW /KNITRO will shift the given initial point.
 
SOC  Indicates whether or not to use the second order correction (SOC) option. A second order correction may be beneficial for problems with highly nonlinear constraints. Default 1.
 
0: No second order correction steps are attempted.
 
1: Second order correction steps may be attempted on some iterations.
 
2: Second order correction steps are always attempted if the original step is rejected and there are nonlinear constraints.
 
Tolerances
DELTA  Specifies the initial trust region radius scaling factor used to determine the initial trust region size. Default 1.0.
 
FEASMODETOL  Specifies the tolerance in 2 by which the iterate must be feasible with respect to the inequality constraints before the feasible mode becomes active. This option is only relevant when FEASIBLE=1. Default 1e−4.
 
FEASTOL  Specifies the final relative stopping tolerance for the feasibility error. Smaller values of FEASTOL result in a higher degree of accuracy in the solution with respect to feasibility. Default 1e−6.
 
FEASTOLABS  Specifies the final absolute stopping tolerance for the feasibility error. Smaller values of FEASTOLABS result in a higher degree of accuracy in the solution with respect to feasibility. Default 0.
 
  NOTE: For more information on the stopping test used in TOMVIEW /KNITRO see Section 5.
MAXTIMECPU  Specifies, in seconds, the maximum allowable CPU time before termination. Default 1e8.
 
  NOTE: For more information on the stopping test used in TOMVIEW /KNITRO see Section 5.
 
MAXTIMEREAL  Specifies, in seconds, the maximum allowable real time before termination. Default 1e8.
 
  NOTE: For more information on the stopping test used in TOMVIEW /KNITRO see Section 5.
 
MU  Specifies the initial barrier parameter value for the interior-point algorithms. Default 1.0e−1.
 
OBJRANGE  Determines the allowable range of values for the objective function for determining unboundedness. If the magnitude of the objective function is greater than OBJRANGE and the iterate is feasible, then the problem is determined to be unbounded. Default 1.0e20.
 
OPTTOL  specifies the final relative stopping tolerance for the KKT (optimality) error. Smaller values of OPTTOL result in a higher degree of accuracy in the solution with respect to optimality. Default 1.0e−6.
 
OPTTOLABS  Specifies the final absolute stopping tolerance for the KKT (optimality) error. Smaller values of OPTTOLABS result in a higher degree of accuracy in the solution with respect to optimality. Default 0.0e0.
 
  NOTE: For more information on the stopping test used in TOMVIEW /KNITRO see Section 5.
 
PIVOT  Specifies the initial pivot threshold used in the factorization routine. The value should be in the range [0 0.5] with higher values resulting in more pivoting (more stable factorization). Values less than 0 will be set to 0 and values larger than 0.5 will be set to 0.5. If pivot is non-positive initially no pivoting will be performed. Smaller values may improve the speed of the code but higher values are recommended for more stability (for example, if the problem appears to be very ill-conditioned). Default 1.0e−8.
 
XTOL  The optimization will terminate when the relative change in the solution estimate is less than XTOL. If using an interior-point algorithm and the barrier parameter is still large, TOMVIEW /KNITRO will first try decreasing the barrier parameter before terminating. Default 1.0e−15.
 

« Previous « Start » Next »