Simscape™ Multibody™
User's Guide
R2022b
How to Contact MathWorks
Latest news:
www.mathworks.com
Sales and services:
www.mathworks.com/sales_and_services
User community:
www.mathworks.com/matlabcentral
Technical support:
www.mathworks.com/support/contact_us
Phone: 508-647-7000
The MathWorks, Inc.
1 Apple Hill Drive
Natick, MA 01760-2098
Simscape™ Multibody™ User's Guide
© COPYRIGHT 2002–2022 by The MathWorks, Inc.
The software described in this document is furnished under a license agreement. The software may be used or copied
only under the terms of the license agreement. No part of this manual may be photocopied or reproduced in any form
without prior written consent from The MathWorks, Inc.
FEDERAL ACQUISITION: This provision applies to all acquisitions of the Program and Documentation by, for, or through
the federal government of the United States. By accepting delivery of the Program or Documentation, the government
hereby agrees that this software or documentation qualies as commercial computer software or commercial computer
software documentation as such terms are used or dened in FAR 12.212, DFARS Part 227.72, and DFARS 252.227-7014.
Accordingly, the terms and conditions of this Agreement and only those rights specied in this Agreement, shall pertain
to and govern the use, modication, reproduction, release, performance, display, and disclosure of the Program and
Documentation by the federal government (or other entity acquiring for or through the federal government) and shall
supersede any conicting contractual terms or conditions. If this License fails to meet the government's needs or is
inconsistent in any respect with federal procurement law, the government agrees to return the Program and
Documentation, unused, to The MathWorks, Inc.
Trademarks
MATLAB and Simulink are registered trademarks of The MathWorks, Inc. See
www.mathworks.com/trademarks for a list of additional trademarks. Other product or brand names may be
trademarks or registered trademarks of their respective holders.
Patents
MathWorks products are protected by one or more U.S. patents. Please see www.mathworks.com/patents for
more information.
Revision History
March 2012 Online only New for Version 4.0 (Release R2012a)
September 2012 Online only Revised for Version 4.1 (Release R2012b)
March 2013 Online only Revised for Version 4.2 (Release R2013a)
September 2013 Online only Revised for Version 4.3 (Release R2013b)
March 2014 Online only Revised for Version 4.4 (Release R2014a)
October 2014 Online only Revised for Version 4.5 (Release R2014b)
March 2015 Online only Revised for Version 4.6 (Release R2015a)
September 2015 Online only Revised for Version 4.7 (Release R2015b)
March 2016 Online only Revised for Version 4.8 (Release R2016a)
(Renamed from SimMechanics™ User’s Guide)
September 2016 Online only Revised for Version 4.9 (Release R2016b)
March 2017 Online only Revised for Version 5.0 (Release R2017a)
September 2017 Online only Revised for Version 5.1 (Release R2017b)
March 2018 Online only Revised for Version 5.2 (Release R2018a)
September 2018 Online only Revised for Version 6.0 (Release R2018b)
March 2019 Online only Revised for Version 6.1 (Release R2019a)
September 2019 Online only Revised for Version 7.0 (Release R2019b)
March 2020 Online only Revised for Version 7.1 (Release R2020a)
September 2020 Online only Revised for Version 7.2 (Release R2020b)
March 2021 Online only Revised for Version 7.3 (Release R2021a)
September 2021 Online only Revised for Version 7.4 (Release R2021b)
March 2022 Online only Revised for Version 7.5 (Release R2022a)
September 2022 Online only Revised for Version 7.6 (Release R2022b)
Multibody Modeling
Bodies
1
Bodies Workow .......................................... 1-2
Bodies in the Context of a Model ........................... 1-2
Step 1: Study the Bodies to Model .......................... 1-2
Step 2: Model the Solids in Each Body ....................... 1-2
Step 3: Connect the Solids Through Frames ................... 1-3
Step 4: Verify the Body Subsystems ......................... 1-3
Modeling Bodies .......................................... 1-4
Body Elements ......................................... 1-4
Relevant Blocks ........................................ 1-6
Body Visualization ...................................... 1-7
See It: A Typical Body .................................... 1-7
Boundaries of Bodies .................................... 1-9
Bodies as Simulink Subsystems ........................... 1-12
Compounding Body Elements ............................... 1-15
Compounding as a Modeling Strategy ....................... 1-15
Try It: Create a Compound Geometry ....................... 1-15
Try It: Create a Compound Inertia ......................... 1-18
Overview of Flexible Beams ................................ 1-20
Flexible Beam Blocks ................................... 1-20
Beam Geometries ...................................... 1-20
Connection Frames ..................................... 1-20
Deformation Models .................................... 1-21
Material Properties .................................... 1-21
Damping Methods ..................................... 1-21
Discretization ......................................... 1-22
Simulation Performance ................................. 1-22
Deformation Under Gravity ............................... 1-22
Visualization .......................................... 1-23
Working with Frames ..................................... 1-24
Role of Frames ........................................ 1-24
Custom Solid Frames ................................... 1-25
What Are Frame Transforms? ............................. 1-27
Visualizing Frame Transforms ............................ 1-27
Try It: Specify a Frame Transform ......................... 1-28
iii
Contents
Creating Connection Frames ............................... 1-33
Frames as a Connection Points ............................ 1-33
Creating and Transforming Frames ........................ 1-33
See It: Frames in a Typical Body ........................... 1-34
Planning Connection Frames ............................. 1-35
Addressing Assembly Errors .............................. 1-36
Representing Solid Geometry ............................... 1-38
Geometry in a Model ................................... 1-38
Preset Solid Shapes .................................... 1-40
Imported Solid Shapes .................................. 1-41
Compound Solid Shapes ................................. 1-42
Modeling Extrusions and Revolutions ........................ 1-44
Extrusions and Revolutions ............................... 1-44
The Cross-Section Proles ............................... 1-45
Cross-Sections with Holes ............................... 1-47
From Cross-Sections to Solids ............................ 1-49
Model an Excavator Dipper Arm as a Flexible Body ............. 1-51
Visualize a Model and Its Components ....................... 1-58
Visualize a Complete Multibody Model ...................... 1-58
Visualize an Individual Solid Geometry ...................... 1-59
A Note on Imported Geometries ........................... 1-60
Representing Solid Inertia ................................. 1-62
Representing Inertias ................................... 1-62
Compounding Solids and Inertias .......................... 1-66
Specifying Custom Inertias ................................. 1-68
Key Inertia Conventions ................................. 1-68
Inertia Matrix Denitions ................................ 1-68
CAD as an Inertia Data Source ............................ 1-71
Automatic Inertia Calculation ............................. 1-74
Specifying Variable Inertias ................................ 1-76
Modeling Variable Inertias ............................... 1-76
Visualizing Variable Inertias .............................. 1-76
Modeling Body Interactions .............................. 1-77
Model a Variable-Mass Oscillator .......................... 1-77
Creating Custom Solid Frames .............................. 1-82
Solid Frames ......................................... 1-82
Opening the Frame-Creation Interface ...................... 1-83
Geometry-Based Frame Placement ......................... 1-83
Primary and Secondary Axes ............................. 1-83
Try It: Create a Custom Solid Frame ........................ 1-84
Manipulate the Color of a Solid ............................. 1-90
Visual Property Parameterizations ......................... 1-90
RGB and RGBA Vectors .................................. 1-90
Simple Visual Properties ................................. 1-91
Advanced Visual Properties .............................. 1-92
Adjust Solid Opacity .................................... 1-92
iv Contents
Adjust Highlight Color .................................. 1-93
Adjust Shadow Color ................................... 1-93
Adjust Self-Illumination Color ............................. 1-94
Multibody Systems
2
Multibody Assembly Workow ............................... 2-2
Study the Joints and Constraints to Model .................... 2-2
Assemble Bodies Using Joints and Constraints ................. 2-2
Guide Model Assembly ................................... 2-2
Verify Model Assembly ................................... 2-3
Modeling Joint Connections ................................. 2-4
Joint Degrees of Freedom ................................. 2-4
Joint Primitives ......................................... 2-5
Joint Inertia ........................................... 2-6
How Multibody Assembly Works ............................. 2-8
Model Assembly ........................................ 2-8
Connecting Joints ....................................... 2-8
Orienting Joints ........................................ 2-9
Guiding Assembly ....................................... 2-9
Verifying Model Assembly ................................ 2-10
Counting Degrees of Freedom .............................. 2-12
Model an Open-Loop Kinematic Chain ....................... 2-13
Model Overview ....................................... 2-13
Build Model .......................................... 2-13
Guide Model Assembly .................................. 2-14
Visualize Model and Check Assembly Status .................. 2-14
Simulate Model ....................................... 2-15
Open Reference Model .................................. 2-15
Model a Closed-Loop Kinematic Chain ....................... 2-16
Build Model .......................................... 2-16
Specify Block Parameters ................................ 2-18
Guide Assembly and Visualize Model ....................... 2-19
Verify Model Assembly .................................. 2-19
Simulate Model ....................................... 2-20
Troubleshoot an Assembly Error ............................ 2-21
Model Overview ....................................... 2-21
Explore Model ........................................ 2-21
Update Model ......................................... 2-23
Troubleshoot Assembly Error ............................. 2-23
Correct Assembly Error ................................. 2-25
Simulate Model ....................................... 2-25
Modeling Gear Constraints ................................. 2-27
Gear Constraints and Applications ......................... 2-27
v