MultiBondLib.Mechanics3DwithImpulses.Parts

Parts

MultiBondLib.Mechanics3DwithImpulses.Parts.Body MultiBondLib.Mechanics3DwithImpulses.Parts.SimpleBody MultiBondLib.Mechanics3DwithImpulses.Parts.Fixed MultiBondLib.Mechanics3DwithImpulses.Parts.FixedRotation MultiBondLib.Mechanics3DwithImpulses.Parts.FixedTranslation

Information


This package contains completely rigid components.

These components are either define a mass and inertia or they define a fixed relationship.

NameDescription
Body complete model of a body
SimpleBody simple model of a body
Fixed wall
FixedRotation fixed rotation
FixedTranslation fixed translation


MultiBondLib.Mechanics3DwithImpulses.Parts.Body MultiBondLib.Mechanics3DwithImpulses.Parts.Body

complete model of a body

MultiBondLib.Mechanics3DwithImpulses.Parts.Body

Information


This is the model of a body representing a point with given mass and inertia tensor.

If the body model is not connected to any joint, its movement is defined to be free. Therefore this model includes a potential free-body movement joint and in consequences shares certain joint characterisitcs.

General parameter

The mass can be specified by the parameter m.

The inertia tensor is a symmetric 3x3 matrix and can be specified by the parameters I11, I12, ...

A non-zero value for the parameter GPIndex inserts the body into the gravity pool.
Make sure the integer value is unique and does not exceed the size of the gravity pool.

The parameter animation toggles the visualization

Initialization

In general, you can specify... Which of these variables do effectively appear in the inital equations can be defined by the parameter initType.

Visualization

The element is visualized by a sphere. Diameter and color of the sphere can be specified by the animation parameters.

Advanced settings

The activation of enforceStates enforces the joint to explicitely define integrators. This parameter is useful to choose the state variables manually.

The activation of reinitByImpulse determines the state variables to be reinitialized in case of a force impulse. It is coupled by default with the parameter enforceStates. The selection of the reinitialization points must be done manually.

The orientation can either be expressed by the three cardan angles or by quaternions.

Which of these two variants is used, can be specified by the parameter useQuaternions. If cardan angles are chosen to be used, you can specify the sequence of rotation axis by the parameter sequence_angles.


Parameters

NameDefaultDescription
animationtrue= true, if animation shall be enabled
m1mass of body [kg]
GPIndex0Index of element in gravity pool (is zero if element is not in gravity pool)
CPIndex0 
Inertia tensor (resolved in center of mass, parallel to frame_a)
I_110.001 (1,1) element of inertia tensor [kg.m2]
I_220.001 (2,2) element of inertia tensor [kg.m2]
I_330.001 (3,3) element of inertia tensor [kg.m2]
I_210 (2,1) element of inertia tensor [kg.m2]
I_310 (3,1) element of inertia tensor [kg.m2]
I_320 (3,2) element of inertia tensor [kg.m2]
Initialization
initTypeMB.Types.Init.Free Type of initialization (defines usage of start values below)
x_start[3]{0,0,0}initial position [m]
v_start[3]{0,0,0}initial velocity [m/s]
a_start[3]{0,0,0}initial acceleration [m/s2]
phi_start[3]{0,0,0}initial cardan angles in degree [deg]
w_start[3]{0,0,0}initial angular velocity in deg/s [deg/s]
z_start[3]{0,0,0}initial angular acceleration in deg/s2 [deg/s2]
Advanced
enforceStatesfalseenforce Quaternions or cardan angles and w as states
useQuaternionstrueuse Quaternions instead of cardan angles
sequence_angles{1,2,3}sequence of the cardan angles
reinitByImpulseenforceStatesreinit velocities by an impulse
Animation
if animation = true
sphereDiameterworld3D.defaultBodyDiameter Diameter of sphere [m]
sphereColorworld3D.defaultBodyColor Color of sphere

Modelica definition

