Update use_custom_mesh authored by Adrien Crovato's avatar Adrien Crovato
...@@ -38,9 +38,9 @@ tbox.GmshExport(msh).save(msh.name) ...@@ -38,9 +38,9 @@ tbox.GmshExport(msh).save(msh.name)
**1.3 Creating a mesh morpher** **1.3 Creating a mesh morpher**
A mesh morpher can be used to deform the volume mesh in order to track the motion of a given boundary surface of that mesh. This is typically required for applications where a body immersed in the fluid can move or deform, such as aerostructural or optimization calculations. The morpher is instantiated using the tbox::MshDeform C++ class as, A mesh morpher can be used to deform the volume mesh in order to track the motion of a given boundary surface of that mesh. This is typically required for applications where a body immersed in the fluid can move or deform, such as aerostructural or optimization calculations. The morpher is instantiated using the tbox::MshDeform C++ class as,
```python ```python
morpher = tbox.MshDeform(msh, linsol, dim) morpher = tbox.MshDeform(msh, linsol, dim, nthrds=1, vrb=1)
``` ```
where `linsol` is a linear solver. In order to solve the linear elasticity equations to deform the mesh, an ILU preconditioned GMRES usually works well as linear solver: `linsol = tbox.Gmres(1, 1e-6, 30, 1e-8)`. More information about the available linear solvers can be found [here](use_custom_solver). where `nthrds` controls the number of threads, `vrb` controls the verbosity level and `linsol` is a linear solver. In order to solve the linear elasticity equations to deform the mesh, an ILU preconditioned GMRES usually works well as linear solver: `linsol = tbox.Gmres(1, 1e-6, 30, 1e-8)`. More information about the available linear solvers can be found [here](use_custom_solver).
The grid associated to the volume (fluid), and the fixed, moving and internal boundaries are added using The grid associated to the volume (fluid), and the fixed, moving and internal boundaries are added using
```python ```python
morpher.setField('fld') # volume grid morpher.setField('fld') # volume grid
... ...
......