MotionSolve
This block performs co-simulation with Altair MotionSolve.
Library
CoSimulation
Description
The MotionSolve block implements co-simulation between Activate and Altair MotionSolve. The MotionSolve model acts as a plant. The model must be prepared by adding Control_PlantInput and Control_PlantOutput. These statements reference variables that are either used as inputs to the model, such as forces or torques, or measure outputs, such as displacements or velocities.
Both MotionSolve (.xml) and MotionView (.mdl) input format are supported. If the inputfile is a MotionView MDL, a conversion to XML will be performed. From within the block parameter dialog it is possible to invoke MotionView to view and edit the MotionView model.
On output, if the action is active in the MotionSolve (.xml) model, the results (.mrf) will be converted into an H3D file (.h3d).
Simulations with this block require that Altair MotionSolve solver is installed. The path to the solver and its licensing must be set within Activate preferences panel, section CoSimulation.
Unlike in MotionSolveSignals block, input and output ports of this block are vectors. The name of each vector in the MotionSolve model are displayed as port labels.
Parameters
Name | Label | Description | Data Type | Valid Values |
---|---|---|---|---|
xml | XML or MDL input filename | MotionSolve (.xml) or MotionView (.mdl) model filename | String | |
mrf | MRF output filename | MotionSolve ouptut filename (.mrf) | String | |
usub | DLL User-sub filename | String | ||
nin | Number of input ports | The number of input ports on this block must correspond to the number of Control_PlantInput statements in the model. This field is automatically filled if the Reload button is pressed. | Number | |
inports | Inputs | Structure | ||
inports/label | Label | Cell of strings | ||
inports/rowsize | Row size | The input ports can be vectorial, in this case the size of vector is given here. This field is automatically filled if the Reload button is pressed. | Cell of scalars | |
nout | Number of output ports | The number of output ports on this block must correspond to the number of Control_PlantOutput statements in the model. This field is automatically filled if the Reload button is pressed. | Number | |
outports | Outputs | Structure | ||
outports/label | Label | Cell of strings | ||
outports/rowsize | Row size | The output ports can be vectorial, in this case the size of vector is given here. This field is automatically filled if the Reload button is pressed. | Cell of scalars | |
depu | Direct feedthrough | Sets the direct-feed-though of the block true. This allows being sure that when MotionSolver is called the block inputs are upto date. If an algebraic loop happens, you may turn this checkbox off to avoid the algenraic loop. | Number | 0 |
msip | MotionSolve server IP address | Used for TCP communication. Not used in the current release. | String | |
msport | MotionSolve server port number | Used for TCP communication. Not used in the current release. | Scalar | |
externalActivation | External activation | This parameter defines if the block receives an external activation or inherits. When External Activation is used, a additional activation port is added to the block. default is OFF. If External activation is enabled, the communication with the MotionSolve simulation engine is done only at event instants, e.g., at a fixed-rate defined by an external clock. | Number | 0 |
Name | Label | Description | Data Type | Valid Values |
---|---|---|---|---|
log_file_name | Log file name (*.log) | Activate messages as well as messages communicated from MotionSolve to Activate are logged into this file. | String |
Ports
Name | Type | Description | IO Type | Number |
---|---|---|---|---|
Port 1 | explicit | output | nout | |
Port 2 | explicit | input | nin | |
Port 3 | activation | input | externalActivation |
Advanced Properties
Name | Value | Description |
---|---|---|
always active | no | |
direct-feedthrough | Depends on block parameters | |
zero-crossing | no | |
mode | no | |
continuous-time state | yes | |
discrete-time state | no |