Simulink Control Design

Key Features

Designing and analyzing control systems with Simulink Control Design.
Designing and analyzing control systems with Simulink Control Design. A control system modeled in Simulink (top), the PID Tuner interface (left), and the Bode diagram of the open-loop transfer function (right).

PID Controller Tuning

Simulink Control Design provides automatic gain-tuning capabilities for Simulink PID Controller blocks. You can accomplish the initial tuning of a PID controller with a single click. The product linearizes a Simulink model to obtain a linear plant model. If the model linearizes to zero due to discontinuities such as pulse width modulation (PWM), you can create a linear plant model from simulation input-output data using system identification (requires System Identification Toolbox™).

The product then uses the linear plant model and a proprietary tuning method to compute the PID gains based on the closed-loop performance that you desire. An initial controller is suggested based on an analysis of your system dynamics. You can then interactively adjust the response time and transient behavior in the PID Tuner. The PID Tuner also provides several plots you can use to analyze the controller behavior. For example, you can use a step reference tracking plot and an open-loop Bode plot to compare the performance of the current design with the design corresponding to initial gain values.

PID Controller Design for a DC Motor 3:53
Design a PID controller for a DC motor modeled in Simulink®. Create a closed-loop system by using the PID Controller block, then tune the gains of PID Controller block using the PID Tuner.

PID Controller Tuning for a Model with Discontinuities 5:40
Design a PID controller for a model that cannot be linearized. Use system identification to identify a plant model from simulation input-output data.

Trimming and Linearization of Simulink Models

Trimming the Model

Linear control design typically requires you to consider multiple operating points to account for the various setpoints of a nonlinear model. Simulink Control Design provides a graphical interface to determine model operating points. You can:

You can use these operating points to initialize a simulation at steady state or as a basis for linearization and control design.

Trim, Linearization, and Control Design for an Aircraft 7:17
Trim and linearize a nonlinear aircraft model and use the resulting linear model to design a pitch rate damper controller.

Linearizing the Model

With Simulink Control Design you can linearize continuous, discrete, and multirate Simulink models. Using graphical signal annotations to specify loop opening and linearization inputs and outputs, you can linearize the whole model, a portion of the model, or a single block or subsystem. The signal annotations can be used for open-loop and closed-loop analysis. The annotations and analysis are nonintrusive and do not affect your model's simulation behavior.

Simulink Control Design automatically computes the linearized model and lets you visualize the results in a step response plot or Bode diagram. A Linearization Inspector is provided to visualize the impact of each block in your Simulink model on the linearization. You can fine-tune your results by specifying the linear behavior of any number of blocks in your model. The linear behavior can be specified as a matrix gain or LTI model, giving you flexibility to linearize Simulink models containing discontinuities or event-based components, such as Stateflow® charts or pulse-width modulation signal-based systems.

When working with Robust Control Toolbox™, you can compute an uncertain linear model by specifying uncertain values for transfer functions and gains directly in the model. The resulting uncertain linear model can be used to study the impact of uncertainty on the stability and performance of your control system.

All of these tools have a command-line API to write scripts for batch mode trimming and linearization. You can write these scripts yourself or automatically create MATLAB code from the graphical interface.

Batch Mode Trimming and Linearization 5:20
Create a script to do batch mode trimming and linearization of Simulink® models.

Computing the Frequency Response of the Model

Simulink Control Design provides tools for the simulation-based computation of a model’s frequency response. You can use these tools to:

  • Verify the results of a linearization
  • Compute the model’s frequency response when linearization techniques are not appropriate, such as with models described by strong discontinuities or event-based dynamics
  • Study the effects of excitation signal amplitude on a nonlinear system’s gain and phase characteristics

Simulink Control Design helps you construct the excitation signals, such as sine sweeps or chirp signals; run the simulations; collect the data; and calculate and plot the model’s frequency response. The algorithms used to compute the frequency response are designed to minimize the simulation time and support the Accelerator and Rapid Accelerator modes in Simulink to speed up the overall computation.

Frequency Response Estimation 6:15
Estimate the frequency response of a Simulink® model using simulation.

Control System Design and Analysis in Simulink

Simulink Control Design provides a graphical interface  for tuning control loops directly in Simulink, using the graphical and automated tuning capabilities of Control System Toolbox™. You can use any control architecture that you build in Simulink that is linearizable. Tunable Simulink blocks include Gain, Transfer Function, Zero-Pole, State-Space, and PID Controller. Simulink Control Design automatically identifies the relevant control loops for the tuned blocks and launches a preconfigured session of the Control System Designer app.

Designing a Controller: Wheel Loader 9:09
Design a compensator (PID, etc.) to control a mechatronic system. Use linear control theory to design a control system.

You can use the Control System Designer app to:

  • Graphically tune multiple, continuous, or discrete SISO loops
  • Observe loop interactions and coupling effects while tuning parameters
  • Compute compensator designs using systematic design algorithms such as the proprietary Robust Response Time PID tuning, Ziegler-Nichols PID tuning, IMC design, or LQG design
  • Optimize the control loops to meet time-domain and frequency-domain design requirements (requires Simulink Design Optimization)
  • Directly tune Simulink block parameters, including PID gains, zero-pole-gain representations, and masked blocks
  • Examine the closed-loop response such as a reference trajectory or the ability of a control system to reject a disturbance at any portion of a model
  • Write the tuned parameter values back to your Simulink model for verification with the full nonlinear system
Optimizing a multiloop control system to simultaneously meet frequency-domain and time-domain requirements.
Optimizing a multiloop control system to simultaneously meet frequency-domain requirements (left) and time-domain requirements (right). The controller parameters to be optimized are specified in the graphical interface (top).

Try Simulink Control Design

Get trial software

Control System Tuning in Simulink Made Easy

View webinar

Learn Control System Design and Analysis in MATLAB and Simulink

View course