sdynpy.fem.sdynpy_exodus.reduce_exodus_to_surfaces

reduce_exodus_to_surfaces(fexo, blocks_to_transform=None, variables_to_transform=None, keep_midside_nodes=False, verbose=False)[source]

Convert exodus finite element models to surface elements

This function converts specified volume meshes in an exodus file to surface meshes to ease computational complexity.

Parameters
  • fexo (ExodusInMemory object or Exodus object) – fexo should be an in-memory representation of the finite element mesh

  • blocks_to_transform (iterable) – blocks_to_transform includes all of the blocks that will be included in the output model

  • variables_to_transform (iterable) – variables_to_transform is a case-insensitive list of all variable names that will be kept in the final model

  • keep_midside_nodes (bool) – keep_midside_nodes specifies whether or not to transform quadratic elements into linear elements, discarding any non-corner nodes.

Returns

fexo_out – An equivalent fexo reduced to the surface geometry.

Return type

ExodusInMemory object

Notes

TO ADD MORE ELEMENT TYPES, we need to define a volume element name that we will find in the exodus file, for example ‘tetra4’ or ‘hex20’, the number of nodes per face on the element, and a connectivity matrix that specifies how the faces are made from the nodes of the element. For example a hex8 element has the following structure:

    8--------------7
   /|             /|
  / |            / |
 /  |           /  |
5--------------6   |
|   4----------|---3
|  /           |  /
| /            | /
|/             |/
1--------------2

So the 6 faces are as follows:

1,2,6,5
2,3,7,6
3,4,8,7
4,1,5,8
4,3,2,1
5,6,7,8

We create the element face connectivity by simply mashing these together one after another like so: 1,2,6,5,2,3,7,6,3,4,8,7,4,1,5,8,4,3,2,1,5,6,7,8 We lastly need to specify what we are turning the element into, in this case, quad4. So we add an entry to the reduce_element_types, reduce_element_nodes_per_face, reduce_element_face, and reduce_element_substitute_type variables containing this information hex8:

reduce_element_types{4} = 'hex8'
reduce_element_nodes_per_face{4} = 4
reduce_element_face{4} = [1,2,6,5,2,3,7,6,3,4,8,7,4,1,5,8,4,3,2,1,5,6,7,8]
reduce_element_substitute_type{4} = 'quad4'

To see what other elements look like, see page 18 of the exodusII manual: http://prod.sandia.gov/techlib/access-control.cgi/1992/922137.pdf