PyAero
PyAero copied to clipboard
SU2 interface implementation
Developed and tested on NixOS 24.11, tested to some extent on Windows 10, both with SU2 8.2.0 from https://su2code.github.io/download.html (2025-07-08)
Notes to maintainers:
- on Linux, I had to run python with QT_QPA_PLATFORM=xcb (otherwise I had Wayland issues)
- on Windows, I sometimes got a broken pipe error when starting and aborting back and forth, but the functionality seemed to persist
- all my tests were run on relatively simple meshes produced by PyAero with default settings. in principle, the SU2 part can also be executed by simply providing a mesh file.
- I modified the meshing export such that the boundary tags actually use the TEXT of the input fields, not their name (I think this was intended, otherwise what's the point of the input?) - see 3rd commit
Open points (see FIXMEs in the code):
- I did not manage to patch the closeEvent properly to make it call abortSU2.
- Some airfoil descriptions (e.g. PARSEC) allow a nonzero y-value of the TE - in this case, the arc-tangent of that value (divided by the chord length) needs to be subtracted from the angle of attack to maintain the common definition of angle of attack being w.r.t. the chord line. I did not manage to find an easy way to get this information from the airfoil object (so I simply assume 0.0 for now). Note that if/when this value is extracted from airfoil information, it is impossible to (re)start the simulation without defining an airfoil in the tool.
- currently the Toolbox-method does not allow the user to pick custom paths for the working directory of SU2. (N.B.: The underlying class that handles SU2 does support this!)
- the method for aborting the simulation uses a rather brutal SIGKILL, but I did not manage any other way (in fact, not even SIGTERM seemed to do the job)