Hostname: page-component-6766d58669-7cz98 Total loading time: 0 Render date: 2026-05-15T05:38:47.492Z Has data issue: false hasContentIssue false

A transformer-based synthetic-inflow generator for spatially developing turbulent boundary layers

Published online by Cambridge University Press:  14 February 2023

Mustafa Z. Yousif
Affiliation:
School of Mechanical Engineering, Pusan National University, 2, Busandaehak-ro 63beon-gil, Geumjeong-gu, Busan 46241, Republic of Korea
Meng Zhang
Affiliation:
School of Mechanical Engineering, Pusan National University, 2, Busandaehak-ro 63beon-gil, Geumjeong-gu, Busan 46241, Republic of Korea
Linqi Yu
Affiliation:
School of Mechanical Engineering, Pusan National University, 2, Busandaehak-ro 63beon-gil, Geumjeong-gu, Busan 46241, Republic of Korea
Ricardo Vinuesa
Affiliation:
FLOW, Engineering Mechanics, KTH Royal Institute of Technology, Stockholm, Sweden
HeeChang Lim*
Affiliation:
School of Mechanical Engineering, Pusan National University, 2, Busandaehak-ro 63beon-gil, Geumjeong-gu, Busan 46241, Republic of Korea
*
Email address for correspondence: hclim@pusan.ac.kr

Abstract

This study proposes a newly developed deep-learning-based method to generate turbulent inflow conditions for spatially developing turbulent boundary layer (TBL) simulations. A combination of a transformer and a multiscale-enhanced super-resolution generative adversarial network is utilised to predict velocity fields of a spatially developing TBL at various planes normal to the streamwise direction. Datasets of direct numerical simulation (DNS) of flat plate flow spanning a momentum thickness-based Reynolds number, $Re_\theta = 661.5\unicode{x2013}1502.0$, are used to train and test the model. The model shows a remarkable ability to predict the instantaneous velocity fields with detailed fluctuations and reproduce the turbulence statistics as well as spatial and temporal spectra with commendable accuracy as compared with the DNS results. The proposed model also exhibits a reasonable accuracy for predicting velocity fields at Reynolds numbers that are not used in the training process. With the aid of transfer learning, the computational cost of the proposed model is considered to be effectively low. Furthermore, applying the generated turbulent inflow conditions to an inflow–outflow simulation reveals a negligible development distance for the TBL to reach the target statistics. The results demonstrate for the first time that transformer-based models can be efficient in predicting the dynamics of turbulent flows. They also show that combining these models with generative adversarial networks-based models can be useful in tackling various turbulence-related problems, including the development of efficient synthetic-turbulent inflow generators.

Information

