Our research team works with a finite element library that reads .unv files and requires all volume IDs and surface IDs in section 2467 to be numbers. When exporting from Trelis to .unv file, we face the following issues.
Section 2467 in .unv files is obsolete, so I guess that is why Trelis writes all information about IDs to section 2477. Solution is simple: rename section in .unv file after it is written. This needs to be checked. I could not do that since I have other issues, so the program does not run.
One cannot assign numbers as names of volume/surface groups when using Trelis GUI. Although assigning a number name to volume using command line works fine, you get an error if you do that with surfaces: “Problem assigning the name ‘1’. The default name will be used.” After that, surfaces do not appear in section 2477 at all. I knew that assigning names like “S1”, “S2”, etc. to surfaces would not work in our case (library-specific issue), but decided to try. Assigning itself seems to work fine, but I get a warning when exporting that says “Group 7 contains entities that were not written out.This group will be skipped.” Surface IDs are not present in section 2477 again.
So my questions are:
Is there any way to make Trelis assign number IDs to surfaces? It worked with volumes (they appear in .unv file).
How do I overcome the issue with the warning mentioned above?
Code is as follows.
####################
##### GEOMETRY #####
####################
# Create membrane
brick x 0.25 y 0.15 z 0.0175
# Move membrane to more convenient location
move volume 1 location 0.125 0.075 0.00875 include_merged
# Create vertices for future arcs to use webcutting tool
create vertex 0.001 0 0.0175 color
create vertex 0.0005 0 0.0175 color
create vertex 0 0 0.017 color
create vertex 0 0 0.0165 color
create vertex 0 0 0.00875 color
create vertex 0.00875 0 0.0175 color
# Create arcs
create curve arc center vertex 4 11 10
create curve arc center vertex 4 12 9
create curve arc center vertex 4 13 14
# Create lines for additional cuts
create curve location 0.035 0 0 location 0.035 0 0.0175
create curve location 0.1 0 0 location 0.1 0 0.0175
# Use webcutting tool to decompose geometry
webcut body 1 sweep curve 13 zaxis angle 90 stop surface 4
webcut body 2 sweep curve 14 zaxis angle 90 stop surface 12
webcut body 3 sweep curve 15 zaxis angle 90 stop surface 21
webcut body 4 sweep curve 16 zaxis angle 90 stop surface 30
webcut body 5 sweep curve 17 along curve 1
# Imprint and merge everything
imprint body all
merge body all
####################
####### MESH #######
####################
# Define number of intervals for all volumes
volume all interval 10
# Mesh everything with Polyhedron scheme
volume all scheme Polyhedron
mesh volume all
####################
######## IDs ########
####################
group '0' equals Volume all
group '1' equals Surface 9
group '2' equals Surface 16
group '3' equals Surface 26 34 44 49
group '4' equals Surface 38 35 24 17 10 8 18 25 33 43 50
group '5' equals Surface 45 48 6
group '6' equals Surface 32 42 47
Trelis can use both names and ID numbers in group commands. This can create some confusion for Trelis when the user-defined name is also a number. For example,
Group plate ID 2
Group 4 ID 3
Group 3 ID 4
The command, “highlight group plate” is clear as to which group to use, but which is the intended group in the command, “highlight group 3”? In these cases, Trelis will always use the group with the ID equal to the specified number.
A group name that is a number is a valid name. but you will need to modify the command to let Trelis know that it is a number name. The command should be:
highlight group with name “3”
If you create a group with a number as its name, Trelis will append an assigned name to the number name. In your example, the group with name 5 had @E added to the 5 to get the name "5@E". While this name is not shown in the tree, it can also be used in commands, such as
highlight group 5_@E
Numbers as group names causes problems when used in commands. For that reason, prevent this in the GUI and we recommend that numbers are not used as group names. However, if needed, you can use number names in the command line and in the tree.
The message, “Group X contains entities that were not written out. This group will be skipped.” only occurs for your groups of surfaces. It seems that groups that contain volumes are exported to I-DEAS, but not groups that contain surfaces. Let me follow up in a separate post.
The I-DEAS exporter is based on blocks, not groups and will only include information from groups if they are defined in blocks. If blocks aren’t defined, then default blocks are defined, one for each volume. This is why your output displayed “Number of element blocks = 6”, one for each volume.
To include surfaces, define blocks that correspond to the groups created. Then those elements will be written out. For example,
group ‘g0’ equals Volume all
group ‘g1’ equals Surface 9
group ‘g2’ equals Surface 16
group ‘g3’ equals Surface 26 34 44 49
group ‘g4’ equals Surface 38 35 24 17 10 8 18 25 33 43 50
group ‘g5’ equals Surface 45 48 6
group ‘g6’ equals Surface 32 42 47
block 1 group with name ‘g0’ expand
block 2 group with name ‘g1’ expand
block 3 group with name ‘g2’ expand
block 4 group with name ‘g3’ expand
block 5 group with name ‘g4’ expand
block 6 group with name ‘g5’ expand
block 6 group with name ‘g6’ expand
Thank you for your reply. Unfortunately, the code still does not work properly.
If I use the following code with your corrections,
####################
##### GEOMETRY #####
####################
# Create membrane
brick x 0.25 y 0.15 z 0.0175
# Move membrane to more convenient location
move volume 1 location 0.125 0.075 0.00875 include_merged
# Create vertices for future arcs to use webcutting tool
create vertex 0.001 0 0.0175 color
create vertex 0.0005 0 0.0175 color
create vertex 0 0 0.017 color
create vertex 0 0 0.0165 color
create vertex 0 0 0.00875 color
create vertex 0.00875 0 0.0175 color
# Create arcs
create curve arc center vertex 4 11 10
create curve arc center vertex 4 12 9
create curve arc center vertex 4 13 14
# Create lines for additional cuts
create curve location 0.035 0 0 location 0.035 0 0.0175
create curve location 0.1 0 0 location 0.1 0 0.0175
# Use webcutting tool to decompose geometry
webcut body 1 sweep curve 13 zaxis angle 90 stop surface 4
webcut body 2 sweep curve 14 zaxis angle 90 stop surface 12
webcut body 3 sweep curve 15 zaxis angle 90 stop surface 21
webcut body 4 sweep curve 16 zaxis angle 90 stop surface 30
webcut body 5 sweep curve 17 along curve 1
# Imprint and merge everything
imprint body all
merge body all
####################
####### MESH #######
####################
# Define number of intervals for all volumes
volume all interval 10
# Mesh everything with Polyhedron scheme
volume all scheme Polyhedron
mesh volume all
####################
######## IDs ########
####################
group 'g0' equals Volume all
group 'g1' equals Surface 9
group 'g2' equals Surface 16
group 'g3' equals Surface 26 34 44 49
group 'g4' equals Surface 38 35 24 17 10 8 18 25 33 43 50
group 'g5' equals Surface 45 48 6
group 'g6' equals Surface 32 42 47
block 1 group with name 'g0' expand
block 2 group with name 'g1' expand
block 3 group with name 'g2' expand
block 4 group with name 'g3' expand
block 5 group with name 'g4' expand
block 6 group with name 'g5' expand
block 6 group with name 'g6' expand
then I get errors (“Group 5 does not exist.”).
I tried to create blocks manually by using Analysis Groups and Materials - Blocks - Manage blocks:
set duplicate block elements on
block 1 group g0
block 2 group g1
block 3 group g2
block 4 group g3
block 5 group g4
block 6 group g5
block 7 group g6
(setting duplicate block elements to on can be skipped)
In this case, blocks are created without any error, but I cannot export to I-DEAS because of the warning (more than 100 elements share the same ID) and error (could not export the data to a file). I do understand the issue, but need some help in solving it.
The issue may be that the Ideas exporter exports blocks, not groups. Try putting your groups into blocks with these commands:
block 1 group 2 #Your group ‘0’
block 2 group 3 #Your group ‘1’
block 3 group 4 #Your group ‘2’
block 4 group 5 #Your group ‘3’
block 5 group 6 #Your group ‘4’
block 6 group 7 #Your group ‘5’
block 7 group 8 #Your group ‘6’
No error message and seven 2477 datasets in the output. Do you get the right 2477 datasets?
####################
##### GEOMETRY #####
####################
# Create membrane
brick x 0.25 y 0.15 z 0.0175
# Move membrane to more convenient location
move volume 1 location 0.125 0.075 0.00875 include_merged
# Create vertices for future arcs to use webcutting tool
create vertex 0.001 0 0.0175 color
create vertex 0.0005 0 0.0175 color
create vertex 0 0 0.017 color
create vertex 0 0 0.0165 color
create vertex 0 0 0.00875 color
create vertex 0.00875 0 0.0175 color
# Create arcs
create curve arc center vertex 4 11 10
create curve arc center vertex 4 12 9
create curve arc center vertex 4 13 14
# Create lines for additional cuts
create curve location 0.035 0 0 location 0.035 0 0.0175
create curve location 0.1 0 0 location 0.1 0 0.0175
# Use webcutting tool to decompose geometry
webcut body 1 sweep curve 13 zaxis angle 90 stop surface 4
webcut body 2 sweep curve 14 zaxis angle 90 stop surface 12
webcut body 3 sweep curve 15 zaxis angle 90 stop surface 21
webcut body 4 sweep curve 16 zaxis angle 90 stop surface 30
webcut body 5 sweep curve 17 along curve 1
# Imprint and merge everything
imprint body all
merge body all
####################
####### MESH #######
####################
# Define number of intervals for all volumes
volume all interval 10
# Mesh everything with Polyhedron scheme
volume all scheme Polyhedron
mesh volume all
####################
######## IDs ########
####################
group '0' equals Volume all
group '1' equals Surface 9
group '2' equals Surface 16
group '3' equals Surface 26 34 44 49
group '4' equals Surface 38 35 24 17 10 8 18 25 33 43 50
group '5' equals Surface 45 48 6
group '6' equals Surface 32 42 47
block 1 group 2 #Your group '0'
block 2 group 3 #Your group '1'
block 3 group 4 #Your group '2'
block 4 group 5 #Your group '3'
block 5 group 6 #Your group '4'
block 6 group 7 #Your group '5'
block 7 group 8 #Your group '6'
The result does not depend on how I name the groups, they can be called ‘g0’, ‘g1’, etc. as well. I get this in Trelis command window and no output file:
This second issue seems to be with using the “cubitids” option when exporting. You are exporting all the volumes and then exporting several of the surfaces. The IDs for each entity type starts at 1. So, if hexes are numbered from 1 to 8 and faces are numbered from 1 to 24, the first IDs of each type (1 to 8) are not unique. Because you are using the “cubitids” option, the IDs used in Trelis are retained in the exported file, and some faces and hexes have the same ID.
There are a few ways to handle this:
Don’t export using the “cubitids” option. Let Trelis create unique IDs as it exports the mesh.
Renumber IDs before exporting. Use the renumber command to renumber the faces starting with the next ID after the last hex ID. In this model the hexes end with ID 5250, so start the faces at 5251 or higher. Here are some commands you could use:
To see the hex ID range type:
list hex
To see the face ID range type:
list face
renumber face all start_id 5251 uniqueids
Export the volume as one file and the surfaces to a second file.
The easiest is to not use the cubitids option. Attached is a journal file with the second option. cubitIDs.jou (2.1 KB)
Is there a way to make Trelis output 2D elements as type 44 (Plane Stress Linear Quadrilateral), not 94 (Thin Shell Linear Quadrilateral) in .unv format?
Trying to solve incompatibilities with our FEA software.