10 Krzysztof Olasek, Maciej Karczewski
4. MATLAB SCRIPT
Post-processing of CFD data was possible thanks to a program designed in MATLAB programming language. Fig. 1 shows the graphical user interface (GUI) of a working program. Algorithm of the main operation executed when running the script looks as follows:
- Reading the CFD velocity results exported from ANSYS CFX in the form of a text file. Text file contains information about the velocity for each node of the numerical model (4 values for each node - position in XY piane and 2 velocity components).
- Interpolation of obtained CFD data onto a regular Cartesian grid (original CFD nodes create an irregular mesh pattern). Interpolation has been applied in order to simplify further calculations.
- Displaying interpolated velocity map onto the screen (contour plot at the
left side of GUI panel in Fig. 1).
- Manuał choice of the size of integration curve (inside the Bounding Box
panel). For the presented test version of the program only a rectangular shape of the integral curve is possible. Exemplary curve is displayed on the contour plot in Fig. 1.
- Interpolation of velocity values onto the curves defined in previous step.
- Calculation of the velocity circulation by integration of the velocity over the chosen loop and finał calculations of lift coefficient basing on eguations (1) & (3).
CFD velocity field
[m]
E:\Suda\201 2 PIV - load extraclion\'IACA0Q12 - dane z CFD\1 A deg.csy
Fig. 1 GUI of MATLAB lift calculator with integration loop marked