MATLAB Examples

Create a 2-D lookup table from experimental data.

Generate a lookup table to approximate an engine volumetric efficiency surface using experimental data.

Use parallel computing to optimize the time-domain response of a Simulink® model. You use Simulink® Design Optimization™ and Parallel Computing Toolbox™ to tune the gains of a discrete PI

Improve optimization performance using the Parallel Computing Toolbox™. The example discusses the speedup seen when using parallel computing to optimize a complex Simulink® model. The

Use the Fast Restart feature of Simulink® to speed up optimization of a model. You use Fast Restart to estimate the parameters of an engine throttle model.

Create an estimation experiment from measured data stored in a file and how to preprocess the measured data. You use the imported data to estimate the parameters of a simple RC circuit.

Estimate the physical parameters - mass (m), spring constant (k) and damping (b) of a simple mass-spring-damper model. This example illustrates the significance of initial state

Use experiment data to estimate model parameters. You estimate the parameters of an engine throttle system.

Estimate model parameters from multiple sets of experimental data. You estimate the parameters of a mass-spring-damper system.

Estimate the initial state and parameters of a model.

Use experimental data to estimate model parameter values.

Automatically generate a MATLAB function to solve a Parameter Estimation problem. You use the Parameter Estimation tool to define an estimation problem for a mass-spring-damper and

Use multiple experiments to estimate a mix of model parameter values; some that are estimated using all the experiments and others that are estimated using individual experiments. The

Estimate model parameters while imposing constraints on the parameter values.

Set a model to steady-state in the process of parameter estimation. Setting a model to steady-state is important in many applications such as power systems and aircraft dynamics. This

Estimate the parameters of a multi-domain DC servo motor model constructed using various physical modeling products.

Use Simulink® Design Optimization™ to estimate multiple parameters of a model by iterated estimations.

Estimate parameters of a muscle reflex model.

Use Simulink® Design Optimization™ to estimate parameters of a clutch model created using Simscape™ Driveline™ library blocks.

Estimate the coefficients of a nonlinear (quadratic) function to approximate the dynamic behavior of a system component.

Use parameter bounds to improve estimation performance. This is illustrated by estimating the power rating, P, of a synchronous machine.

Automatically generate a MATLAB function to solve a Design Optimization problem. You use the Response Optimization tool to define an optimization problem for a hydraulic cylinder design

Tune model parameters to meet frequency-domain requirements using the Response Optimization tool.

Tune a controller to satisfy time- and frequency-domain design requirements using the Response Optimization tool.

Optimize a design when there are uncertain variables. You optimize the dimensions of a Continuously Stirred Tank Reactor (CSTR) to minimize product concentration variation and

Specify a custom objective function for a model signal. You calculate the objective function value using a variable that models parameter uncertainty.

Optimize a design and specify parameter-only constraints that prevent the model from being evaluated in an invalid solution space.

Optimize a design to meet a custom objective using the Response Optimization tool. You optimize the cylinder parameters to minimize the cylinder geometry and satisfy design requirements.

Optimize a design to meet custom objective using sdo.optimize. You optimize the cylinder parameters to minimize the cylinder geometry and satisfy design requirements.

Tune model parameters to meet frequency-domain requirements, using the sdo.optimize command.

Tune parameters in a lookup table in a model that uses gain scheduling to adjust the controller's response to a plant that varies. Model tuning uses the sdo.optimize command.

Tune parameters in a lookup table in a model that uses gain scheduling to adjust the controller's response to a plant that varies. Model tuning uses the Response Optimization tool.

Use numerical optimization to tuning the controller parameters of a nonlinear system. In this example, we model a CE 152 Magnetic Levitation system where the controller is used to position a

Use Simulink® Design Optimization™ to optimize the controller of an inverted pendulum. The inverted pendulum is on a cart and the motion of the cart is controlled. The controller's

Use Simulink® Design Optimization™ to tune the gains of the PID controller (Kp, Ki, and Kd) and optimize the step response of the plant. To view the results, use the following steps.

Use Simulink® Design Optimization™ to optimize the temperature control of a heat exchanger around a temperature set-point.

Use Simulink® Design Optimization™ to optimize the output response of a plant by tuning the LQR gain matrix and feed-forward gain. This model includes uncertainty in the plant model and

Use Simulink® Design Optimization™ to optimize the multi-loop controller parameters of a distillation column. The Distillation column produces methanol and is represented as a linear

Use Simulink® Design Optimization™ to tune an all-pass filter of a Phase Lock Loop. The filter includes a second-order low pass filter and a feedthrough gain. The feedthrough gain and the

Use Simulink® Design Optimization™ to optimize the current controller parameters of a 3-phase thyristor converter. The model uses blocks from Simscape™ and Simscape™ Power Systems™.

Use Simulink® Design Optimization™ to tune the gains of a Digital Pitch Rate Controller and optimize the response of an Aircraft to a step altitude change. The controller includes state

Use Simulink® Design Optimization™ to track a reference signal and optimize the response with uncertainties in the plant model. The plant model consists of the plant transfer function and

Use Simulink® Design Optimization™ to optimize the position controller parameters of a Stewart platform. The Stewart platform is modeled using Simscape™ Multibody™ blocks.

Use Simulink Design Optimization™ to optimize a design for performance and cost. In this example, we tune an automotive engine speed controller while reducing controller costs by tuning

Use Simulink® Design Optimization™ to optimize the position controller parameters for a servomotor piston. This model uses blocks from Stateflow®.

Apply Simulink® Design Optimization™ to optimize the autopilot gains of an airframe to control its fin deflection. The model uses blocks from Aerospace Blockset™.

Design a PI control system to control the speed of a DC motor, and is based on the Control System Toolbox™ example "DC Motor Control".

Tune a lead-lag regulator for a simplified hydraulic piston. The piston model is given by:

Design two feedback loops in a cascaded control system to track reference signals. The design uses the body rate (q) as an inner feedback loop and the acceleration (az) as an outer feedback

Use Simulink® Design Optimization™ to tune a compensator in a Simulink model. You will add performance requirements to further refine and optimize an initial compensator design performed

Sample and explore a design space. You explore the design of a Continuously Stirred Tank Reactor to minimize product concentration variation and production cost. The design includes feed

Use sensitivity analysis to narrow down the number of parameters that you need to estimate to fit a model. This example uses a model of the vestibulo-ocular reflex, which generates

Use sensitivity analysis to narrow down the number of parameters that you need to estimate when fitting a model. This example uses a model of the vestibulo-ocular reflex, which generates

Sample and explore a design space using the Sensitivity Analysis tool. You explore the design of a Continuously Stirred Tank Reactor (CSTR) to minimize product concentration variation and

Use the Sensitivity Analysis tool to explore the behavior of a PI controller for a DC motor. The controller is susceptible to variations caused by component tolerances, and the impact on

Choose your country to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .

You can also select a location from the following list:

Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.