|On this page…|
Note The next two studies assume some knowledge of control systems. In addition to Simulink® and the SimMechanics™ product, the studies use these products:
You should have some experience with these tools before proceeding.
To understand trimming better, work through Trimming and Linearizing Through Inverse Dynamics earlier in this chapter.
A classic engineering problem is the design of controllers for a physical system, the plant . A SimMechanics model can represent a complex mechanical system and helps you design and implement a control system for the plant, in conjunction with Simulink and related control design products.
In the next two case studies, you use SimMechanics software to model the plant and Simulink to analyze and synthesize controllers. You explore a basic challenge of control design, the tradeoff between responsiveness and stability, by implementing first a simple controller, then a more complex and robust one . This section is preliminary to those studies.
The motion of an uncontrolled physical system is represented by its position and velocity variables arranged into a state vector X. The dynamics of the system is described by a force law:
Introducing control means introducing sensors and actuators that modify the system's otherwise natural motion. The actuators impose artificial forces — collectively, the inputs U — on the system, while the sensors detect motions and report outputs Y. The dynamics of the controlled system are modified:
The U and Y are the control variables of the system.
By selecting the proper set of U and Y and a feedback control or compensator law U = c(Y) that modifies the system's motion X in a desired way, you impose control actuator forces for the relevant range of X, U, and Y.
Selecting c is the fundamental problem of control design. The desired trajectory of X is the reference or nominal trajectory. The difference of the actual and reference trajectories is the motion error. Finding the actuator forces needed to produce a desired motion is closely related to the problem of inverse dynamics. See the case study, Trimming and Linearizing Through Inverse Dynamics preceding.
The controller and plant transfer functions are often called C and G, respectively. The combined controller-plant transfer function forms are the open-loop CG and the closed-loop CG/(1+CG).
Controller and plant response magnitudes are measured in decibels (dB).
The next two case studies use these files, in addition to the initialization script and function.
|mech_stewart_control_derivmech_stewart_control_deriv||Configurable subsystem: Derivative block or transfer function (filtered)|
|mech_stewart_controllersmech_stewart_controllers||Configurable subsystem: Null, PID, or H-infinity controller|
|mech_stewartplatform_legmech_stewartplatform_leg||Library model of Stewart platform leg; used six times in the Plant subsystem of the main model|
The problems and techniques of the next two case studies only touch the basics of control design. In practice, you need to consider additional issues and goals. Also consult References.
To fully understand the plant, you need to find plant operating points other than the simple ones used here and optimize the controller in other representative states.
See the preceding case study, Trimming and Linearizing Through Inverse Dynamics.
To design more robust controllers, you should consider the effect of parameter uncertainty and signal noise. This step involves comparing typical plant motion frequencies, noise frequencies, and filtered derivative cutoffs.
The following toolboxes can help with such tasks:
To move toward hardware implementation, you must consider discretizing the controller . Among other requirements, this necessitates using a fixed-step solver, optimizing the solver step size and sample rate, and adjusting the filtered derivative cutoff.
See the final two case studies: