AmesimKnowledge

Importing Simcenter Amesim into Adams > Importing Simcenter Amesim models into Adams

Importing the model in Adams

As an example, you will use the Adams tutorial of the antenna controlled within Simcenter Amesim. This example comes from A/Controls tutorials.

Copy the A/View commandfile antenna.cmd from {Adams_DIR}/controls/examples/antenna into a working directory.

Warning

In Adams, do not forget to select the working directory where the Simcenter Amesim model is located. Use the menu item File > Select Directory. By default, the working directory is set to $HOME. This interface also uses libraries located in the $AME/$MACHDIR where $MACHDIR is the machine directory, for example win64 for Windows. This variable must be in the patch directory.

Procedure

  1. Import the file within A/view environment.

The Adams model contains an input on the azimuth_motion_csd azimuth_motion_csd variable to force the rotation during the simulation. This input must be deactivated because it is managed in the controller (Simcenter Amesim model). If we do not deactivate this variable, there will be a conflict between the Simcenter Amesim control and Adams control.

  1. To do this, select the Edit > Deactivate entry.

This action displays the Database Navigator Database Navigator to access the datatree.

  1. In the window Database Navigator select azimuth_motion_csd.

  2. Apply by clicking OK .

If we reopen the Database Navigator, the variable appears as OFF.

Step 1: Create the arrays for inputs, outputs and states

Arrays

Procedure

  1. Adams 2005: In A/View go to the Build > Controls Toolkit menu.Adams 2008: In A/View go to the Build > Data Elements > Array menu.

  2. First, choose the U input array.There you create inputs to the Simcenter Amesim subsystem, so it will be a 2-dimensional array containing Adams variables for velocity and position.

Figure 7: Adams 2005

Figure 8: Adams 2008

  1. Next choose X states array.

discrete export: X state array size = 1 (a dummy state variable)

continuous export: size of the array = Simcenter Amesim number of states (*) (if = 0 put 1)

(*) this number is displayed in the build dialog box.

The model cannot have implicit variables otherwise the interface does not work. Figure 9: Adams 2005

Figure 10: Adams 2008

  1. Finally, choose Y output array.

It represents the outputs from Simcenter Amesim so in our case it will be a 1-dimension array for the control torque.

Figure 11: Adams 2005

Figure 12: Adams 2008

Step 2: Association of array output value with the model

The control torque computed by Simcenter Amesim needs to be associated with the Adams model. You do it in the single component torque using ARYVAL Adams function. This one permits you to get an array value.

Note

As a first argument to this function you use the array of outputs and the second argument is the position of the required value; 1 in our case.

Procedure

From the Database Navigator, select the azimuth_actuator.

You have access to the following dialog box to modify the function:

Step 3: Creating the GSE and linking with the Simcenter Amesim library

Procedure

  1. In the Build > System Elements > General State Equation, choose New....

This opens the dialog box window below.

  1. Fill in the window as shown in the following figures.The States line corresponds to the coupling method you chose previously under  Simcenter Amesim. Choose discrete for a co-simulation and continuous for an export.The User Function Parameters field always needs three parameters and corresponds respectively to the ID of U Array, Y Array and X Array. Simcenter Amesim will need them to be able to get correct values from Adams during simulation.

Figure 13: Creating a GSE in Adams - discrete mode

Figure 14: Creating a GSE in Adams - continuous mode

  1. Once completed, you have to indicate to A/Solver to use the Simcenter Amesim library.Go to the Settings > Solver > Executable... menu.

  2. In the dialog box window for Solver Library supply the Simcenter Amesim library path as shown in the figure below:

  3. In Simcenter Amesim, select the appropriate settings for the simulation

Step 4: Running a simulation

Procedure

  1. Create a command script.

Here is an example of a Solver command script: Copysimulate/dynamics, end=0.250000, dtout=0.001

  1. simulation script Select Simulate > Simulation Script... > New

Since A/Solver will use an external library only scripted simulations are available.

  1. Select Simulate > Scripted Controls...

  2. Run the simulation within Adams, at the same time the Simcenter Amesim library writes a result file.

The Simcenter Amesim model is executed in the background. The communication with Adams takes place at the library level (dll on Windows). In the aside figure you can notice that Simcenter Amesim outputs some messages during the simulation.

Step 5: Checking the results

If you have Simcenter Amesim installed on the same machine, you can look at the results within Simcenter Amesim. Otherwise, you can focus on Adams results only.

Results of common variables are as follows under Simcenter Amesim.

In Adams we can also see the variable curves.

Source: https://docs.sw.siemens.com/en-US/doc/254352342/PL20250521841123434.amesim_collection.Adams/Importing_the_model_in_Adams · retrieved 2026-07-17