# OptimizationProblem

Optimization problem

## Description

An `OptimizationProblem`

object describes an optimization
problem, including variables for the optimization, constraints, the objective function,
and whether the objective is to be maximized or minimized. Solve a complete problem
using `solve`

.

**Tip**

For the full workflow, see Problem-Based Optimization Workflow.

## Creation

Create an `OptimizationProblem`

object by using `optimproblem`

.

**Warning**

The problem-based approach does not support complex values in an objective function, nonlinear equalities, or nonlinear inequalities. If a function calculation has a complex value, even as an intermediate value, the final result can be incorrect.

## Properties

## Object Functions

`optimoptions` | Create optimization options |

`prob2struct` | Convert optimization problem or equation problem to solver form |

`show` | Display information about optimization object |

`solve` | Solve optimization problem or equation problem |

`varindex` | Map problem variables to solver-based variable index |

`write` | Save optimization object description |

## Examples

## See Also

`optimproblem`

| `OptimizationConstraint`

| `OptimizationExpression`

| `OptimizationVariable`

| `solve`

| `show`

| `write`

**Introduced in R2017b**