For linear programming, mixed-integer linear programming, or quadratic problems with linear constraints, choose between this solver-based approach and a problem-based approach. See Optimization Problem Setup.
To represent your optimization problem for solution in this solver-based approach, you generally follow these steps:
• Choose an optimization solver.
• Create an objective function, typically the function you want to minimize.
• Create constraints, if any.
• Set options, or use the default options.
• Call the appropriate solver.
For a basic nonlinear optimization example, see Solve a Constrained Nonlinear Problem. For a basic mixed-integer linear programming example, see Mixed-Integer Linear Programming Basics: Solver-Based.