model Body "complete model of a body" 
  extends Mechanics3D.Parts.Body(redeclare Interfaces.IFrame_a frame_a,
                                 redeclare Interfaces.IMech2MBG Mech2MBG1,
                                 redeclare Joints.PotentialFBM PotentialFBM1(
    initType=initType,
    x_start=x_start,
    v_start=v_start,
    a_start=a_start,
    phi_start=phi_start,
    w_start=w_start,
    z_start=z_start,
    enforceStates=enforceStates,
    useQuaternions=useQuaternions,
    sequence_angles=sequence_angles,
    reinitByImpulse = reinitByImpulse));
  
  
   parameter Boolean reinitByImpulse =  enforceStates 
    "|Advanced||reinit velocities by an impulse";
   parameter Integer CPIndex = 0;
  
protected 
  outer CollisionPool collisionPool;
  Real Va[3];
  Real Wa[3];
equation 
  if CPIndex > 0 then
    connect(frame_a, collisionPool.frames[CPIndex]);
  end if;
  when frame_a.contact then
    Va = frame_a.P.v;
    Wa = frame_a.P.w;
  end when;
  
  frame_a.F = m*2*(frame_a.Vm-Va);
  frame_a.T = Inert*2*(frame_a.Wm-Wa);
  
end Body;

MultiBondLib.Mechanics3DwithImpulses.Parts.SimpleBody MultiBondLib.Mechanics3DwithImpulses.Parts.SimpleBody

simple model of a body

MultiBondLib.Mechanics3DwithImpulses.Parts.SimpleBody

Information


This is the model of a body representing a point with given mass and inertia tensor.

Different from the standard body model, this model does not contain a potential joint and therefore needs to be connected to a joint or fixation element.

General parameter

The mass can be specified by the parameter m.

The inertia tensor is a symmetric 3x3 matrix and can be specified by the parameters I11, I12, ...

A non-zero value for the parameter GPIndex inserts the body into the gravity pool.
Make sure the integer value is unique and does not exceed the size of the gravity pool.

The parameter animation toggles the visualization

Visualization

The element is visualized by a sphere. Diameter and color of the sphere can be specified by the animation parameters.

Parameters

NameDefaultDescription
animationtrue= true, if animation shall be enabled
m1mass of body [kg]
GPIndex0Index of element in gravity pool (is zero if element is not in gravity pool)
Inertia tensor (resolved in center of mass, parallel to frame_a)
I_110.001 (1,1) element of inertia tensor [kg.m2]
I_220.001 (2,2) element of inertia tensor [kg.m2]
I_330.001 (3,3) element of inertia tensor [kg.m2]
I_210 (2,1) element of inertia tensor [kg.m2]
I_310 (3,1) element of inertia tensor [kg.m2]
I_320 (3,2) element of inertia tensor [kg.m2]
Animation
if animation = true
sphereDiameterworld3D.defaultBodyDiameter Diameter of sphere [m]
sphereColorworld3D.defaultBodyColor Color of sphere

Modelica definition

model SimpleBody "simple model of a body" 
   extends Mechanics3D.Parts.SimpleBody(redeclare Interfaces.IFrame_a frame_a,
                                        redeclare Interfaces.IMech2MBG 
      Mech2MBG1);
  
  
protected 
  Real Va[3];
  Real Wa[3];
equation 
  when frame_a.contact then
    Va = frame_a.P.v;
    Wa = frame_a.P.w;
  end when;
  
  frame_a.F = m*2*(frame_a.Vm-Va);
  frame_a.T = Inert*2*(frame_a.Wm-Wa);
  
end SimpleBody;

MultiBondLib.Mechanics3DwithImpulses.Parts.Fixed MultiBondLib.Mechanics3DwithImpulses.Parts.Fixed

wall

MultiBondLib.Mechanics3DwithImpulses.Parts.Fixed

Information


This is the model of a body representing a point with given mass and inertia tensor.

Different from the standard body model, this model does not contain a potential joint and therefore needs to be connected to a joint or fixation element.

General parameter

The mass can be specified by the parameter m.

The inertia tensor is a symmetric 3x3 matrix and can be specified by the parameters I11, I12, ...

