WOLFRAM SYSTEM MODELER
This model shows an inversion-based controller that is used to control a hoist crane.
The hoist crane is modeled using the PlanarMechanics Modelica library. Force is applied to a prismatic joint that pushes a crab along a one-dimensional beam. Attached to the crab is a dampened revolute joint that connects to the load through a stiff rod.
In the controller, a filtered pulse is used as a reference signal to control the position of the load. Using a constrained inverse block, the force that should be applied to the crab can be calculated from the reference signal.
To simulate the model, click the Simulate button:
Explore how the crane is positioned relative to its reference position by examining the plot that is automatically displayed after simulating the model. The first variable describes the actual position of the crane, while the second describes the reference position that is input into the controller.
PlanarMechanics and Multibody systems have visualizers to show what a real-world system would look like.
To show a 3D animation of the model, click the Animation button:
Use your mouse or trackpad to drag the animation to a good angle and zoom in with your scroll wheel or by using the trackpad.
Changing parameters for the simulation can be done rapidly in Simulation Center. The crane_I parameter determines the "real" inertia of the load. The model used inside the controller also has an inertia parameter that determines what the controller expects the load inertia to be. When the real and the expected inertia differ from each other, the controller will not be able to accurately predict what force to apply to the crane.
Try changing the inertia for the load and see how this affects the controller:
You should now see the graph below:
In order to get the full experience of this example, you need a desktop Wolfram Language product. A free trial download is available at www.wolfram.com/mathematica/trial/
For the full example, open the accompanying notebook ModelInversionControl.nb.
Type: Time (s)
Description: Period of the input pulse, position switches every half period
Type: Frequency (Hz)
Description: Cut-off frequency of the input filter, higher values give sharper movement
Type: Inertia (kg⋅m²)
Description: Inertia of the physical crane body
Type: Inertia (kg⋅m²)
Description: Inertia of the inverted crane body model.
Description: Complement open loop control with closed loop corrective controller.
Description: Proportional gain of corrective controller.
Description: Time constant of integrative part of corrective controller.
Description: Time constant of derivative part of corrective controller.
Description: Type of initialization used for PID controller
Description: Input signal filter, smoothing the signal.
Description: Load position reference, going back and forth between 0 and 1 meters along the X-axis.
Description: Coordinate system.
Description: Crab crane setup.
Description: Corrective closed loop feedback of crane position.
Description: Crab crane inversion block. Open loop control.
Description: Corrective PID-controller.
Description: Input force sum.
Description: Crab crane model.