Source-linked AI summary
Prediction of Aerodynamic Flow Fields Using Convolutional Neural Networks
Yaser Afshar, Saakaar Bhatnagar, Shaowu Pan, Karthik Duraisamy, Shailendra Kaushik
TL;DR
The paper addresses the computational cost and user intervention required for flow-field analysis in engineering design. It develops a CNN framework that predicts non-uniform steady RANS flow fields around airfoils from geometry and free-stream conditions, achieving four-orders-of-magnitude speedups over the RANS solver with mean square error below 10% across the flow field.
Problem
Flow-field analysis is computationally intensive and time-consuming, making engineering design exploration tedious, costly, and intervention-heavy.
Method
A convolutional neural network predicts entire non-uniform steady RANS flow fields from airfoil geometry, angle of attack, and Reynolds number.
Results
Four orders of magnitude faster than the RANS solver, the network predicted flow fields with mean square error below 10% over the entire flow field.
Takeaways & Limitations
The CNN framework can enable near-real-time simulation-based aerodynamic design and optimization across variable flow conditions and unseen airfoil shapes.
Takeaways & Limitations
Interpolation errors were observed when reconstructed data were compared with CFD data during data preparation.
Abstract
from arXiv · showhide
An approximation model based on convolutional neural networks (CNNs) is proposed for flow field predictions. The CNN is used to predict the velocity and pressure field in unseen flow conditions and geometries given the pixelated shape of the object. In particular, we consider Reynolds Averaged Navier-Stokes (RANS) flow solutions over airfoil shapes. The CNN can automatically detect essential features with minimal human supervision and shown to effectively estimate the velocity and pressure field orders of magnitude faster than the RANS solver, making it possible to study the impact of the airfoil shape and operating conditions on the aerodynamic forces and the flow field in near-real time. The use of specific convolution operations, parameter sharing, and robustness to noise are shown to enhance the predictive capabilities of CNN. We explore the network architecture and its effectiveness in predicting the flow field for different airfoil shapes, angles of attack, and Reynolds numbers.
1 Introduction
Flow-field simulation is computationally intensive, motivating data-driven CNN approximations that learn spatial features and predict aerodynamic fields across geometries and conditions.
- Flow-field analysis is computationally intensive and makes engineering design tedious, costly, and dependent on substantial user intervention.
- Data-driven methods can augment or replace expensive high-fidelity analyses with less expensive approximations.
- CNNs learn high-level features from data with strong spatial and temporal correlations, offering flexible shape representation and scalability.
- Earlier CNN-based fluid studies demonstrated rapid flow estimation but often emphasized qualitative velocity fields or reduced outputs rather than complete aerodynamic characteristics.
- The present work contributes a framework for predicting flow fields around different geometries under variable flow conditions.
2 Methodology
The methodology combines validated compressible RANS simulations with structured C-meshes and a CNN designed to predict complete airfoil flow fields from geometry and free-stream conditions.
- 2.1 CFD Simulation: OVERTURNS solves compressible RANS equations using preconditioned dual-time integration, implicit approximate factorization, MUSCL discretization, and turbulence and transition models.
- 2.1 CFD Simulation: Simulations use S805, S809, and S814 airfoils on structured 394×124 C-meshes around the bodies.
- 2.1 CFD Simulation: The study varies Reynolds numbers from 0.5 × 10^6 to 3 × 10^6 and angles of attack from 0° to 20°.
- 2.2 Convolutional Neural Networks: The CNN predicts the entire non-uniform turbulent flow field using airfoil shape, angle of attack, and Reynolds number as inputs.
2.3 Network Structure
The proposed encoder-decoder CNN uses shared encoding and decoding to map airfoil geometry and flow conditions to pressure and velocity fields while reducing computational cost.
- 2.3 Network Structure: The encoder-decoder architecture stacks convolutional layers, a dense layer, and another stack of convolutional layers.
- 2.3 Network Structure: Figure 3 specifies forward operations, kernel sizes, filter counts, unit strides, and Swish activations throughout the network except its output layer.
- 2.3 Network Structure: Shared decoder weights extract high-level representations for pressure and velocity components, using almost 50% fewer parameters than separated decoders.
- 2.3 Network Structure: The network maps Reynolds number, angle of attack, and a 150 × 150 2D airfoil shape representation to pressure and velocity outputs.
2.4 Geometry Representation
The study surveys geometric representations used to capture shape details and classify points into formats suitable for learning.
- 2.4 Geometry Representation: Geometric learning approaches include implicit functions for image reconstruction and methods for shape representation and classification.
2.5 Signed Distance Function
The signed distance function represents airfoil geometry on a Cartesian grid by encoding each point’s shortest distance and whether it lies inside or outside the object. The resulting SDF is generated from the structured C-mesh and used as the CNN’s geometry input.
- The SDF assigns each point its minimum distance to the airfoil boundary, with the sign indicating whether the point is inside or outside.Positive values are outside, zero is on the boundary, and negative values are inside.
- The S814 SDF is plotted on a 150×150 Cartesian grid, with airfoil boundary points shown in white.
- The airfoil’s discrete structured C-mesh is represented on a Cartesian grid, with mesh points in black, grid points in red, and boundary points in blue.
- Distances from Cartesian grid points to boundary points are computed using the fast marching method, while the sign is determined from nearby boundary normals.
- After preprocessing, the SDF feeds the encoder-decoder CNN, whose convolutional layers extract geometry features from it.
2.6 Convolutional Encoder-Decoder Approach
The convolutional encoder-decoder learns a low-dimensional representation of the input SDF and decodes it into pressure and velocity fields. Convolutional filters and nonlinear activations support geometry-feature extraction and field reconstruction.
- The encoder and decoder use convolution layers and filters to learn geometry features from the input SDF.
- Each convolutional layer uses 300 filters, producing 300 activation maps that encode the input in a low-dimensional parameter space.
- Swish nonlinear activations wrap the convolutions, using x·σ(βx) with β either constant or trainable.
- The decoding operation reverses the encoding convolution’s passes and maps the encoded high-level features to pressure and velocity components.
2.7 Data Preparation
The dataset contains RANS simulations for three airfoils, with randomly selected test points spanning the feature space. CFD fields are interpolated and normalized on a 150 × 150 Cartesian grid before model use, introducing measurable interpolation error.
- 252 RANS simulations cover the S805, S809, and S814 airfoils, with 85 percent used for training and the remainder for testing.
- Test points are selected uniformly at random in feature space to provide an unbiased evaluation while tuning hyperparameters.
- The S814 example uses an RANS velocity field at angle of attack α = 9° and Reynolds number Re = 3 × 10^6.
- CFD data are interpolated from the structured mesh onto a 150 × 150 Cartesian grid containing the SDF, using triangulation-based scattered-data interpolation.
- After interpolation, points inside the airfoil are masked and velocity is set to zero, while standard-score normalization rescales the data.
- Comparing interpolated and original fields shows evidence of interpolation errors.
2.8 Network Training and Hyper-parameter Study
Training updates CNN weights through minibatch feed-forward and back-propagation while minimizing a combined loss with regularization. Hyperparameters are selected empirically through grid search based on generalization and prediction accuracy.
- Each training iteration applies feed-forward and back-propagation to a batch while learning network weights.
- The total loss combines two task-specific loss functions with L2 regularization.
- The loss uses mean squared error and gradient-sharpening loss, with central differences used for gradient sharpening.
- For separated decoding, the loss functions are defined for a variable X representing U, V, or P.
- Hyperparameters are chosen by grid search over value intervals, comparing trained networks by generalization tendency and truth–prediction differences.
3 Results and Discussion
The CNN is evaluated across varying airfoil shapes, angles of attack, and Reynolds numbers, with results compared against CFD truth using MAPE and visual field agreement. Shared decoding and gradient sharpening improve prediction sharpness and wake-region errors, while tests on unseen geometries indicate good generalization.
- Model validation: The evaluation measures prediction error with MAPE in both the airfoil wake and the entire flow field, excluding 2–3% of points exceeding 100% error as outliers.The wake is defined over x ∈ [1.1, 1.5], y ∈ [−0.5, 0.5], while the entire field spans x ∈ [−0.5, 1.5], y ∈ [−0.5, 0.5].
- Angle of attack variation: At fixed S805 geometry and Re = 1 × 10^6, the network is trained on 21 angle-of-attack cases and tested on four unseen angles.The held-out angles are α = 2.5°, 7.5°, 12.5°, and 19.5°; the α = 12.5° velocity-field prediction agrees visually with CFD truth.
- Gradient sharpening: Gradient sharpening reduces wake-region errors by 20% or more for x-velocity and pressure predictions while producing sharper full-field predictions.The comparison uses predictions with and without gradient sharpening for S809 and S814.
- Shape, angle of attack, and Reynolds number variation: The predicted and ground-truth velocity fields show good agreement across S809 and S814 cases spanning different angles of attack and Reynolds numbers.The reported comparisons include S809 at α = 1° and Re = 1 × 10^6 and S814 at α = 19° and Re = 3 × 10^6.
- Prediction for unseen airfoil shapes: The network shows good generalization properties when predicting flow fields for three unseen airfoil geometries.The unseen geometries are an averaged S809–S814 shape, S807, and S819.
4 Conclusions and Future Work
The study develops a CNN approximation model for aerodynamic flow fields, using shared encoding and decoding to predict RANS velocity and pressure fields efficiently. Predictions were four orders of magnitude faster than the RANS solver, while limitations remain for unseen airfoil families.
- Shared encoding and decoding was more computationally efficient than separated alternatives.
- The CNN uses Reynolds number, angle of attack, and signed-distance airfoil geometry as inputs to predict velocity and pressure fields.
- Four orders of magnitude faster than the RANS solver, network predictions achieved mean square error levels below 10% over the entire flow field.
- Gradient sharpening improved prediction accuracy, and predictions were possible with a small number of training simulations.
- CNNs enabled near-real-time simulation-based design and optimization, but training on three airfoil shapes reduced generalization to unseen geometries from other families.
Appendix: Governing equations
The governing-equation appendix presents compressible RANS equations derived by ensemble averaging conservation laws and closed with the Spalart–Allmaras turbulence model. The closure estimates eddy viscosity by solving a transport equation for a working variable at each iteration.
- RANS equations are derived by ensemble-averaging the conservation equations of mass, momentum, and energy for compressible flow.
- The notation defines mean velocity, density, pressure, Reynolds stress, heat capacity, and turbulent kinetic energy, with Favre averaging given by ˆξ = ρξ/¯ρ.
- The Spalart–Allmaras closure uses the Boussinesq hypothesis to represent turbulence through an eddy viscosity and solves a transport equation for a working variable.
- The turbulent eddy viscosity is computed as µt = ¯ρ˜νfv1.
- In Equation 19, the first right-hand-side term is production of ˜ν, while the second represents dissipation.