Skip to content

Program capable of producing a 3D mesh and body-force model input for SU2 analysis from Meangen input.

Notifications You must be signed in to change notification settings

EvertBunschoten/Meangen2BFM

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

32 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Meangen2BFM is a program which allows for the creation of 2D and 3D body-force and (future) blade computation meshes for axial turbomachinery analysis from Meangen input. The user specifies the machine type, number of stages, duty coefficients, performance parameters and blade thickness parameters and the program creates a 2D or 3D mesh, alongside the input file required for body-force analysis in SU2. A template of such an input configuration file can be found in the 'templates' folder.

For the program to work, installation of Parablade is required(the 'feature_BFM' branch), Meangen, GMesh and UMG2 and their installation location has to have been added to PATH and PYTHONPATH. The "gmsh" python module has to be installed in the used version of Python. The script "RunMe.sh" returns the lines which should be added to the .bashrc script, as well as the header line which should be replaced in Meangen2BFM.py.

A template of the inputfile to be used can be found in the 'templates' folder under the name 'M2P.cfg'. More detailed explanations on all the input options can be found in there.

To execute the program, the user has to execute the following command, where "inputfile.cfg" is the name of the input file, located in the current working directory.

Meangen2BFM.py inputfile.cfg

the program will initiate and start generating output folders for Meangen and Parablade, alongside a mesh suitable for body-force analysis or blade computation. Currently, full integration with SU2 is not yet functional, so SU2 has to be initiated manually.

To perform a body-force simulation, the SU2 "feature_turbo_bodyforce" branch has to be cloned on the user's machine. In the body-force template configuration file("BFM_comp.cfg"), the user can adjust several things regarding the body-force model. The first is the body-force option(BODY_FORCE). When selecting YES here and setting the BODY_FORCE_TYPE to VARIABLE_BF, the body-force model within SU2 will be used. The BODY_FORCE_ROTATION input asks for the rotation rate of the rotor rows of the machine in rpm, with the rotation axis being the positive x-axis. The other inputs are equivalent to more general SU2 inputs, such as inlet and outlet conditions and fluid parameters. Currently, only the 3D BFM in SU2 works properly. The final input for the body-force model is the BODY-FORCE_INPUT_FILENAME. Here, the file name of the body-force interpolation input file has to be specified. This file is automatically generated by Meangen2BFM.py and the file name can be changed in its input file.

To summarize, the full process of performing a body-force analysis from scratch is as follows:

Step 1: fill in Meangen2BFM input file by specifying all required design paramters as listed in the template file named M2P.cfg and move this file to the working directory.

Step 2: In the working directory, type

Meangen2BFM.py inputfile.cfg

in the terminal, where inputfile.cfg is the name of the Meangen2BFM input file. This step will generate the mesh and body-force interpolation file for SU2.

Step 3: Check the BFM_comp.cfg file which is generated by Meangen2BFM.py for the right boundary conditions, flow parameters, output file format and convergence targets. The user might want to use different values than the default values in the template file.

Step 4: For the body-force analysis to be initialized, the general command for SU2 CFD simulations can be used.

SU2_CFD BFM_comp.cfg

This will initialize the simulation and generate the flow field and convergence history files.

About

Program capable of producing a 3D mesh and body-force model input for SU2 analysis from Meangen input.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published