exporting information from GiD via a text file

Moderator: GiD Team

Posts: 1
Joined: Wed Jun 23, 2021 2:16 pm

exporting information from GiD via a text file

Postby jlyon426 » Wed Jun 23, 2021 2:34 pm

Hello everyone
I am currently exporting information from GiD via a text file: geometry, grid, simple types of tasks that I use to add information such as materials, connections, analysis parameters; but i also want to export normals to grid elements: how can i do this without a .bas file and TCL commands?
Thank you very much.
"Go to Heaven for the climate, Hell for the company."
time tracking software
User avatar
Posts: 1717
Joined: Thu Sep 18, 2014 3:31 pm

Re: exporting information from GiD via a text file

Postby escolano » Wed Jun 23, 2021 5:02 pm

How are you exporting the information a text?
with Files->Export->Text data report...?

In general any standard format will export exactly what you want, and in fact normals is derived information that is not usually exported because it is redundant data. (a dot product of two tangent vectors and an evaluation of partial derivatives in surfaces)

If do you need your own format or kind of data assume that you must export with your custom code (Tcl or .bas template)
why not to do it? it is as simple as write a file xxx.bas in your problemtype (I assume that do you have one because are speaking of 'materials') with few lines like this:

Code: Select all

*set elems(triangle)
*loop elems
*ElemsNum *ElemsNormal
*end elems

then a <modelname>.dat file will be printed with the element id and its normal for all triangles

for more complicated data, can write in your problemtype some Tcl code with a proc that ask GiD data and print it as you want

Return to “Mesh”

Who is online

Users browsing this forum: No registered users and 2 guests