|
FUN3D Analysis Interface Module (AIM)
FUN3D Analysis Interface Module (AIM)
|
A module in the Computational Aircraft Prototype Syntheses (CAPS) has been developed to interact (primarily through input files) with NASA LaRC's unstructured flow solver FUN3D [1]. FUN3D is a parallelized flow analysis and design suite capable of addressing a wide variety of complex aerodynamic configurations by utilizing a mixed-element, node-based, finite volume discretization. The suite can simulate perfect gas (both incompressible and compressible), as well as multi-species equilibrium and non-equilibrium flows. Turbulence effects may be represented through a wide variety of models. Currently only a subset of FUN3D's input options have been exposed in the analysis interface module (AIM), but features can easily be included as future needs arise.
Current issues include:
An outline of the AIM's inputs and outputs are provided in AIM Inputs and AIM Outputs, respectively.
Details on the use of units are outlined in AIM Units.
Details of the AIM's automated data transfer capabilities are outlined in FUN3D Data Transfer
FUN3D's primarily input file is a master FORTRAN namelist, fun3d.nml. To generate a bare-bones fun3d.nml file based on the variables set in AIM Inputs, nothing else besides the AIM needs to be provided. Since this will create a new fun3d.nml file every time the AIM is executed it is essential to set the Overwrite_NML input variable to "True". This gives the user ample warning that their fun3d.nml (if it exists) will be over written.
Conversely, to read and append an existing namelist file the user needs Python installed so that the AIM may be complied against the Python API library (and header file - Python.h). The AIM interacts with Python through a Cython linked script that utilizes the "f90nml" Python module; note, having Cython installed is not required. On systems with "pip" installed typing "pip install f90nml", will download and install the "f90nml" module.
The Cython script will first try to read an existing fun3d.nml file in the specified analysis directory; if the file does not exist one will be created. Only modified input variables that have been specified as AIM inputs (currently supported variables are outlined in AIM Inputs) are updated in the namelist file.
FUN3D has the ability to deform the volume mesh around an updated surface mesh (nodal numbering and count must remain the same). The AIM can make use of this capability to reuse an existing volume mesh after geometric changes have been made. The Mesh_Morph input variable (outlined in AIM Inputs) is the key switch to toggle this capability. If Mesh_Morph is set to True and a Mesh (volumetric only) is linked to the AIM, the AIM will make a copy of the mesh as opposed to just a symbolic link. Upon "un-linking" the Mesh, the AIM will project the original (or last linked) surface mesh onto any new geometry perturbations on additional invocations of the AIM; given the new geometry is topologically equivalent. This projected, updated surface mesh is written to a file(s) of form Proj_Name_body#.dat.
To invoke the volumetric deformation, FUN3D must be called with the --read_surface_from_file command line argument. Additionally if one plans to run FUN3D's adjoint solver, the --write_mesh Proj_Name argument should also be added to the flow solver execution. This will cause the flow solver to write out the updated deformed volume mesh; without this step the adjoint solver will use the unperturbed/undeformed volume mesh.
An example problem using the FUN3D AIM (coupled with a meshing AIM - TetGen) may be found at FUN3D AIM Example.
This software has been cleared for public release on 05 Nov 2020, case number 88ABW-2020-3462.