Type
JFM Papers
Creative Commons
Creative Common License - CCCreative Common License - BY
This is an Open Access article, distributed under the terms of the Creative Commons Attribution licence (http://creativecommons.org/licenses/by/4.0/), which permits unrestricted re-use, distribution and reproduction, provided the original article is properly cited.
Copyright
© The Author(s), 2023. Published by Cambridge University Press.
Figure 0

Figure 1. Schematic of (a) training procedure for the transformer, (b) training procedure for the MS-ESRGAN and (c) turbulent inflow generation using the proposed DLM.

Figure 1

Figure 2. Architecture of the transformer. The dashed line box represents the scaled dot-product attention.

Figure 2

Figure 3. Architecture of MS-ESRGAN. (a) The generator, where $\gamma$ is the residual scaling parameter which is set to 0.2 in this study, and (b) the discriminator.

Figure 3

Figure 4. Instantaneous streamwise (a) velocity and (b) vorticity fields at $Re_\theta = 661.5$, for three different instants. Reference (DNS) and predicted (DLM) data are shown.

Figure 4

Figure 5. Instantaneous streamwise (a) velocity and (b) vorticity fields at $Re_\theta = 905.7$, for three different instants. Reference (DNS) and predicted (DLM) data are shown.

Figure 5

Figure 6. Instantaneous streamwise (a) velocity and (b) vorticity fields at $Re_\theta = 1362.0$, for three different instants. Reference (DNS) and predicted (DLM) data are shown.

Figure 6

Table 1. Shape factor values of the reference (DNS) and predicted (DLM) data.

Figure 7

Figure 7. Probability density functions of the velocity components as a function of the wall-normal distance. The shaded contours represent the results from the DNS data and the dashed ones represent the results from the predicted data. The contour levels are in the range of 20 %–80 % of the maximum p.d.f. with an increment of 20 %: (ac$Re_\theta = 661.5$; (df$Re_\theta = 905.7$; (gi$Re_\theta = 1362.0$.

Figure 8

Figure 8. Turbulence statistics of the flow at $Re_\theta = 661.5$: (a) mean streamwise velocity profile; (b) r.m.s. profiles of the velocity components; (c) Reynolds shear stress profile.

Figure 9

Figure 9. Turbulence statistics of the flow at $Re_\theta = 905.7$: (a) mean streamwise velocity profile; (b) r.m.s. profiles of the velocity components; (c) Reynolds shear stress profile.

Figure 10

Figure 10. Turbulence statistics of the flow at $Re_\theta = 1362.0$: (a) mean streamwise velocity profile; (b) r.m.s. profiles of the velocity components; (c) Reynolds shear stress profile.

Figure 11

Figure 11. Premultiplied spanwise wavenumber energy spectra of the velocity components as a function of the wall-normal distance and the spanwise wavelength. The shaded contours represent the results from the DNS data and the dashed ones represent the results from the predicted data. The contour levels are in the range of 10 %–90 % of the maximum $k_z^+ \varPhi _{\alpha \alpha }^+$ with an increment of 10 %: (ac$Re_\theta = 661.5$; (df$Re_\theta = 905.7$; (gi$Re_\theta = 1362.0$.

Figure 12

Figure 12. Frequency spectra of the velocity components as a function of the wall-normal distance and the frequency. The shaded contours represent the results from the DNS data and the dashed ones represent the results from the predicted data. The contour levels are in the range of 10 %–90 % of the maximum $\phi _{\alpha \alpha }^+$ with an increment of 10 %: (ac$Re_\theta = 661.5$; (df$Re_\theta = 905.7$; (gi$Re_\theta = 1362.0$.

Figure 13

Figure 13. Instantaneous streamwise (a) velocity and (b) vorticity fields at $Re_\theta = 763.8$, for three different instants. Reference (DNS) and predicted (DLM) data are shown.

Figure 14

Figure 14. Instantaneous streamwise (a) velocity and (b) vorticity fields at $Re_\theta = 1155.1$, for three different instants. Cases 1 and 2 represent the prediction using the transformer that is trained for the flow at $Re_\theta = 905.7$ and 1362.0, respectively.

Figure 15

Figure 15. Turbulence statistics of the flow at $Re_\theta = 763.8$: (a) mean streamwise velocity profile; (b) r.m.s. profiles of the velocity components; (c) Reynolds shear stress profile.

Figure 16

Figure 16. Turbulence statistics of the flow at $Re_\theta = 1155.1$. Cases 1 and 2 represent the prediction using the transformer model trained for the flow at $Re_\theta = 905.7$ and 1362.0, respectively. (a) Mean streamwise velocity profile; (b) r.m.s. profiles of the velocity components; (c) Reynolds shear stress profile.

Figure 17

Figure 17. Instantaneous streamwise (a) velocity and (b) vorticity fields at $Re_\theta = 1502.0$ for three different instants. Reference (DNS) and predicted (DLM) data are shown.

Figure 18

Figure 18. Turbulence statistics of the flow at $Re_\theta = 1502.0$. (a) mean streamwise velocity profile; (b) r.m.s. profiles of the velocity components; (c) Reynolds shear stress profile.

Figure 19

Figure 19. Premultiplied spanwise wavenumber energy spectra of the velocity components as a function of the wall distance and wavelength. The shaded contours represent the results from the DNS data; the dashed-black contours represent the results from the predicted velocity data at $Re_\theta = 763.8$ and 1502.0; the dashed-brown and grey contours represent the results from the velocity data at $Re_\theta = 1155.1$ predicted using the transformer model trained for the flow at $Re_\theta = 905.7$ and 1362.0, respectively. The contour levels are in the range of 10 %–90 % of the maximum $k_z^+ \varPhi _{\alpha \alpha }^+$ with an increment of 10 %: (ac$Re_\theta = 763.8$; (df$Re_\theta =1155.1$; (gi$Re_\theta =1502.0$.

Figure 20

Figure 20. The $L_2$ norm error of the predicted velocity fields: (a) streamwise velocity; (b) wall-normal velocity; (c) spanwise velocity. Cases 1 and 2 represent the results from the velocity data at $Re_\theta = 1155.1$ predicted using the transformer model trained for the flow at $Re_\theta = 905.7$ and 1362.0, respectively.

Figure 21

Figure 21. Isosurfaces of instantaneous vortical structures ($Q$-criterion$= 0.54U_\infty ^2/\delta _0^2$) from the inflow–outflow simulation coloured by the streamwise velocity.

Figure 22

Figure 22. Turbulence statistics from the inflow–outflow simulation at $Re_\theta = 1400$ compared with the DNS results: (a) mean streamwise velocity profile; (b) Reynolds shear stress profile.

Figure 23

Figure 23. Turbulence statistics from the inflow–outflow simulation at $Re_\theta = 1530$ compared with the results of Lund et al. (1998) and Spalart (1988): (a) mean streamwise velocity profile; (b) Reynolds shear stress profile.

Figure 24

Figure 24. Evolution of the shape factor and skin-friction coefficient in the inflow–outflow simulation compared with the results of the DNS (Lund et al.1998; Spalart 1988): (a) shape factor; (b) skin-friction coefficient.