4.1.1. Remeshing with Key-Frame Meshes

In some analyses involving mesh deformation, the motion of various boundaries and sub-domains is known beforehand. Thus, the iteration or time step number at which unacceptable mesh quality will occur due to mesh motion is also known. A sequence of ‘key-frame’ meshes (of any mesh file type) corresponding to these instances of poor mesh quality can consequently be generated and applied during the analysis.

Once the sequence of key-frame meshes has been generated, they should be placed in a location that will be accessible during the analysis’ execution. The analysis definition is then modified to include one or more control conditions that will interrupt the solver at the iteration or time step at which a key-frame mesh should be inserted. A configuration is subsequently defined (unless this has already been done), and a remeshing definition is created with the following settings:

  • Set Option to User Defined.

  • Set the Activation Condition(s) to the previously created interrupt control condition(s).

  • Set the Location to the mesh region that will be replaced.

  • Set the External Command to the command that will be used to generate the replacement mesh file.

  • Set the Replacement File to the name of the file that will be generated by the external command.

The External Command is typically a shell script or batch file that completes the following tasks:

  • Determine which key-frame mesh to use. This will require parsing the run’s CFX-Solver Output file for the iteration or time step number, or the actual simulation time. Output generated from the cfx5mondata executable can also be parsed instead of the run’s CFX-Solver Output file. For details, see Exporting Monitor Data from the Command Line in the CFX-Solver Manager User's Guide.

  • Copy the key-frame mesh to the path the specified by the Replacement File setting.