A non-zero value for the parameter GPIndex inserts the body into the gravity pool.
Make sure the integer value is unique and does not exceed the size of the gravity pool.

The parameter animation toggles the visualization

Visualization

The element is visualized by a sphere. Diameter and color of the sphere can be specified by the animation parameters.

Parameters

NameDefaultDescription
r[3]{0,0,0}position of frame_b [m]

Modelica definition

model Fixed "wall" 
            extends Mechanics3D.Parts.Fixed(redeclare Interfaces.IFrame_b 
      frame_b,                              redeclare Interfaces.MBG2IMech 
      MBG2Mech1);
equation 
   frame_b.Vm = zeros(3);
   frame_b.Wm = zeros(3);
end Fixed;

MultiBondLib.Mechanics3DwithImpulses.Parts.FixedRotation MultiBondLib.Mechanics3DwithImpulses.Parts.FixedRotation

fixed rotation

MultiBondLib.Mechanics3DwithImpulses.Parts.FixedRotation

Information


This component defines a fixed rotation between the two connected frames.

General parameter

The rotation can be specified by the rotation axis n and the rotation anlge phi. The rotation axis is resolved in the body system.

Visualization

The element isn't visualized.

Parameters

NameDefaultDescription
n[3]{1,0,0}rotation axis [m]
angle0angle [deg]

Modelica definition

model FixedRotation "fixed rotation" 
  extends Mechanics3D.Parts.FixedRotation(redeclare Interfaces.IFrame_a frame_a,
                                 redeclare Interfaces.IFrame_b frame_b,
                                 redeclare Interfaces.IMech2MBG Mech2MBG1,
                                 redeclare Interfaces.MBG2IMech MBG2Mech1);
  
equation 
  frame_a.contact = frame_b.contact;
  frame_a.F + frame_b.F = zeros(3);
  frame_a.Vm =  frame_b.Vm;
  
  Rotation1.Rrel*frame_a.T + frame_b.T  = zeros(3);
  Rotation1.Rrel*frame_a.Wm = frame_b.Wm;
  
end FixedRotation;

MultiBondLib.Mechanics3DwithImpulses.Parts.FixedTranslation MultiBondLib.Mechanics3DwithImpulses.Parts.FixedTranslation

fixed translation

MultiBondLib.Mechanics3DwithImpulses.Parts.FixedTranslation

Information


This is the model of a massless rod. It defines a fixed translation between the two connected frames.

General parameter

The rod can be specified by a parameter vector r. r is resolved in the body system and points from frame a to frame b.

Visualization

The element is normally visualized as cylinder. Anyhow the visualization can be changed by the according parameters.

Parameters

NameDefaultDescription
animationtrue= true, if animation shall be enabled
r[3]{1,0,0}translational vector from frame a to b [m]
Animation
if animation = true
shapeType"cylinder" Type of shape
lengthsqrt(r*r) Length of shape [m]
widthlength/world3D.defaultWidthF... Width of shape [m]
heightwidth Height of shape. [m]
extra0.0 Additional parameter depending on shapeType (see docu of Visualizers.Advanced.Shape).
colorworld3D.defaultRodColor Color of shape

Modelica definition

model FixedTranslation "fixed translation" 
  extends Mechanics3D.Parts.FixedTranslation(redeclare Interfaces.IFrame_a 
      frame_a,                   redeclare Interfaces.IFrame_b frame_b,
                                 redeclare Interfaces.IMech2MBG Mech2MBG1,
                                 redeclare Interfaces.MBG2IMech MBG2Mech1);
  
protected 
  Real R[3,3];
  
equation 
when frame_a.contact then
  R = frame_a.P.R;
end when;
  
frame_a.contact = frame_b.contact;
frame_a.F + frame_b.F = zeros(3);
frame_a.T + frame_b.T + cross(r,R*frame_b.F) = zeros(3);
frame_a.Vm + transpose(R)*cross(frame_a.Wm,r) = frame_b.Vm;
frame_a.Wm = frame_b.Wm;
  
end FixedTranslation;

HTML-documentation generated by Dymola Thu Feb 23 12:20:07 2006.