Upload
maleah-omans
View
215
Download
0
Tags:
Embed Size (px)
Citation preview
INSIA-ETSII-UPM
1/46
Multibody Systems Made Simple and Efficient
J. García de Jalón
IDETC/CIE 2011MSNDC 23-1Washington, USA, 28-31 Aug, 2011
Universidad Politécnica de MadridDept. de Mat. Aplicada and INSIA
José Gutiérrez Abascal 228006 Madrid, Spain
INSIA-ETSII-UPM
2/46
Deo omnis gloria!
Outline of this presentation
History of natural coordinates Acknowledgements Early developments and applications of natural coordinates
- Back to the basics- Multibody simulation plus realistic 3-D graphics- Global formulations: Improving the efficiency- Biomechanics- Flexible multibody systems
Improving the efficiency throughout topological formulations- Rigid multibody systems- Flexible multibody systems
Live demos Conclusive remarks
INSIA-ETSII-UPM
3/46
Aknowledgements
Former PhD students- Rafael Avilés - José Antonio Tárrago- Jorge Unda- Alejandro García-Alonso- Alejo Avello- José Manuel Jiménez- Alejandro Gutiérrez- Jesús Cardenal- Javier Cuadrado- Gorka Álvarez- Antonio Avello- Nicolás Serrano- José Ignacio Rodríguez- Jesús Vidal
Current PhD Students - F. Javier Funes- Andrés F. Hidalgo- Alfonso Callejo- Mª Dolores Gutiérrez
Colleagues- Joaquín Casellas ()- Francisco Tejerizo ()- José María Bastero- Joaquín Aguinaga ()- Miguel Ángel Serna- Juan Tomás Celigüeta- Carlos Vera ()- Francisco Aparicio
INSIA-ETSII-UPM
4/46
Part I: History of natural coordinates
J. García de Jalón
IDETC/CIE 2011MSNDC 23-1Washington, USA, 28-31 Aug, 2011
Universidad Politécnica de MadridDept. de Mat. Aplicada and INSIA
José Gutiérrez Abascal 228006 Madrid, Spain
INSIA-ETSII-UPM
5/46
1.1 How the idea arose
F. Beaufait, Basic Concepts of Structural Analysis, Prentice Hall, 1977
G. Strang and G. Fix, An Analysis of the Finite Element Method, Wellesley-Cambridge Press (1973)
G. Strang, Linear Algebra and Its Applications, Academic Press, First Edition (1976)
INSIA-ETSII-UPM
6/46
Deo omnis gloria!
The beginning of natural coordinates 1/2
1971-77- Lecturer on Structural Analysis and Numerical Methods- Doctoral Thesis on “Finite Element Thermal Stresses in Railways Wheels”
1978-79- Strong pressure to complete in four weeks an original research work on
mechanisms - An idea urgently needed: A mechanism as an unstable structure!
- The stiffness matrix has the same null space as the Jacobian matrix of the constant distance constraint equations
Statically determinateStatically indeterminate Unstable
Kx 0
INSIA-ETSII-UPM
7/46
Deo omnis gloria!
The beginning of natural coordinates 2/2
Mathematical evolution- From minimum elastic potential to minimum constraint violation, and then to
nonlinear constraint equations: constant distances, angles, areas,… Extension to three-dimensional systems (1981)
- Straightforward when only points are considered- Each rigid body has at least three non-aligned points- Revolute joints introduced by sharing two points- Cylindrical joints introduced with four points aligned- High number of points needed
Unit vectors introduced (1984)- Points and unit vectors contribute to define 3-D orientation- A single unit vector may define the direction of several parallel axes- Revolute joints introduced by sharing a point and a unit vector- Cylindrical joints introduced with two points aligned with a shared unit vector- Important size reductions achieved
INSIA-ETSII-UPM
8/46
Deo omnis gloria!
Example 1: Constraint equations of robot ERA
u 3u 2
u1
u 1
1
2
3
45 u1
u 0
21 coordinates and 15 constraints:r2, r3, r4, r5, u1, u2 y u3
2 2 2 22 1 2 1 2 1 12
2 1 1 2 1 1 2 1 1
2 2 21 1 1
1
2 2 2 23 2 3 2 3 2 23
3 2 1 3 2 1 3 2 1
2 2 2 24 3 4 3 4 3 34
3 4 1
0
0Body 2
1 0
0
0Body 3
0
0
Body 4
x y z
x y z
z
x y z
x x y y z z d
x x u y y u z z u
u u u
u
x x y y z z d
x x u y y u z z u
x x y y z z d
x x u
3 4 1 4 3 1
3 4 2 3 4 2 4 3 2
2 1 2 1 2 1
2 2 22 2 2
2 2 2 25 4 5 4 5 4 45
5 4 2 5 4 2 5 4 2
5 4 3 5 4 3 5 4 3
0
0
0
1 0
0Body 5
0
0Body 6
x y z
x y z
x x y y z z
x y z
x y z
x y z
y y u z z u
x x u y y u z z u
u u u u u u
u u u
x x y y z z d
x x u y y u z z u
x x u y y u z z u
2 2 23 3 3 1 0x y zu u u
2
INSIA-ETSII-UPM
9/46
Deo omnis gloria!
Example 2: Robot ERA with mixed coordinates
Natural coordinates allow an easy addition of relative coordinates- Angles and distances in
Revolute and Prismatic joints, respectively, allow a direct introduction of actuator forces.
In the ERA robot, angles have been defined in the following way:- Angle y1 goes from u2 to u5 and it is measured on u1.- Angle y2 goes from u1 to (r2–r1) and it is measured on u2.- Angle y3 goes from (r1–r2) to (r3–r2) and it is measured on u2.- Angle y4 goes from (r2–r3) to (r4–r3) and it is measured on u2.- Angle y5 goes from (r3–r4) to (r5–r4) and it is measured on u3.- Angle y6 goes from u3 to u4 and it is measured on (r5–r4). - Each angle is defined with the dot product of vectors or with the largest
component of the cross product of vectors, according to its value.
u4 u 3
1
2
3
45
u1
u2
u2
u2
Y1
Y2
Y3
Y4
Y5
Y6
u5
INSIA-ETSII-UPM
10/46
Part II: Early developments and applications of natural coordinates
J. García de Jalón
IDETC/CIE 2011MSNDC 23-1Washington, USA, 28-31 Aug, 2011
Universidad Politécnica de MadridDept. de Mat. Aplicada and INSIA
José Gutiérrez Abascal 228006 Madrid, Spain
INSIA-ETSII-UPM
11/46
2.1 Back to the basics: singular mass matrices and redundant constraints
J. García de Jalón and E. Bayo, Kinematic and Dynamic Simulation of Multi-Body Systems: The Real-Time Challenge, Springer-Verlag, New-York (1993).
Udwadia, F. E. and Phohomsiri, P., Explicit Equations of Motion for Constrained Mechanical Systems with Singular Mass Matrices and Applications to Multi-body Dynamics, Proceedings of the Royal Society of London, Series A, 462, pp. 2097-2117, (2006).
J. García de Jalón, Multibody dynamics with redundant constraints and singular mass matrix: Theory and practice, paper in preparation, (2011).
INSIA-ETSII-UPM
12/46
Deo omnis gloria!
Aspects of formulations with natural coordinates
Singular mass matrices arise very often- A constant mass matrix (with no
velocity dependent inertia forces) can be defined with two points and two non coplanar unit vectors.
- If there are more points and vectors their inertia coefficients are null and the mass matrix singular.
Dependent constraint equations are also frequent- for implementation convenience
for instance:- in over-constrained systems
These difficulties need always to bedealt with to find an adequate solution, but, When does this solution exists? Is it unique?
ir
mujr
nu
lu
kr
, j k i j k u u 0 u r r 0
INSIA-ETSII-UPM
13/46
Deo omnis gloria!
Dynamic equations with Lagrange multipliers 1/3
Motion differential equations- Putting together the dynamic equations and all the kinematic constraints:
that is a system of 3N+M differential-algebraic equations of index 3.- It is also possible to set only the dynamic and the acceleration equations:
- Assume matrix M is positive definite and matrix has full rank
- Then,
- These conditions on M and are too restrictive and shall be relaxed
some stabilization necessaryT
q
q
M Φ q F
Φ 0 λ c
T qMq Φ λ F
, = , , t tt q q qΦ q 0 Φ q Φ b Φ q Φ Φ q c
qΦ
1 T qq M F Φ λ
11 1 1 T T q q q q q qΦ q c Φ M F Φ λ c λ Φ M Φ Φ M F c
, , rank , rankT n n m n n m q qM M Φ M Φ
qΦ
INSIA-ETSII-UPM
14/46
Deo omnis gloria!
Dynamic equations with Lagrange multipliers 2/3
Motion differential equations: the rank r of made visible- Index-1 ordinary differential equations may be transformed:
- Matrix M may be singular or semi-definite- Matrix may have redundant constraints:
- By taking into account that matrix is invertible,
- The existence and uniqueness of solutions are studied next.
T
q
q
M Φ q F
Φ 0 λ c
qΦ
r n
LU m mm r n
q
UP Φ L
0
T T Tr n m mm r n
r nLU LU
m m m mm r n
M U 0 Lq F
U P λ P cL 00
1, ,
T Tr n m r n
Tm m LU m m LUr n
m mm r n
M U 0q F
λ L P λ c L P cU λ c00
qΦ
m mL
INSIA-ETSII-UPM
15/46
Deo omnis gloria!
Dynamic equations with Lagrange multipliers 3/3
Dynamic equations: existence and uniqueness of solutions- As has seen, these equations are compatible if is compatible,
- Values for compatibility. Values are arbitrary.- Moreover, if matrix has full rank n, these equations are
determined in the acceleration vector and undetermined in the transformed Lagrange Multipliers In this case, the following matrix is invertible
even if matrix M is not invertible. The QR factorization and the SVD can be applied in a similar way
1, ,
T Tr n m r n
Tm m LU m m LUr n
m mm r n
M U 0q F
λ L P λ c L P cUλ c0
0
q.λ
Tr n M U
qΦ q c
Tr n
r n
M U
U 0
1 ... 0r mc c 1 2, ,...,r r m
INSIA-ETSII-UPM
16/46
Three forms to set and solve the dynamic equations 1/4
Three equivalent formulations- Index 1 Lagrange equations
- Null space method
- Maggi’s method
- The conditions for the existence of a solution are:
T
q
q
M Φ q F
Φ 0 λ c
T T
q
R M R Fq
Φ c
T T T R MRz R F R MSc
qΦ R 0
, q Rz q Rz Sc
rank ker ker def. pos.Tn
q
q
MM Φ 0 R MR
Φ
q
INSIA-ETSII-UPM
17/46
Three forms to set and solve the dynamic equations 2/4
The existence of solutions- By applying the Rouché-Capelli theorem, in order to be able to
express any external force vector as a linear combination of inertia and constraint forces,
- This condition can be transformed into an equivalent one,
which has a more clear physical significance:
“Any physically possible velocity is associated with a non-zero (positive) kinetic energy “
1 rankT n T n q q
qM Φ F M Φ
λ
rank ker kern
q
q q
M M 0x x 0 M Φ 0
Φ Φ 0
ker qq Φ , 0 .T Mq 0 q Mq
INSIA-ETSII-UPM
18/46
Deo omnis gloria!
Three forms to set and solve the dynamic equations 3/4
The existence of solutions (cont.)- For the null space equations, taking into account that
But matrix M is positive-semidefinite, so
Assume vector x belongs to the null spaces of and
and the previous condition is obtained.
,qΦ R 0
, rank ker kerT TT
Tn
q
q q
R M R MR Fq R M Φ 0
Φ Φc
, rank rank ker kerT M P P M P P M
1ker ,
0ker
f
T T T
T T
qx Φ x Rz zR MRz 0 z R MRz
x R M R Mx 0
2
2 ker kerT T T T T z R MRz z R P PRz PRz 0 Rz P x M
qΦ ,TR M
ker ker qM Φ 0
INSIA-ETSII-UPM
19/46
Deo omnis gloria!
Three forms to set and solve the dynamic equations 4/4
The existence of solutions(cont.)- For the Maggi’s equations
The accelerations and are determined if matrix is positive-definite.
This condition can be written as,
Any vector cannot belong to Thus,
The positive-definiteness of has a physical meaning:
“Any physically possible velocity is associated with a positive kinetic energy “
, T T T R MRz R F R MSc q Rz Sc
z q TR MR
2
2 ker kerT T T T T z R MRz z R P PRz PRz 0 x Rz P M
ker , , qx Rz Φ x 0 ker .M
ker ker qM Φ 0
, T T r z R MRz 0 z z 0
ker , qq Φ q Rz
TR MR
2 0, .T T TT q Mq z R MRz z 0
INSIA-ETSII-UPM
20/46
Deo omnis gloria!
The uniqueness of solutions
Assume the conditions for the existence are fulfilled,
- The uniqueness of the acceleration is better studied with the null space formulation
- As the columns are independent, the solution is unique, even if there are redundant constraints
- Also is unique if matrix is definite-positive- In the Lagrange equations of the first kind and are unique,
but the multipliers are not if there are redundant constraints
- The resultant constraint forces are unique, but the particular are not
rank rank ker ker def. pos.T
Tn
q
q q
M R MM Φ 0 R MR
Φ Φ
, rank rankT TT
n
qq q
MR M R MR Fq
ΦΦ Φc
q
q
z TR MR
, , rankT
T T n m T r m
qq q q
q
M Φ q FΦ λ F Mq Φ Φ
Φ 0 λ c
q TqΦ λ
λ
INSIA-ETSII-UPM
21/46
Deo omnis gloria!
Redundant constraints and constraint forces
Assume the MBS is over-constrained and constraint forces are to be determined- Remember is determined
but is not. Then
- The individual constraint forces are
that are not determined. General and minimum norm solution of
- The general solution is where is the minimum norm solution and is a vector in
- The important point is that is a set of self-equilibrating constraint forces (see examples)
- This minimum norm solution can be computed from the system of equations:
TqΦ λ
λ
,T qΦ λ F q q Mq
1:,1 :,T T Tmm q q qΦ λ Φ Φ
T qΦ λ f
0 , ,m r λ λ Nα α 0λNα ker T
qΦTqΦ Nα
0
T
T
qfΦ
λ0N
kerA11 1 12 2 0a x a x
Im TA
x
u0x
px
11 1 12 2 1a x a x b Ax b
INSIA-ETSII-UPM
22/46
Example 1: 2-D double quad
Over-constrained system- Bar 5-6 can be removed
without changing the kinematics of the motion
- The system cannot be assembled if unless bars are stretched
- The minimum norm solution makes the self-equilibrating forces null
Set of self-equilibrating constraint forces
Constraint forces for the three constant distances
1 2
3 4
5 6
34 56 ,L L
0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1-100
-80
-60
-40
-20
0
20
40
60
80
100Constraint force in rods 1 (red), 2 (green) and 3 (blue)
time
For
ce
12 34 56, ,L L L
INSIA-ETSII-UPM
23/46
Example 2: 8-link spatial parallelogram
Frączek & Wojtyra, ECCOMAS Warsaw (2009)
Platform 1-2-3-4 and bars modeled with natural coordinates- 6 rigid body dofs, 6 constant distance
conditions and 1 final constrained dof- The figure shows the set of self-
equilibrating constraint forces - The force systems in red and in blue
must self-equilibrate separately- The forces in blue can not self-
equilibrate, and so they are null (proved algebraically by Frączek & Wojtyra)
K
M5
6
4
32A
C E
1
G
INSIA-ETSII-UPM
24/46
Deo omnis gloria!
Example 3: 3-D four bar system
3-D four-bar with 3 self-equilibrating sets of constraint forces
INSIA-ETSII-UPM
25/46
2.2 Multibody simulation withrealistic 3-D graphics
J. García de Jalón, A. García–Alonso and N. Serrano, "Interactive Simulation of Complex Mechanical Systems", Eurographics'93, Barcelona, 1993.
G. Álvarez, A. García-Alonso, P. Urban, N. Serrano and J. García de Jalón, "Biomechanics: Dynamics & Playback", video presented in SIGGRAPH’93, Annual Conference Series, ISBN 0-89791-602-6, Anaheim CA, USA, 1993.
INSIA-ETSII-UPM
26/46
Animated CG essential to understand MBS
Computer plots used from 1979 Tektronix 4114 y 4115 for
monochrome vector animations since 1982
Workstation HP 320SRX with realistic graphics since 1987- Motorola 69020 processor plus
3-D graphics accelerator- Some examples presented in the VII
IFTóMM World Congress on the Theory of Machines and Mechanisms, Seville, September, 17-22, 1987
Silicon Graphics 4D/240GTX since 1989- Four MIPS 3000 processors
Since 1987 computer graphics produced an interest boom on interactive or even real-time multibody systems
INSIA-ETSII-UPM
27/46
Some MBS animations from the late 80s
Some of the first examples - Kinematics of
steering and suspension systems
- Complete model of a truck
- Kinematic deployment of an antenna
- Space dynamic maneuver
INSIA-ETSII-UPM
28/46
2.3 Global formulations: Improving the efficiency
R. von Schwerin, “Multibody System Simulation: Numerical Methods, Algorithms and Software”, Springer, 338 pages, 1999.
J. Cuadrado and D. Dopico, “Penalty, semi-recursive and Hybrid Methods for MBS Real-Time Dynamics in the Context of Structural Integrators”, MULTIBODY DYNAMICS 2003, Jorge A.C. Ambrósio (Ed.), IDMEC/IST, Lisbon, Portugal, July 1-4 2003
INSIA-ETSII-UPM
29/46
Deo omnis gloria!
von Schwerin’s Formulation 1/3
Main characteristics- Natural coordinates are used for the system of linear equations- Two methods are considered to solve this system: RSM and NSM- The problem is assumed non-stiff and the index 1 DAE system is integrated
with a special ABM integrator based on the solution of the inverse dynamics that does not need the derivative of the state vector.
- Instead of using a predictor-corrector formula, von Schwerin enforces the discretized dynamic equations by a modified Newton-Raphson iteration, with an approximate tangent matrix that can be kept for many time steps. At the end, it is possible to obtain a O(n) method based on the descriptor form.
- The index 1 DAE system is stabilized for positions and velocities by using two mass-orthogonal projection with the aforesaid tangent matrix
- The efficiency can be further improved by considering the system topology through a distinction between the closure of the loop constraints and all the remaining constraints.
This method seems to have been discontinued in the bibliography
T
q
q
M q F
0 c
INSIA-ETSII-UPM
30/46
Deo omnis gloria!
The Range Space method (RSM)
An LDLT factorization is assumed and then computed- Factorization step (M and assumed full rank matrices)
- Substitution step
- This method takes into account the matrix symmetry and doesn’t need complicated pivoting strategies
1 1 21 1 1 1 21
21 2 2 21 1 21 21 2 2
T T T T Tm
T T T Tf
q
q
I 0M L 0 L L L L L L0 I0 L L 0 L L L L L L L
11 21 1 2 21 21chol , , cholT T T qL M L L L L L
1 1 21 1 21
21 2 2 2
, T T T T
m m
T Tf f
I 0 I 0L 0 q F x qL L L L0 I 0 IL L λ c μ λ0 L 0 L
1 212 1 21
2
\ , \T T
T T T
T
q xL Lλ L μ q L x L λ
λ μ0 L
11 2 21
21 2
\ , \
L 0 x Fx L F μ L c L x
L L μ c
q
INSIA-ETSII-UPM
31/46
Deo omnis gloria!
The Null Space method (NSM)
A transformation based on a null space basis R of is applied- The constraint equations for velocities and accelerations allow a
transformation based on the null space basis R,
- The accelerations can be computed from the equations
, ,
, ,, , , ,
, d i d i d dd
n n n m
iiim n m mf m f f f m f f f
q q q qq
I 0Φ Φ Φ Φ S RcqΦ q b
0 I0 I 0 I S Iqq
1
1 1
iT i T
dT dd d dT di id d ii i dT d i dT dd ii d
d d i i di
q
q q q
R MRq R F MSc
R M R R M M R M q R F F R M M Φ c
q Φ Φ q Φ c
qΦ
1 1 1
, ,
1
, ,
d i d d id d di
i i ii i if m f f f
d i d ddi
iif m f f f f m
q q q q q
q q
Φ Φ b b bΦ Φ Φq S Rq Sb Rq
0 I q q qq S R 0 I
Φ Φ R Scqq q
0 I I 0qq
1
1, i
d d i
i
d d
q q
q 0
q
R Φ Φc Rq Sc Sc q
S Φ
INSIA-ETSII-UPM
32/46
Deo omnis gloria!
The RSM and NSM complexities compared
von Schwerin presented a theoretical study of the complexity of solving the descriptor system of equations using the three methods, depending on the relationship between the number of constraints m and the number of dependent coordinates n.
His findings are very significant and interesting:- For m/n > 0.63 the NSM is more efficient than the RSM. It is also more efficient
for m/n > 0.69 when matrix M is constant and the RSM takes advantage of this circumstance.
- When the ratio m/n is close to 1 (strongly constrained systems with very few degrees of freedom), the NSM requires 7 times less arithmetic operations than the Gauss method, and 3.5 times less operations than the RSM (2.5 if matrix M is constant).
- In the worst circumstances (m/n small and matrix M constant), the NSM never requires more than 15% of additional operations with respect to the RSM.
These results justify the superiority of the methods based on independent coordinates, which are equivalent to the RSM.
INSIA-ETSII-UPM
33/46
Deo omnis gloria!
Augmented Lagrangian (Cuadrado and Dopico) 1/4
Description of the multibody formalism- Based on natural coordinates (dependent) plus angles and distances.- Index-3 augmented Lagrangian equations with generalized- method.
- Newmark equations to approximate velocities and accelerations.
- Nonlinear system of equations:
1 1
1 12 2
ˆ ˆ ; 1 12
1 1 1 1ˆ ˆ ; 12
n n n n n n n
n n n n n n n
hh h
hh h
g g g gb b b b
b bb b
+ +
+ +
ì üæ ö æ öï ï÷ ÷ï ïç ç= + = - + - + -÷ ÷í ýç ç÷ ÷ç ç÷ ÷ç çï ïè ø è øï ïî þæ öæ ö ÷ç ÷ç ÷= + = - + + - ÷ç ç ÷÷ç ç ÷ ÷çç è øè ø
q q q q q q q
q q q q q q q
& & & & &&
&& && && & &&
( )t h+ =f q 0
( ){ } ( ) ( ){ }( ){ }
*1
1*
1 1 Tm n m n f
nT
fn
d d d
d
++
- + + - + -
+ + - =
q
q
M q q Φ αΦ λ Q
Φ αΦ λ Q 0
&& &&
1 1i i i+ += +λ λ αΦ
INSIA-ETSII-UPM
34/46
Deo omnis gloria!
Augmented Lagrangian (Cuadrado and Dopico) 2/4
Description of the multibody formalism (cont.)- Solution of the nonlinear system by the Newton-Raphson method
where
( )( )1 1 1;
iii i i i
t h t h t h t ht ht h
+ + ++ + + ++
+
é ù¶ê ú é ùD = - = +Dê ú ê úë û¶ê úë û
f qq f q q q q
q
( ) ( ){ } ( ) ( ){ }( ){ }
2 *1
1
*
1 1 Tm n m n f
n
Tf
n
hb d d d
d
++
é= - + + - + -ê
êëù
+ + - =úúû
q
q
f q M q q Φ αΦ λ Q
Φ αΦ λ Q 0
&& &&
( ) ( ) ( ) ( ) ( )2 T1 1
1 1 1m f n f nh hd d g d b+ +
é ù¶ê ú@ - + - + - +ê ú¶ê úë ûq q
f qM C Φ αΦ K
q
,¶ ¶
= - = -¶ ¶Q Q
Κ Cq q&
INSIA-ETSII-UPM
35/46
Deo omnis gloria!
Augmented Lagrangian (Cuadrado and Dopico) 3/4
Description of the multibody formalism (cont.)- Projections of velocities and accelerations onto their constraint manifolds.
where
,¶ ¶
= - = -¶ ¶Q Q
Κ Cq q&
( ) ( )* 21 Tf thd b
é ù¶ê ú = - -ê ú¶ê úë ûq
f qq Pq Φ αΦ
q& &
( ) ( ) ( ) 21 11 1 1m f n f nh hd d g d b+ += - + - + -P M C K
( ) ( ) ( )* 21 Tf thd b
é ù¶ê ú = - - +ê ú¶ê úë ûq q
f qq Pq Φ αΦ q Φ
q& &&& && &
INSIA-ETSII-UPM
36/46
Deo omnis gloria!
Augmented Lagrangian (Cuadrado and Dopico) 4/4
Implementation details- Sparse matrix techniques:
- CS: Coordinate format (MA27, MA57)- CCS: Compressed column format (Cholmod, KLU)
- Constant mass matrices and gravity forces in rigid-body case- Analytical evaluation of Jacobians of forces easy to obtain (spring-damper,
contact, tire, brake, etc.)- Usually symmetric positive-definite tangent matrices- Integration step-sizes attainable: stable with very large step sizes, problems
with very small step sizes (bad condition number)- Able to modify the system in real-time: adding (removing) bodies (constraints)
Conclusions on the efficiency obtained- Real time for systems with sizes of more than 1000 coordinates
- Assembly of four–bar linkages with “n” loops, CCS, h=1e-3, AMD Athlon 64.- Excavator simulator (152 coordinates): about 5 times faster than RT
- CS, h=5e-3, ASUS U6V laptop computer Intel Core 2 Duo.
INSIA-ETSII-UPM
37/46
2.4 Biomechanics
ABAT’92 project: Análisis Biomecánico de Alta Tecnología (1988-1992) G. Álvarez, A. García-Alonso, P. Urban, N. Serrano and J. García de
Jalón, "Biomechanics: Dynamics & Playback", video presented at SIGGRAPH’93, Anaheim CA, USA, 1993.
G. Alvarez, A. Gutiérrez, N. Serrano, P. Urban and J. García de Jalón, "Computer Data Acquisition, Analysis and Visualization of Elite Athletes Motion", VIth International Symposium on Computer Simulation in Biomechanics, Paris, France, 1993.
INSIA-ETSII-UPM
38/46
Natural coordinates and biomechanics
Step 1: Motion capture: points model - Using several synchronized cameras- Manual or automatic digitalization- 3D coordinates determination with
optional filtering Step 2: Data conditioning: consistent
MBS model- Definition of rigid bodies and joints- Consistent MBS model: natural
coordinates- Evaluation of relative angles and filtering
Step 3: MBS simulation- Kinematic simulation- Direct dynamic simulation- Inverse dynamic simulation
INSIA-ETSII-UPM
39/46
2nd step: MBS model of the human body 1/3 The HUMAN BODY model
- Figure shows a typical multi-rigid-body model of the human body, including 37 degrees of freedom.
- The hip body (consisting of center, right and left points, and three unit vectors) is taken as the base body, in order to show easily the rigid body motions.
Natural coordinates- This model has 30 points (27 movable) and
23 unit vectors (20 movable).- The relative coordinates are the angles
between the different bodies.- So, this human body model has 37 degrees
of freedom and 141 dependent coordinates.
INSIA-ETSII-UPM
40/46
2nd step: MBS model of the human body 2/3 Example: definition of a leg:
- Points 9, 25 and vectors 15, 16 are a rigid body:
- Points 25, 26 and vectors 16, 17 are a rigid body:
- Points 26, 27 and vectors 17, 18 are a rigid body:
- Sometimes foot twist is restricted:
226 27 26 27 26,27
17 26 27
18 26 27
( )( ) 0
( ) 0
( ) 0
T T
T
T
d
r r r r
u r r
u r r
17 18 0 u u
29 25 9 25 9,25
15 9 25
16 9 25
( )( ) 0
( ) 0
( ) 0
T T
T
T
d
r r r r
u r r
u r r
225 26 25 26 25,26
16 25 26
17 25 26
( )( ) 0
( ) 0
( ) 0
T T
T
T
d
r r r r
u r r
u r r
9
25
26
u5
u16
10
5
27
u17
u15
u18
INSIA-ETSII-UPM
41/46
2nd step: MBS model of the human body 3/3
Relative coordinates used to control the 6 degrees of freedom:- goes from to measured on- goes from to
measured on - goes from to measured on - goes from to
measured on - goes from to measured on
- goes from to measured on
Angle definition constraints:- Angle from to measured on
- Angle from to measured on
( ) ( ) sin( )j i l k m ij klL L y r r r r u 0
( )sin( )l k
i jklL
y
r ru u 0
9
25
26
u5
u16
10
5
27
u17
u15
u18
27y
28y
29y
30y
31y
26y 5u 15u
27y 10 9( )r r15u
15u 16u
25 9( )r r
25 9( )r r
26 25( )r r 9 25( )r r
27 26( )r r25 26( )r r
17u16u16u
28y29y
30y
31y
19 10( )r r
mu
26 25( )r r
17u
( )j ir r ( )l kr r
( )l kr riu ju
INSIA-ETSII-UPM
42/46
Deo omnis gloria!
3rd step: Kinematic and dynamic simulation
Kinematic simulation- After conditioning, the consistent model with the recorded
motion is visualized with realistic graphics from several fixed or moving cameras
- If necessary, new frames are obtained by interpolation Inverse and direct dynamic simulation
- The inertia properties of the athlete’s members are obtained from anthropometric data tables
- Knowing the motion as a function of time, the external reaction and internal motor-constraint forces can be computed and visualized
INSIA-ETSII-UPM
43/46
Deo omnis gloria!
Barcelona’ 1992 Olympic Games 1/4
ABAT’92 Project: Análisis Biomecánico de Alta Tecnología (1988-1992)- Developed with CAR (High Performance Sport Training Center)- Research project aimed at the multibody analysis of athletes, using the
latest technologies in data capturing, analysis of motion and computer graphics
Two sports were studied: athletics and gymnastics Working procedure
- The trials were recorded in the afternoon- The images were manually digitized during the night- The digitized data was conditioned, produced and recorded in the
morning- The resulting images were broadcast at midday news services (too
late…) Some broadcast images will be shown next
- Gymnastics, high jump and long jump
INSIA-ETSII-UPM
44/46
Deo omnis gloria!
Barcelona’ 1992 Olympic Games 2/4
Gymnastics
INSIA-ETSII-UPM
45/46
Deo omnis gloria!
Barcelona’ 1992 Olympic Games 3/4
High jump: Javier Sotomayor
INSIA-ETSII-UPM
46/46
Deo omnis gloria!
Barcelona’ 1992 Olympic Games 4/4
Long jump: Lewis vs. Powell
INSIA-ETSII-UPM
47/46
Deo omnis gloria!
Biomechanics and natural coordinates today 1/3
STT Ingeniería y Sistemas Automatic data capturing
- Gait analysis- Bull fighter- Golf
Manual data capturing- Gymnastic 1- Gymnastic 2
INSIA-ETSII-UPM
48/46
Deo omnis gloria!
Biomechanics and natural coordinates today 2/3
Kinematic Motion Reconstruction (KMR) at CEIT Optimization process
- The quadratic error between the experimental and theoretical position of the markers, subjected to the kinematic constraint equations, is minimized
In the next video we will see:- Red spheres ( ) in the center of joints, - Blue spheres ( ) in the model points associated to markers - Green spheres ( ) to represent marker’s position experimentally measured
The error between blue and green spheres is minimized subjected to the constant distance condition between blue and red spheres
Over-determined and under-determined problems- There is over-determined information when more points or more cameras
than necessary are used for a body- On the other hand, there is for instance an under-determined problem when a
body has fewer than necessary points or they are hidden for some cameras
INSIA-ETSII-UPM
49/46
Deo omnis gloria!
Biomechanics and natural coordinates today 3/3
A CEIT’s REALMAN example: A driver enters and exits a vehicle
INSIA-ETSII-UPM
50/46
2.5 Flexible multibody systems
J. García de Jalón and E. Bayo, Kinematic and Dynamic Simulation of Multi-Body Systems: The Real-Time Challenge, Springer-Verlag, New-York (1993).
J. Cuadrado, J. Cardenal and J. García de Jalón, Flexible Mechanisms Through Natural Coordinates and Component Synthesis: An Approach Fully Compatible with the Rigid Case, International Journal for Numerical Methods in Engineering, Vol. 39, pp. 3535-3551, (1996).
INSIA-ETSII-UPM
51/46
Deo omnis gloria!
Moving frame approach with natural coordinates
The classical moving frame approach separates the large rigid body motion and the small elastic deformations respect the moving frame- The elastic deformations are expressed as a linear combination of
a reduced set of static and dynamic modes Natural coordinates provide a simple way to define
boundary conditions for the static modes- The elastic static modes can be considered as the relaxation of
one or more rigid body constraint equations- It is not necessary to consider all the possible static nodes. Those
considered as irrelevant may be kept as constraint equations- It is not necessary to consider the amplitude of the static modes
so defined: they can be computed from the natural coordinates
INSIA-ETSII-UPM
52/46
Static modes coming from a point displacement
There are three static modes related to the displacement of point
The static modal amplitudes can be defined as
0r 1r
u
v
w
1v
2v
1 0 1T
r n η A r r r
1r
INSIA-ETSII-UPM
53/46
Static modes coming from a point rotation
There are three static modes related to the infinitesimal rotations of vectors and
The modal amplitudes are obtained from
rx ry rz G I u v w
A v GvTn1 1
A v GvTn2 2
0r 1r
u
v
w
1v
2v
1v 2v
INSIA-ETSII-UPM
54/46
Deo omnis gloria!
A possible selection of static modes
A revolute joint on the right hand side allows a free rotation respect to the joint axis
Only two rotational and one translational static modes are considered
INSIA-ETSII-UPM
55/46
Part III: Improving the efficiency throughout topological formulations
J. García de Jalón
IDETC/CIE 2011MSNDC 23-1Washington, USA, 28-31 Aug, 2011
Universidad Politécnica de MadridDept. de Mat. Aplicada and INSIA
José Gutiérrez Abascal 228006 Madrid, Spain
INSIA-ETSII-UPM
56/46
3.1 Semi-recursive formulation basedon a double velocity transformation
J.I. Rodríguez (2000), PhD Dissertation (in Spanish). J. I. Rodríguez et al., Recursive and Residual Algorithms
for the Efficient Numerical Integration of Multi-Body Systems, Multibody System Dynamics, 11, pp. 295-320, (2004).
J. Cuadrado et al., A combined Penalty and Recursive Real-Time Formulation for Multibody Dynamics, ASME Journal of Mechanical Design, pp. 602-608 (2004).
INSIA-ETSII-UPM
57/46
Deo omnis gloria!
Open-chain topology: path matrix
Path matrix T- Rows correspond to rigid bodies.- Columns correspond to joints.- Tij = 1 if body i is upwards of joint j.
Otherwise Tij = 0. Column i of T:
- Defines the bodies that are upwards of joint i.
Row j of T:- Defines the joints that are
downwards of body j. Numbering of joints and bodies
- Each rigid body has the same number as its input joint.
- Bodies and joints are numbered from the leaves to the root.- Matrix T is upper triangular.
1z3z
2z 4z
5z
1
2
3
4
5
6 6 6 6 6
6 6 6 6 6
6 6 6 6 6
6 6 6 6 6
6 6 6 6 6
1 1 0 0 1
0 1 0 0 1
, 0 0 1 1 1
0 0 0 1 1
0 0 0 0 1
I I 0 0 I
0 I 0 0 I
T T 0 0 I I I
0 0 0 I I
0 0 0 0 I
INSIA-ETSII-UPM
58/46
Deo omnis gloria!
Geometry and position
The bodies’ geometry is defined through natural coordinates.
The position of each body is defined by the Cartesian coordinates of a point and the rotation matrix.
All the joints are defined as a combination of revolute (R) and prismatic (P) joints.
ri
gi
X Y
Z
1iX
i–1
i
1iY
1iZ
iY iX
iZ
1ir
ir
1ip
iu
X Y
Z
1iX
i–1
i
1iY
1iZ iY
iX
iZ
1ir
ir
1ip
iu
1i id
R P
INSIA-ETSII-UPM
59/46
Deo omnis gloria!
Cartesian velocities and accelerations
Cartesian velocities and accelerations:- According to the point of the solid chosen as reference:
Center of gravity Point at the origin of global axis
- Simple relationships between them:
- Recursive Cartesian velocities and accelerations (open-loop systems):
- Matrix and vectors and depend on the joint type between elements i and i−1. For instance, with Z velocities:
, i ii i
i i
s sZ Z
ω ω
3 3
3 3
,
i i i i i i i i ii i i i i i i
i i i i
g I g s g I g s ω ω gY D Z Y D Z e
ω 0 I ω ω 0 I ω 0
1
1
i i i i
i i i i i
z
z
Z Z b
Z Z b d
1
1
i i i i i
i i i i i i
z
z
Y B Y b
Y B Y b d
, i ii i
i i
g gY Y
ω ω
iB , ,i i ib d b
11
1
22, ; ,
i i i i i iR R i i i i i i P Pj j j j
i i i i
s
r u u ω uω u r ub d b d
u 0 0ω u
id
INSIA-ETSII-UPM
60/46
Deo omnis gloria!
1st velocity transformation (open-chain)
Transformation from Cartesian to relative coordinates- Cartesian velocities Z
are dependent and can be obtained from the relativeindependent velocities:
- Column i of matrix R contains the Cartesian velocities produced by a unit input velocity in joint i andnull velocities in the rest of the joints.
- All the bodies upwards of joint i have the same Cartesian velocity bi (the same vector that appeared in ).
- For the whole open-chain system:
1 0z 3 0z
2 1z 4 0z
5 0z
1
2
3
4
5
1 1 2 2 ... n nz z z Z Rz R R R
1 2 5 6 6 1
2 5 6 6 6 2
6 13 4 5 6 6 3
4 5 6 6 6 4
5 6 6 6 6 5
0 0 0 0 0 0
0 0 0 0 0 0 0
, 00 0 0 0 0 0
0 0 0 0 0 0 0
0 0 0 0 0 0 0 0
d
6 6 6
6 6
6 6 6
6 6
6
b b b I I 0 0 I b
b b 0 I 0 0 I b
R TR 0b b b 0 0 I I I b
b b 0 0 0 I I b
b 0 0 0 0 I b
1i i i iz Z Z b
INSIA-ETSII-UPM
61/46
Deo omnis gloria!
Open-chain motion differential equations 1/2
Newton-Euler equations for each solid- Cartesian velocities and accelerations Y and Z can be used:
- By applying the Virtual Power Principle to the complete system:
- Introducing now the 1st velocity transformation:
in the virtual power equation, the following ODE system is obtained:
where t are the forces/torques applied in the joints.- These equations are further developed in the next slide.
, , i ii i i i i
i i i i i
m
3I 0 FM Y Q M Q
0 J n ω J ω
1 2 1 2 1 2diag , ,..., , , ,..., , , ,..,T T T T T T T Tn n n M M M M Q Q Q Q Z Z Z Z
0T Z MZ Q
, d d d Z Rz TR z Z TR z TR z
T T T Td d d d R T MT R z τ R T Q MTR z
, , i i iT Ti i i i i i i i i i i i
i i i i i i
m m
m m
3I gM Z Q M = D M D = Q D Q M e
g J g g
INSIA-ETSII-UPM
62/46
Deo omnis gloria!
Open-chain motion differential equations 2/2
Motion differential equations with relative coordinates:- The motion equations are:- By substituting matrices Rd and T from the previous example:
- Notice that the LU factorization will not destroy the zeroes-pattern.- For external and velocity dependent inertia forces:
- In both cases the accumulation of inertias and forces becomes very explicit. The path matrix T plays a fundamental role.
1 1 1 1 1 2 1 1 5
2 1 1 2 2 2 2 2 5
3 3 3 3 3 4 3 3 5
4 3 3 4 4 4 4 4 5
5 1 1 5 2 2 5 3 3 5 4 4 5 5 5
T T T
T T T
T T TT T Td d d d
T T T
T T T T T
b M b b M b 0 0 b M b
b M b b M b 0 0 b M b
R T MTR R M R0 0 b M b b M b b M b
0 0 b M b b M b b M b
b M b b M b b M b b M b b M b
1 1
2 2 1
3 3
4 4 3
5 5 2 4
M M
M M M
M M
M M M
M M M M
1 1
2 2
3 3
4 4
5 5
, T Td
Q P
Q P
Q T Q P T MTR zQ P
Q P
Q P
1 1
2 2 1
3 3
4 4 3
5 5 2 4
Q Q
Q Q Q
Q Q
Q Q Q
Q Q Q Q
1 1 1
2 2 12
3 3 3
4 4 34
5 5 2 45
d
d
d
d
d
P M TR z
P M TR z P
P M TR z
P M TR z P
P M TR z P P
T T T Td d d d R T MT R z τ R T Q MTR z
INSIA-ETSII-UPM
63/46
Deo omnis gloria!
Closed-chain differential equations 1/2
Closed-chain equations are obtained in two steps:- First, the loops are opened by removing some joints or special bodies (rods).- Second, the constraints are introduced by an appropriate method: Lagrange
multipliers, penalties, augmented Lagrangian or a 2nd velocity transformation The constraint equations are formulated in the simplest
way through natural coordinates:
1z3z
2z4z
5z
1
2
3
4
4
ju ku
jr kr
1z3z
2z4z
5z
1
2
3
4
5
3 independent equationsj k r r 0
only 2 independent equationsj k u u 0 2 0
T
j k j k jkl r r r r
INSIA-ETSII-UPM
64/46
Deo omnis gloria!
Closed-chain differential equations 2/2
Closure of the loop constraint equations- The Jacobian matrix in relative coordinates can be computed as:
- By using the coordinate partitioning method:
- Introducing in the motion equations:
- The parenthesis of this expression can be written as:
; 2 , 2
j j T T T Tk kj k j kj k j k j kz r r r r r r
r rr rΦ Φ Φ Φ Φ Φ r r Φ r r
z z z z
& && &
1,
dd i d d i i
i
z z z z
zΦ Φ 0 z Φ Φ z
z
1 1
, , d d i d i
i i
i
z z z zz z
z Φ Φ Φ Φz R z z R
z I I
i i z zz R z R z
T T i T T T T T T id d d d d d
z z z z z zR R M R R z R τ R R Q R R T MT R z R R z
di i i i id d d d d d
d
dt z
z z z z z
R RR z R R z R R z R R z R R R R z z
0
, , i
d di i i id d d
d d
dt dt z z
z z z
R R R RZ Rz TR z TR R z Z TR R z T z T z Z
INSIA-ETSII-UPM
65/46
Deo omnis gloria!
Closed-chain equations with penalties 1/2
The closed-chain constraints are applied for the open-chain relative coordinates as in Cuadrado and Dopico- By using the penalty method for positions the following system of differential
equations is obtained
- These equations are integrated by the HHT implicit method
- The Newmark’s expressions are assumed for velocities and accelerations
- By substituting in the HHT equations, the following nonlinear system of equations is obtained
, ,T zM z z = Q z z Φ z αΦ z Q z z
( ) ( ) ( )1 1 11 , ,n n f fn n
M z Q z z Q z z = 0d d+ + +- - -&& & &
1 1
1 12 2
ˆ ˆ; 1 12
1 1 1 1ˆ ˆ; 12
n n n n n n n
n n n n n n n
hh h
h h h
+ +
+ +
æ öæ ö æ ö ÷ç ÷ ÷ç ç ÷= + = - + - + -÷ ÷ç ç ç ÷÷ ÷ç ÷ ÷ç ç ÷ç è ø è øè ø
æ öæ ö ÷ç ÷ç ÷= + = - + + - ÷ç ç ÷÷ç ÷ç ÷ç è øè ø
z z z z z z z
z z z z z z z
& & & & &&
&& && && & &&
g g g gb b b b
b b b b
2 2 21 1 1 1 1
ˆ( ) (1 )n n n n n f n f nh h hb d b d b+ + + + += + - - - =f z M z M z Q Q 0&&
INSIA-ETSII-UPM
66/46
Numerical examples3.2 Numerical examples
(semi-recursive formulation)
INSIA-ETSII-UPM
67/46
Coach
15 dof 33 bodies (14 auxiliary) 34 joints 11 rods Closed loops opened by
removing:- 2 spherical joints- 11 rods
INSIA-ETSII-UPM
68/46
IVECO van
17 dof 43 bodies (17 auxiliary) 47 joints 4 rods Closed loops opened by
removing:- 4 rods- 2 spherical joints- 3 revolute joints
INSIA-ETSII-UPM
69/46
Semi-trailer truck
40 dof 5 axles 81 bodies (34 auxiliary) 89 joints Closed loops opened
by removing:- 1 spherical joints- 8 revolute joints
INSIA-ETSII-UPM
70/46
Computation times (explicit RK4 integrator) [s]
Algorithm Step
Coach Semi-trailer truck
Time step: 1x10-3 s Time step: 2.5x10-5 s
C++ BLAS SPARSE C++ BLAS SPARSE
0.276 0.279 0.276 26.410 26.361 26.436
0.120 0.215 0.408 18.071 32.926 28.763
0.355 0.183 0.089 223.253 29.733 28.228
0.122 0.133 0.200 13.360 14.647 7.671
0.193 0.192 0.182 13.861 13.849 14.126
0.151 0.143 0.100 12.972 9.925 9.371
0.087 0.086 0.637 8.638 8.543 9.080
0.649 0.606 0.637 151.284 73.521 73.715
0.073 0.074 0.083 13.696 13.765 13.927
Elapsed time [s] 2.026 1.912 2.461 481.543 223.27 211.316
, , , ,
j i i i i i ij i
b A J M M M M
, [ , ] lud i d z z zΦ Φ L U Φ
1d iz z
z
Φ ΦR
I
1, recVel: , ,d d i i
i i i
z zz Φ Φ z Z d d
, ,i i iQ Q τ
, \d z z z zc Φ z R z Φ Φ z
recAccel: , , iZ Q Q
T Td d
T T T id d d d
z z
z z
M R R M R Rb R R Q R M R z R R z
, , , ,\ , d d d d g g g g d d g g gz M M z b M z M z
INSIA-ETSII-UPM
71/46
Computation times (Implicit method) [s]
Algorithm Step
Iveco van Semi-trailer truck
Time step: 5x10-3 s Time step: 5x10-3 s
Serial TBB Serial TBB
0.001 0.001 0.001 0.001
0.153 0.194 0.193 0.236
0.333 0.115 1.748 0.243
4.437 1.581 9.199 2.802
0.028 0.033 0.081 0.096
0.179 0.164 0.674 0.706
Convergence evaluation 0.001 0.001 0.002 0.002
Velocities projections 0.019 0.020 0.072 0.073
Accelerations projections 0.013 0.014 0.030 0.031
Elapsed time [s] 5.162 2.122 11.999 4.191
0z
,K Q z C Q z
( 1) 1 1\
k kkn n n
z f(z) z f(z)
Tz zΦ Φ
1
k
nf(z) z
, , , , ,zM(z) Φ(z) Φ (z) Q(z z) f(z)
INSIA-ETSII-UPM
72/46
Computation times
Slalom manoeuvre (15 s) Without graphics MATLAB graphics 3D graphics
Coach 16.31 1440 19.17
FSAE racing car 31.12 1419 43.86
15 s simulation time Intel Core 2 Duo 1.8 GHz, GeForce 8
INSIA-ETSII-UPM
73/46
3.2 Semi-recursive formulation for flexible bodies: method of the 24 constant matrices
F.J. Funes and J. García de Jalón, Simulation of Flexible Multibody Systems Based on Recursive Topological Methods and Modal Synthesis, ECCOMAS Multibody Dynamics 2009, Warsaw, Poland.
F.J. Funes and J. García de Jalón, Efficient Simulation of Complex Flexible Multibody Systems Based on Recursive Methods and Implicit Integrators, ECCOMAS Multibody Dynamics 2011, Brussels, Belgium.
INSIA-ETSII-UPM
74/46
Deo omnis gloria!
Objectives
Motivation and objectives- To present a work in progress to analyze large size, real-life flexible multibody
systems - This formulation uses two efficient methods for implicit integration of the
dynamic equations of systems with flexible bodies (not described here) Outline
- Semi-recursive formulation for flexible bodies: a review- Kinematics and dynamics of the flexible body- Method of the “24 constant matrices” (ECCOMAS 2009, Warsaw)- Dynamic equations of the multibody system
- Definition of the reduced model of a flexible body- Recursive computation of the dynamic equations
INSIA-ETSII-UPM
75/46
Deo omnis gloria!
Kinematics of a flexible body 1/2
Combines large rigid body motions with small deformations
- Based on the classical Moving Frame Approach- Deformed position of a point
- Relative position and velocity between two contiguous bodies
1 1
, s dn n
n i i j ji j
r g A r g A r q q φ ψ Φη Ψε
1 1 1 , 1 1, 1 , , 21 2
f f f fi i i i t i i k j j i i t i i k
k j k
z
g g A r φ u A r φ
11, 1 , 2
1 21 1
i i t ti k j j i k
k j ki i r ri i
z
s s φ φb
ω ω φ φ
r0
r y
x
z
nrq
gi-1 gi
ri-1 ri
body i-1
body i
zi-1,1
zi-1,2
INSIA-ETSII-UPM
76/46
Deo omnis gloria!
Kinematics of a flexible body 2/2
Transformation between Cartesian/FEM and Cartesian/modal coordinates- Cartesian linear and angular velocity of a FEM node
- For the n nodes of a flexible body:
, ,1 1
, ,1 1
s d
s d
n n
i i t j j t k kj k
n n
i r j j r k kj k
r s ω r A φ ψ
ω ω A φ ψ
1 1 1 1,1 , ,1 ,
11 1 1 1
,1 , ,1 ,1
2 2 2 22 ,1 , ,1 ,2
2 2 2 22 ,1 , ,1 ,
,1
f i
f i
f i
f i
t t n t t n
r r n r r n
t t n t t n
f r r n r r n
nn
n t
n
3 1
3 3
3
3 3
3
I r Aφ Aφ Aψ Aψr
0 I Aφ Aφ Aψ AψθI r Aφ Aφ Aψ Aψr
v θ 0 I Aφ Aφ Aψ Aψ
r I r Aφ Aφθ
1 1 1
1 1 1
, ,1 ,
,1 , ,1 ,
s s s
f i
f i d d d
RBn n n
n n nt n t t n
n n n nr r n r r n n n n
3 3
s s s
ω ω ω
D D D D
Aψ Aψ
0 I Aφ Aφ Aψ Aψ
f
Dq
f f f v Dq Dq
INSIA-ETSII-UPM
77/46
Deo omnis gloria!
Dynamics of a flexible body
By using the Principle of Virtual Power and a non-consistent interpolation for velocities, the dynamic equations can be obtained- Motion equations of a flexible body in Cartesian coordinates
- The mass matrix can be expressed in partitioned form:
The inertia matrix coming from FEM has been computed in the global reference frame and in the initial position:
(constant matrices/vectors are typed in blue color) The evaluation of terms and can be very
expensive.
T FEM T T FEMext ext vel elastic qD M Dq Φ λ Q D M Dq Kq Q Q Q
1 1s d
T T T T T Tn n q s ω Z η ε
, diag , , ,FEM FT FEM T T Tn n n
EM D M D D A A D DM D A A A AM
T FEMD M D T FEMD M Dq
, ,
, RB RB RB RB
Text
vel elastsym
q
M M M Z Q 0
M M η Φ λ Q Q Q
M ε Q Q
T FEMD M D
INSIA-ETSII-UPM
78/46
Deo omnis gloria!
Efficient computation of the term 1/3
Computation of matrix
- By taking into account that
1 1 1 1,1 , ,1 ,
1 1 1 1,1 , ,1 ,
2 2 2 22 ,1 , ,1 ,
2 2 2 2,1 , ,1 ,
,1
f i
f i
f i
f i
T T T T T Tt t n t t n
T T T T Tr r n r r n
T T T T T Tt t n t t n
T T T T T Tn r r n r r n
T T T nn t
1
3
3
A A r A Aφ A Aφ A Aψ A Aψ
0 A A Aφ A Aφ A Aψ A Aψ
A A r A Aφ A Aφ A Aψ A Aψ
D A D 0 A A Aφ A Aφ A Aψ A Aψ
A A r A Aφ
, ,1 ,
,1 , ,1 ,
f i
f i
RB
T n T n T nt n t t n
T T n T n T n T nr r n r r n
3
D
A Aφ A Aψ A Aψ
0 A A Aφ A Aφ A Aψ
D
ψ
D
A A
constant
3 3
3 3
3 3
3 3 3
3
1
2
3
2
3
T T T
T
T T TT
TRB T
T T Tn n
T
1
3 3
33 3
3
3 3
3 3
3 3
3 3
3 3 3
3
3
A A r A r
0 A 0
A A r A rA 0
D 0 A 00 A
A A r A r
0 A 0
I 0 I 0
0 I 0 I
I 0 I 0
0 I 0 I 0 I
I 0 I
0 I
1
21 2
3
TT
R RBT
n
B
3
3
3
3
3
3
33
r
0
rA 0
0 A D D0 A
0
0 r
0 I 0
Ti iA rA r
T FEMD M D
D
INSIA-ETSII-UPM
79/46
Deo omnis gloria!
Efficient computation of the term 2/3
The global position of a node, expressed in the moving frame is
Substituting this equation in the expression of
3 01 11
2
1 1 11 1
3 02 21 2 21 2
3 0
2
1 1
t
T
t t tnf ni
t t t tnf ni
t t t tn n nnf n n i
RB
nn
3 3 3 3 3 3
3 3 3 3 3 3
3 3 3 3
3
33
3 3 3
I r φ φ ψ ψ
0 0 0 0 0 0
I r φ φ ψ ψ
0 0 0 0 0 0
I r φ φ ψ ψ
0 0 0 0 0 0
r
0
r
D 0 A0
r
0
0
3
1 3
1
3
1 3
3
23,RB m
T
nf
ni
3
r
I
I
0 A ΓI
I
I
D 0
0 01 1
s dn n
T T T t ti i i i i ij j ij j
j j
A r A r r A r A r r φ ψ
2RBD
T FEMD M D
INSIA-ETSII-UPM
80/46
Deo omnis gloria!
Efficient computation of the term 3/3
The matrix to compute is- It depends on 10 precomputed, constant matrices- Sub-matrix MRB
- Sub-matrix MRB
- Sub-matrix M
1 2 1 2
3 33,3 1
3 33
3, 3
41 23
52 33
3 3,3 364 5
3,
,3,3 1
1 13
FEM
T
T TRB RB RB RB RB
T
mT
Tm m
mT T
mTT TT
m
M D D D D
A 0 A 0A 00
M
0 MM M
0 MΓ
0 A 0 A0 A
0 0A 0
M M
0 00 Γ
Γ Γ0
0
0 MA
0
M M
3 3,7
9
8
1 2
3 1
mT TRB R
FEB RB B
MRB R T
A 0 0M M M D D
0 A Γ
MM D D M
M
10 11
11 12
T T FEM T FEMFEM
T T FEM T FEM T
M M D D M D D M D M MM M D D
M M D D M D D M D M M
RB RBT FEMTRB
M MD M D
M M
T FEMD M D
INSIA-ETSII-UPM
81/46
Deo omnis gloria!
Efficient computation of the term 1/3
Dq
Velocity dependent inertia forces
The term can be computed as follows:
with
For each node there are two kind of terms: and
T FEMD M Dq
T FEM T FEM Tvel n n Q D M Dq D A M A Dq
1 1 1 1,1 , ,1 ,
1 1 1 1,1 , ,1 ,
2 2 2 22 ,1 , ,1 ,
2 2 2 2,1 , ,1 ,
,1 ,
f i
f i
f i
f i
f
t t n t t n
r r n r r n
t t n t t n
r r n r r n
n nn t t n
3 1
3 3
3
3 3
3
0 r s Aφ Aφ Aψ Aψ
0 0 Aφ Aφ Aψ Aψ
0 r s Aφ Aφ Aψ Aψ
Dq 0 0 Aφ Aφ Aψ Aψ
0 r s Aφ Aφ A
1 1
1
1
2 2
2
1
1,1 ,
,1 , ,1 ,
2
2
2
s
i
df i
r
r
r
r
n
rn nnt t n
rn n n nnnr r n r r n
3 3
s ω ω r ω vω
ω ω
ω ω r ω v
ω ω
ω ω r ω vψ Aψ
ω ω0 0 Aφ Aφ Aψ Aψ
, , , ,1 1 1 1
, s s s sn n n n
r rt i i t j j r i i r j j
i j i j
v φ ψ ω φ ψ
j ω ω r 2 r
j
rj
ω v
ω ω
Dq
INSIA-ETSII-UPM
82/46
Deo omnis gloria!
Efficient computation of the term 2/3
Computation of the centrifugal term at each node:
For each one of the three adding terms
with:
2 2 2 2 2 2 2 21 2
1,3 1,3
3 1 2 31,3 1,3
1,3 1,3
Ti i i
iT
ii
T
Ti
ω ω r A ω A r A ω r A ω ω ω r A
r 0 0
0 r 0
0 0 r
ω ω ω
1,3 123 0 ,1 , ,1 ,
1,3 1,3 1,3 1,3 1,3 1,3 1,3 1,3
1,3 1,3 1,3 1,3 1,3 1,
3
0 3
3
1 32 21 2 1 2
3
1 3
3 1,3 1,3
3
, s d
T T i T i T i T i TTi t
nf
ni
t n t t ni
0 e r φ φ ψ ψr
0 0 0 0 0 0 0 0
0 0 0 0 0 0
0
r I
I
I
A ω A Γ
0 0
ω Γ
I
I
I
0
0 0 123
0
1 1 1, x
Ty
z
r 0 0
r I 0 r 0 e
0 0 r
T FEMD M Dq
INSIA-ETSII-UPM
83/46
Deo omnis gloria!
Efficient computation of the term 3/3
Computation of the Coriolis acceleration term
Finally, the velocity dependent inertia forces are:
There 12 constant matrices that can be pre-computed
,1 , ,1 ,
,1 , ,1 ,
1
3
3 1
2 2 2 22 2 2s d
s
s
d
d
T
Tr r r i i i it t n t t n
i i i ir r n r r
Tni i i
r r T Tri ii
T
n
n
φ φ ψ ψ
φ φ ψ
A
Aω v A 0v A v Aω ω
0 Aω A ω A Aω ψω
A
ω
1
3 2 2 2, 2 1 2 2 2 3 3
3
3
13, 2 2 22 1
13 1
2 2 2 3 31
4 15 16
17 18 19 20
s
d
T
vel RB Tn
TmT
Tn
A
A 0Q Γ ω Γ ω Γ ω Γ ω
A0 AΓ
A0Γ ω Γ ω
M M M M
M M M Γ ω Γ ωMΓ
A
2 2 2
, 221 22 23 24
1 2 2 2 3 3vel M MQ Γ ω Γ ω ΓM Mω Γ ω
,
,
vel RB
velvel
Q
T FEMD M Dq
INSIA-ETSII-UPM
84/46
Deo omnis gloria!
1st velocity transformation 1/4
First, the closed loops are open. The Cartesian velocities are expressed in terms of the relative velocities and the static and dynamic modal amplitudes (computations carried out recursively):
The transformation matrix R can be partitioned in the form:
1 11
2 21 2 2,1
3 31 2 3 2,1 2,3
4 41 4 4,1
5 1 4 5 4,1 5,6
6 1 4 6 4,1 5,6
2
3
4
5
6
2
4
Z zb
Z zb b φ
Z zb b b φ φ
Z zb b φ
Z b b b φ φ
Z b b b φ φ
η I
η I
η I
η I
η I
ε I
ε I
5
6
2
3
4
5
6
2
4
z
z
η
η
η
η
η
ε
ε
q4
5
6
q5
q64
q3
0
q1
3
2
q2
1
, RB
Z q R R 0
η R η R 0 I 0
ε ε 0 0 I
INSIA-ETSII-UPM
85/46
Deo omnis gloria!
1st velocity transformation 2/4
The transformation matrix R relate Cartesian and relative coordinates for velocities and accelerations:
By assembling the dynamic equations of each body and setting them in terms of the relative and modal coordinates, the final expression for the open-chain dynamic equations is:
All the terms in this equation can be evaluated efficiently, using a recursive algorithm.
,
Z q Z q q
η R η η R η R η
ε ε ε ε ε
T T T
q q
R MR η R MR η R Q 0
ε ε
INSIA-ETSII-UPM
86/46
Deo omnis gloria!
1st velocity transformation 3/4
By substituting matrix R partitioned in the expression :
The first term of this expression is the mass accumulation in the relative coordinates and in the amplitudes of the boundary nodes.- A single recursive calculation can evaluate all expressions.
The second and third terms have analogous meanings.
TR MR
,
,
, ,
, , , ,
, ,
T TRB RB RB RB RB
T T TRB RB RB
T TRB RB RB RB
T TRB RB RB RB RB
RB RB RB
R M R R M R 0 0 0 0
R MR R M R R M R 0 0 M M
0 0 0 0 M M
0 R M R M
M R R M M R R M
M R M R 0
, , ,
, , n n n
T T k T T k T T kRB RB RB i RB j RB i RB j RB RB i RB ji j i j i j
k i k i k i
R M R b M b R M R φ M φ R M R φ M b
INSIA-ETSII-UPM
87/46
Deo omnis gloria!
1st velocity transformation 4/4
The projection of the forces can be evaluated similarly:
The evaluation is similar to that corresponding to the mass matrix:- All the terms are evaluated recursively
following the open-chain tree structure.- The forces applied to the relative
coordinates and modal amplitudes are added.
The remaining expressions also can be evaluated recursively.
TR Q
T TRB RB RB RB
T T TRB
T TRB
R 0 0 Q R Q
R Q R I 0 Q R Q Q
R 0 I Q R Q Q
i ii
i i ii
i ii
nT TRB RB z i k zz
k i
nT
RB kk i
R Q Q b Q Q
R Q Q φ Q Q
Q Q
INSIA-ETSII-UPM
88/46
Deo omnis gloria!
2nd velocity transformation
Closed-chain systems:- First the closed-loops are open by removing some joints- A subset of independent relative coordinates is chosen
- The constraint equations are enforced by a 2nd velocity transformation:
- Substituting in the open-chain differential equations:
i z B z
, , and
i
z ηz η
z η z
z
Φ Φ 0Φ Φ
Φ z η ε 0 Φ Φ 0 I 0 R 0B 0
0 0 I
z R z
T T i T T id
dt
zz z z
RRR R MRR z R R Q M z
INSIA-ETSII-UPM
89/46
Numerical examples 4. Live demos and concluding remarks
INSIA-ETSII-UPM
90/46
Deo omnis gloria!
Mbs3d: Implementation details
Program mbs3d- Computer program that implements the semi-recursive
formulation previously described- Written in MATLAB- Available at http://mec21.etsii.upm.es/mbs/
mbs3d/MEX- The core functions for computations and graphics written in C++
and called from MATLAB - Speed up of two orders of magnitude: real-time attainable!- Use of BLAS and sparse matrix libraries
Some advantages of the MATLAB/C++ combination- MATLAB is faster for the first implementation and testing- Afterwards, C++ functions may be implemented faster
INSIA-ETSII-UPM
91/46
Deo omnis gloria!
Concluding remarks
Natural coordinates provide a very simple way to define multibody systems.
Some of their characteristics (constant mass matrices and not velocity dependent inertia forces, quadratic constraint equations and linear Jacobians, …) allow fast global formulations.
For faster simulations topological methods with relative coordinates are preferable. Even in this case, natural coordinates may help in the definition of the system geometry and in the closure of the loop constraint equations, keeping the formulation simpler.
Natural coordinates and MATLAB may be useful for education in multibody systems under severe time limitations.
Algorithm implementation and testing are very easy with MATLAB, but the numerical performance is very poor. The combined implementation MATLAB/C++ is fast, reliable and efficient.
Keeping things as simple as possible always has an added value.
INSIA-ETSII-UPM
92/46
Numerical examples Thank you very much!(Slides available in mec21.etsii.upm.es/mbs
in a few days)