![]() |
GeMA
The GeMA main application
|
To complete our tutorial, this section presents a simple multiphysics problem coupling temperature and stress/deformation calculations. The simulated scenario is given in Figure 17, where a bar is fixed on its right side and left free to move in the other directions. The top border is kept at a constant temperature of 100.0 degrees Celsius while the other borders are isolated, with the exception of a small segment at the bottom border that is heating the bar with a heat flux of 100W/m2. The bottom half of the bar has a thermal expansion factor alpha
five times bigger than the top half, forcing the bar to bend up while heated at the bottom.
Since by now the reader should already be able to understand a GeMA model, only parts of it are presented here with comments only on relevant constructions. In particular, the mesh generation is not included. It uses the Mesh Lib functions to create a regular grid mesh, assigning different materials to the top and bottom halfs of the grid. The complete code for the simulation can be downloaded at the following link:
Since our simulation now includes also deformation analysis, the set of state variables includes deformations on the x and y directions through a vector state variable, as well as the temperature.
The stress physics calculates the stress tensor components sxx
, syy
and sxy
both at the nodes and at Gauss points. Since on this problem we desire to present stress results in terms of principal stresses, their values can be calculated by user functions provided by the Stress Functions Lib.
To enable deformation calculations, the property set now includes the materials elasticity modulus and Poisson ratio. The thermal expansion factor is also given. Notice that now the value set contains two rows, one for the top part of the bar and another for the bottom one.
This simulation requires three different boundary conditions. The first one, Tbc1
, applies a fixed temperature condition to the top of the bar. The second one, Tbc2
, applies a fixed heat flux condition to heat a bar segment on its bottom. Notice that the prescribed heat flux value is negative since heat is entering the cells. Finally, the third boundary condition, ubc
, is used to prescribe a zero node displacement for nodes at the bar's right border.
This multiphysics simulation requires a set of three physics for temperature calculation, deformation calculation and for the coupling of both of them. Some points worthy of notice are:
properties
. This is needed since this physics expects the element width to be a property named w
and our model names it as t
, the name expected by the temperature physics;stressMode
option tells the physics that stresses should be recovered at both nodes and Gauss points;referenceT
field.The orchestration script is very similar to the one used in our previous heat conduction example. Notice that now the first parameter to fem.solve()
includes the set of three physics defined above.
When calling the io.printMeshNodeData()
process, notice that it includes node stresses (S
) calculated by the mechanical physics and that this attribute was not included in the mesh definition (see the simulation files). When recovering stresses, the mechanical physics will add this attribute to the mesh automatically if it was not defined by the user. In a similar way, the io.printMeshGaussData()
process is used to print information recovered on Gauss points.
Finally, the io.saveMeshFile()
process now receives a second table with the set of Gauss attributes to be saved and a third with specific options for the neutral file format, enabling the inclusion of a deformation section in the file.
Running the simulation will produce a neutral file that can be opened in the Pos3D software. Figure 18 shows the bar deformation together with the resulting temperature distribution. Figure 19 shows the resulting principal stresses.
Go to the next section, previous section or return to the index.