# Interactive Airfoil Optimization Using Parsec Parametrization and Adjoint Method
## 5 Results and Verification
### Xfoil Verification Computations: Compressible and Viscous Flow
\begin{table}
\begin{tabular}{c c c c c c c c c} \hline \hline  & \multicolumn{6}{c}{**Incompressible and Inviscid**} & \multicolumn{6}{c}{**Compressible and Viscous**} \\ \cline{2-10}
**Simulation** & **Original** & **Optimized** & **Absolute** & **Relative** & **Original** & **Optimized** & **Absolute** & **Relative** \\  & **Airfoil** & **Airfoil** & **Difference** & **Difference** & **Airfoil** & **Airfoil** & **Difference** & **Difference** \\ \hline \(\alpha\left[{}^{c}\right]\) & 0 & 0 & — & — & 0 & 0 & — & — \\ \(C_{y}\left[1\right]\) & 0.2137 & 0.3502 & 0.1365 & +63.9\% & 0.1480 & 0.2881 & 0.1401 & +94.7\% \\ \(C_{x}\left[1\right]\) & — & — & — & — & 0.00883 & 0.00885 & 0.00002 & +0.2\% \\ \(C_{y}/C_{x}\left[1\right]\) & — & — & — & — & 16.76 & 32.55 & 15.79 & +94.2\% \\ \(C_{M}[1]\) & \(-0.0578\) & \(-0.0778\) & \(-0.0200\) & \(-34.6\%\) & \(-0.0425\) & \(-0.0638\) & \(-0.0213\) & \(-50.1\%\) \\ \hline \(\alpha\left[{}^{c}\right]\) & 6.2 & 6.2 & — & — & 6.2 & 6.2 & — & — \\ \(C_{y}\left[1\right]\) & 0.9869 & 1.1215 & 0.1346 & +13.6 \% & 0.8108 & 0.9415 & 0.1307 & +16.1\% \\ \(C_{x}\left[1\right]\) & — & — & — & — & 0.01347 & 0.01337 & \(-0.00010\) & \(-0.7\%\) \\ \(C_{y}/C_{x}\left[1\right]\) & — & — & — & — & 60.20 & 70.40 & 10.20 & +16.9\% \\ \(C_{M}[1]\) & \(-0.0778\) & \(-0.0974\) & \(-0.0196\) & \(-25.2\%\) & \(-0.0449\) & \(-0.0641\) & \(-0.0192\) & \(-42.8\%\) \\ \hline \hline \end{tabular}
\end{table} 
Table 4: Xfoil results for NREL S809 airfoil—adjoint optimization. From the comparison of the adjoint optimization results with [PERSON] and [PERSON]'s results [13], it is possible to conclude that the adjoint optimization in this paper yielded very similar or even better results; however, it obtained them with a computational cost that was more than three orders of magnitude lower. The computation time of the adjoint optimization is 11 seconds, compared to the 272 minutes needed by the GA optimization published in [13]. The computation time could be further reduced to less than 5 seconds by increasing the iteration step and lowering the number of iterations accordingly. This can be easily carried out with no risk of losing stability, as the initially chosen iteration step is very small. The number of iterations in the adjoint optimization should be somewhere between 10 and 50, as stated in [3]; therefore, after doubling the current iteration step and halving the current number of iterations, the optimization would still obey those recommendations. Another way of lowering the computational complexity of the optimization is by coarsening the airfoil paneling. As matrix A is a full matrix with no special properties, the cost of solving the equations is proportional to \((\text{N}+1)^{3}\). Thus, by lowering the number of panels from 300 (a very fine resolution used throughout this paper) to 200 (which is still an acceptable resolution), it is possible to lower the optimization cost by more than a factor of 3, achieving a computation time that is 4 orders of magnitude shorter when compared to [13]. After applying the suggestions above, by setting the iteration step to \(\zeta_{0}=0.0005\), the number of iterations to 20, and the number of panels to 200, the computation time dropped to two seconds, while very similar optimization results were achieved (\(\Delta C_{y}^{REL}=58\) % for \(0\) deg AoA). All the computations were carried out using the Intel Core i7-12700H processor (Intel, Santa Clara, CA, USA). The panel method simulations in the optimization were performed in serial (due to the nature of the adjoint method making consecutive changes to the design), but the MATLAB R2023b solver used for solving systems of LAEs, which are by far the most computationally expensive part of the adjoint method, incorporated parallel computation. The abovementioned data and computation times prove that the adjoint method can be highly computationally effective and, despite the simplifications applied during the development of the optimization code, can vastly improve the efficiency of the initial design.