![]() ![]() If exact/user-supplied gradients are used, an additional matrix should be returned with the Jacobian of the functions at x. fun accepts a vector x and returns a vector F, the values of the functions/residuals evaluated at x. knitro_nlnlsq ( fun, x0, lb, ub, extendedFeatures, options, knitroOptsFile )įun: The functions whose sum of squares is minimized. Unlike the user-supplied Jacobian for knitro_nlp/ knitro_minlp, the entries J(i,j) of the Jacobian for knitro_nlneqs represent the partial derivative of the function component i with respect to variable j. If exact/user-supplied gradients are used, an additional matrix should be returned with the Jacobian of the nonlinear equations at x. fun accepts a vector x and returns a vector F, the values of the nonlinear equations evaluated at x. knitro_nlneqs ( fun, x0, extendedFeatures, options, knitroOptsFile )įun: The functions whose components are to be solved to equal zero. For notes on when this option is available, see KN_get_hessian_values(). An empty argument can be specified using. Only the first two arguments are required. If exact/user-supplied gradients are used, two additional matrices should be returned with the gradients for the nonlinear inequality constraints and the gradients for the nonlinear equality constraints (optional). ![]() nonlcon accepts a vector x and returns two vectors: the values of the nonlinear inequality constraints at x and the values of the nonlinear equality constraints at x. Nonlcon: The function that computes the nonlinear inequality and equality constraints. If exact/user-supplied gradients are used, an additional vector with the objective gradient should be returned. fun accepts a vector x and returns a scalar f, the objective function evaluated at x. knitro_minlp ( fun, x0, xType, A, b, Aeq, beq, lb, ub, nonlcon, extendedFeatures, options, knitroOptsFile )įun: The function to be minimized. Only the first four arguments are required. If xType=, variables are assumed to be continuous. XType: Specifies the variable type (should have the same dimension as x): 0 for continuous, 1 for general integer, and 2 for binary (set lb=0 and ub=1 for any binary variables). knitro_milp ( f, xType, A, b, Aeq, beq, lb, ub, x0, extendedFeatures, options, knitroOptsFile ) Only the first output argument is required. ![]() Lambda: Structure containing the Lagrange multipliers at the solution with a different field for each constraint type. Output: Structure containing solution information about the optimization. įval: The optimal solution objective value.Įxitflag: Integer identifying the reason for termination of the algorithm. ![]() Only the first three arguments are required. KnitroOptsFile: Knitro options filename used to set Knitro options specified in a text file, see Setting options (optional). Options: Knitro options structure generated from knitro_options, see knitro_options (optional), Ub: Variable upper bound vector (optional).ĮxtendedFeatures: Structure used to input additional model features, see The extendedFeatures Structure (optional). Lb: Variable lower bound vector (optional). knitro_lp ( f, A, b, Aeq, beq, lb, ub, x0, extendedFeatures, options, knitroOptsFile )Ī: Coefficient matrix for linear inequality constraints.ī: Upper bound vector for linear inequality constraints.Īeq: Coefficient matrix for linear equality constraints (optional).īeq: Right-hand side vector for linear equality constraints (optional). The knitromatlab/examples directory provided with the Knitro distribution. Several examples using both the solver-based approach and problem-based approach are included in The Knitro/MATLAB interface functions are described in more detail below in alphabetical order. In addition, the knitro_options function can be used to specify Knitro solver The Knitro/MATLAB interface also provides a generic knitro_solve function that canīe used to solve any model defined using the problem-based approach. Knitro_qp for solving quadratic programs (QPs). Knitro_qcqp for solving quadratically constrained quadratic programs (QCQPs) (this function can also be used to solve second order cone programs (SOCPs) by formulating the cone constraints as quadratic constraints) Knitro_nlp for solving continuous nonlinear optimization models (NLPs) Knitro_nlnlsq for solving nonlinear least-squares models Knitro_nlneqs for solving nonlinear systems of equations Knitro_minlp for solving mixed-integer nonlinear optimization models (MINLPs) Knitro_milp for solving mixed-integer linear programs (MILPs) Knitro_lp for solving linear programs (LPs) The solver-based interface provides the following specialized functionĬalls for various optimization model types: The “solver-based” and “problem-based” approaches offered by MATLAB. The interfaces used to call Knitro from the MATLAB environment mimic both ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |