TEKLA-to-GiD (ATENA problem)

Moderator: GiD Team

Posts: 6
Joined: Thu Apr 04, 2019 7:43 pm
Location: St.Petersburg, Russia

TEKLA-to-GiD (ATENA problem)

Postby pavlo » Fri Aug 23, 2019 3:11 pm


I intend to create a macro or program to export model from Tekla Structures to GiD with all available properties to be defined to GiD macroelements. I see the following ways to solve this problem now:

OPTION A (mid difficulty)
1. To export geometry from Tekla to 3D DXF file with all concrete blocks as volumes and rebars as lines. Each different material should be placed in separate layer.
2. To generate a tcl script for GiD which imports geometry from dwg file created in previous step.
3. To generate a tcl script for GiD which switches problem type to ATENA and creates all materials in GiD based on data from Tekla exported members.
4. To generate a tcl script for GiD which assigns all boundary conditions and materials to the imported geometry (in step 2). We consider reasonable to assign materials with the use of layers but I couldn't find how to do this with the use of tcl script.
5. Model is ready for user fine tuning and analysis.
6. If needed to upgrade geometry from Tekla, all steps are repeated in the same model. User should do necessary actions to not have intersecting members of older and new version of model (I mean that if I need to change only a column in system of column+beam, I should firstly delete old column in GiD an then start generated script).

We assume that tcl script from steps 2-4 can be generated with the use of Tekla C# plugin of our own development.

OPTION B (most difficult)
Instead of steps 1-4 to use GiD API. Geometry from Tekla can be restored with the use of code in GiD with no DXF export-import. However, I haven't found any info about GiD API. I even know don't whether you have an open API. Could you specify please?

(most simple)
1. Create an empty GiD (Atena problem) with all material library predefined, template actually. This step will be not repeated, just once.
2. Create a tcl script which firstly imports DXF generated by Tekla, then assigns materials to elements on the basis of layer name. Layer names in DXF should be the same name as materials in GiD template from step 1. However, I don't know how to assign materials to elements which belong to a specific layer rather than to an element with specified number. Would you help me pls with this? This step is not recurrent as well.
3. To export geometry from Tekla to 3D DXF file with all concrete blocks as volumes and rebars as lines. Each different material should be placed in separate layer with names similar to GiD material library from template.
4. Run script from step 2.

Would you please advice me on this?
Also please send me description of all commands for creating macro in GiD. And please send me API documentation if it exists.
User avatar
Posts: 1717
Joined: Thu Sep 18, 2014 3:31 pm

Re: TEKLA-to-GiD (ATENA problem)

Postby escolano » Mon Aug 26, 2019 10:57 am

You can do

1- an importer of Tekla format at GiD side, with a Tcl procedure (added for example to the ATENA problemtype, or invoked from a user macro button,etc)

2- an exporter of GiD-ATENA format at Tekla side, with a "Tekla C# plugin".

If Tekla format is easy to be read (e.g. ASCII or xml), I recommend you the option 1
Have a look for example to the code of

The procedure Calculix::ReadPreGeometry read a .fbd CALCULIX geometry file,
and create the GiD entities with our API
GiD_Geometry, GiD_Groups, GiD_Layers, GiD_AssignData, ...
and GiD_Process and the GiD process keywords (if there is not a more direct Tcl command like GiD_Geometry to do the same)

The documentation of our GiD-Tcl API is docummented in the "GiD Customization Manual"->Tcl and Tk extension

If Tekla format is difficult, It is possible to use a combination of 1 and 2: exporting with Tekla C# the data in a simple intermediate format, and then read this intermediate format with the Tcl importer

Instead of Tekla format can use the exchange DXF format, but maybe do you miss some control of other attached data like materials and boundary conditions

Return to “General Information”

Who is online

Users browsing this forum: No registered users and 1 guest