Hello everyone! I am currently working on a parametric model generation project. Specifically in steel connections. To do this, I made a problem type that generates these models from a database (.xml) which contains the geometric properties (width, height, thickness, etc.) of the elements of the connection such as columns, beams and welding.
However I realized that doing this sequentially would have many problems if you want to parameterize, because working with many points, lines, areas and volumes in the same drawing is a disaster.
What I would like to know is that if GiD can work with separate files (column.gid, beam.gid, welding.gid) to generate the geometries with a "slave code" taking its properties from the .xml file (separately) and then assemble all these elements and get the Connection using a "Master Code".
Thank you very much!
Model generation in separate files
Moderator: GiD Team
Re: Model generation in separate files
You can add a model to another previous model with
Files->Import->Insert GiD model
(entities of the second model are renumbered, avoiding repeat identifiers)
Files->Import->Insert GiD model
(entities of the second model are renumbered, avoiding repeat identifiers)
-
- Posts: 9
- Joined: Tue May 02, 2017 8:48 pm
Re: Model generation in separate files
Thank you for answering!escolano wrote:You can add a model to another previous model with
Files->Import->Insert GiD model
(entities of the second model are renumbered, avoiding repeat identifiers)
But there is a problem. What i'm trying to do is to generate automatically those models and I was looking for a solution that doesn't involve manual work, only code. Yes, I want to insert the connection elements in a new project file called "connection.gid", but those elements never have the same geometric properties, because I'm changing its parameters.
Here's a screen capture of my data tree
When I change "column section" or "beam section" fields, the models generated are the following:
My current code creates the connection sequentially, but I would like to make this easier (for the reasons exposed above) and generate the elements separately using a "slave code". It is possible? Maybe using several .tcl files?
Thank you again!
Re: Model generation in separate files
You can automatize tasks without user intervention
e.g.
to do the same that manually from the menu: Files->Import->Insert GiD model
must do it with the GiD_Process Tcl command
GiD_Process Mescape Files InsertGeom $filename.gid escape
Information of groups (entities associated to a group name) is also imported by "Insert GiD model",
if your model has the appropriated groups then applying the conditions on it could be simple
Layers information is also imported. It could also aid to apply your boundary conditions, but groups data is better for this purpose
You can also write a batch file with the GiD commands to be processed and read this batch file.
e.g.
to do the same that manually from the menu: Files->Import->Insert GiD model
must do it with the GiD_Process Tcl command
GiD_Process Mescape Files InsertGeom $filename.gid escape
Information of groups (entities associated to a group name) is also imported by "Insert GiD model",
if your model has the appropriated groups then applying the conditions on it could be simple
Layers information is also imported. It could also aid to apply your boundary conditions, but groups data is better for this purpose
You can also write a batch file with the GiD commands to be processed and read this batch file.
-
- Posts: 9
- Joined: Tue May 02, 2017 8:48 pm
Re: Model generation in separate files
Thank you so much, Escolano!escolano wrote:You can automatize tasks without user intervention
e.g.
to do the same that manually from the menu: Files->Import->Insert GiD model
must do it with the GiD_Process Tcl command
GiD_Process Mescape Files InsertGeom $filename.gid escape
Information of groups (entities associated to a group name) is also imported by "Insert GiD model",
if your model has the appropriated groups then applying the conditions on it could be simple
Layers information is also imported. It could also aid to apply your boundary conditions, but groups data is better for this purpose
You can also write a batch file with the GiD commands to be processed and read this batch file.
Greetings from Mexico!