Optimization Toolbox | ![]() ![]() |
Problems Covered by Large-Scale Methods
Not all possible problem formulations are covered by the large-scale algorithms. The following table describes what functionality is covered by the large-scale methods. For example, for fmincon
, the large-scale algorithm covers the case where there are only bound constraints or only linear equalities. For each problem formulation, the third column describes what additional information is needed for the large-scale algorithms. For fminunc
and fmincon
, the gradient must be computed along with the objective in the user-supplied function (the gradient is not required for the medium-scale algorithms).
Since these methods can also be used on small- to medium-scale problems that are not necessarily sparse, the last column of the table emphasizes what conditions are needed for large-scale problems to run efficiently without exceeding your computer system's memory capabilities, e.g., the linear constraint matrices should be sparse. For smaller problems the conditions in the last column are unnecessary.
Several examples, which follow this table, clarify the contents of the table.
Function |
Problem Formulations |
Additional Information Needed |
For Large Problems |
fminunc |
![]() |
Must provide gradient for f(x) in fun . |
|
fmincon |
Must provide gradient for f(x) in fun . |
||
lsqnonlin |
F(x) must be overdetermined (have at least as many equations as variables). |
None |
|
lsqcurvefit |
![]() |
None |
|
fsolve |
![]() ![]() |
None |
|
lsqlin |
![]() such that ![]() ![]() ![]() ![]() |
None |
![]() |
linprog |
![]() such that ![]() ![]() ![]() |
None |
![]() ![]() |
quadprog |
None |
In the following examples, many of the M-file functions are available in the Optimization Toolbox optim
directory. Most of these do not have a fixed problem size, i.e., the size of your starting point xstart
determines the size problem that is computed. If your computer system cannot handle the size suggested in the examples below, use a smaller-dimension start point to run the problems. If the problems have upper or lower bounds or equalities, you must adjust the size of those vectors or matrices as well.
![]() | Large-Scale Examples | Nonlinear Equations with Jacobian | ![]() |