Main Content

Nonlinear MPC Design

Design model predictive controllers with nonlinear prediction models, costs, and constraints

As in traditional linear MPC, nonlinear MPC calculates control actions at each control interval, using a combination of model-based prediction and constrained optimization. The key differences are:

  • The prediction model can be nonlinear and include time-varying parameters

  • The equality and inequality constraints can be nonlinear

  • The scalar cost function to be minimized can be a nonquadratic (linear or nonlinear) function of the decision variables.

By default, nonlinear MPC controllers solve a nonlinear programming problem using the fmincon function, which requires Optimization Toolbox™ software. If you do not have Optimization Toolbox software you can specify your own custom nonlinear solver.

For more information, see Nonlinear MPC.


nlmpcNonlinear model predictive controller
nlmpcMultistageMultistage nonlinear model predictive controller (Since R2021a)
validateFcnsExamine prediction model and custom functions of nlmpc or nlmpcMultistage objects for potential problems
generateJacobianFunctionGenerate MATLAB Jacobian functions for multistage nonlinear MPC using automatic differentiation (Since R2023a)
nlmpcmoveCompute optimal control action for nonlinear MPC controller
nlmpcmoveoptOption set for nlmpcmove function
getSimulationDataCreate data structure to simulate multistage MPC controller with nlmpcmove (Since R2021a)
convertToMPCConvert nlmpc object into one or more mpc objects
createParameterBusCreate Simulink bus object and configure Bus Creator block for passing model parameters to Nonlinear MPC Controller block


Nonlinear MPC ControllerSimulate nonlinear model predictive controllers
Multistage Nonlinear MPC ControllerSimulate multistage nonlinear model predictive controllers (Since R2021a)


Nonlinear MPC Basics

Feedback Control

Optimal Planning

Economic MPC

Passivity-Based MPC