classLink
Link
Extends from Modelica.Mechanics.MultiBody.Interfaces.PartialTwoFrames (Base model for components providing two frame connectors + outer world + assert to guarantee that the component is connected), Servomechanisms.Utilities.IconName.
Information
General
This class enables the creation of a link element by selecting one of the predefine components from Multibody library: BodyBox , BodyCylinder or BodyShape .
Implementation
IF statements allow the selection of one kind of link from the Multibody library.Replaceable statement was intended at the beginning but it did not work well.
Notes
- The advantage of using this component is that if one selects for example box or cylinder it is necessary only to input the dimensions length, width and heigth or length and diameter because the density and values of mass and inertia are automatically calculate.
- In the other case (bodyshape), the user must input the directory of a 3d model for visualization (it has been tested with modelica3d library but it is yet under development) and the values of mass, vector from frame_a to frame_b, vector from frame_a to center of mass and the inertia tensor.
- At the moment, not all the parameters of the original elements (BodyShape, BodyBox, BodyCylinder) are utilized. This could be a limitation for the user.
Parameters
| Type | Name | Default | Description |
|---|---|---|---|
| String | shape | "box" | shape of visualizer:"shape", "box", "cylinder" |
| if shape | |||
| SI.Position[3] | r | Vector from frame_a to frame_b resolved in frame_a | |
| SI.Position[3] | r_CM | Vector from frame_a to center of mass, resolved in frame_a | |
| SI.Mass | m | Mass of rigid body | |
| SI.Length | shapeLength | 1 | |
| SI.Distance | shapeWidth | boxLength/20 | |
| SI.Distance | shapeHeight | boxWidth | |
| String | shapeType | "modelica://Servomechanisms//Resources//b2.dxf" | Type of shape |
| Real | extra | 1 | Additional parameter depending on shapeType (see docu of Visualizers.Advanced.Shape) |
| if shape › Inertia tensor (resolved in center of mass, parallel to frame_a) | |||
| SI.Inertia | I_11 | 0.001 | (1,1) element of inertia tensor |
| SI.Inertia | I_22 | 0.001 | (2,2) element of inertia tensor |
| SI.Inertia | I_33 | 0.001 | (3,3) element of inertia tensor |
| SI.Inertia | I_21 | 0 | (2,1) element of inertia tensor |
| SI.Inertia | I_31 | 0 | (3,1) element of inertia tensor |
| SI.Inertia | I_32 | 0 | (3,2) element of inertia tensor |
| if box | |||
| SI.Length | boxLength | 1 | |
| SI.Distance | boxWidth | boxLength/20 | |
| SI.Distance | boxHeight | boxWidth | |
| if cylinder | |||
| SI.Length | cylinderLength | 1 | |
| SI.Distance | cylinderDiameter | cylinderLength/20 | |
| Parameters only for cylinder and box | |||
| SI.Density | density | 7700 | Density of link (e.g., steel: 7700 .. 7900, wood : 400 .. 800) |
Connectors
| Type | Name | Default | Description |
|---|---|---|---|
| Interfaces.Frame_a | frame_a (from PartialTwoFrames) | Coordinate system a fixed to the component with one cut-force and cut-torque | |
| Interfaces.Frame_b | frame_b (from PartialTwoFrames) | Coordinate system b fixed to the component with one cut-force and cut-torque |
Components
| Type | Name | Default | Description |
|---|---|---|---|
| ShapePath.BodyShape | shape1 | ||
| ShapePath.BodyBox | box1 | ||
| ShapePath.BodyCylinder | cylinder1 |