Download as pdf or txt
Download as pdf or txt
You are on page 1of 7

Available online at www.sciencedirect.

com

Procedia Engineering 31 (2012) 9 – 15

International Conference on Advances in Computational Modeling and Simulation

Accurate and robust CFD algorithms applied to 3D arbitrary


polyhedral grids
Zhongliang Kang*, Chao Yan
National Laboratory for CFD, Beihang University, Beijing, 100191 China

Abstract

A parallel, accurate, robust and grid-transparent CFD solver was developed to solve compressible flow on 3D
arbitrary polyhedral grids. To improve spacial accurate, a constrained least-squares reconstruction method is
developed. To accelerate convergence, a matrix free implicit method GMRES+LU-SGS, and a parallel method using
OpenMP are presented on shared-memory parallel systems with help of a special grid reordering technique. Several
typical test cases, including subsonic, transonic and hypersonic flows, prove that the resulting solver performs fast,
accurate and robust.

© 2011 Published by Elsevier Ltd. Selection and/or peer-review under responsibility of Kunming
University of Science and Technology Open access under CC BY-NC-ND license.

Keywords: unstructured grids; polyhedral; constrained reconstruction; GMRES; OpenMP; grid-transparent

1. Introduction

3D arbitrary polyhedral grids used in CFD may consist of any element type, including tetrahedral,
hexahedral, pyramid and prism, as well as arbitrary mixtures of various polyhedral cells. It is an effective
way to make use of dominance of each grid type.
Compare with higher-order spacial discretization methods, second-order accuracy is much more useful
in engineering calculations considering many factors (i.e. efficiency and robustness). For arbitrary
polyhedral grids, to obtain second-order is even much difficult[1,2]. In the present paper, a constrained
reconstruction method[3] is given to improve spacial accuracy.
In addition, discretizations with 3D arbitrary polyhedral grids can lead to larger memory requirements

* Corresponding author. Tel.: +86-13811825893; fax: +86-10-82317019.


E-mail address: KZL929@163.com.

1877-7058 © 2011 Published by Elsevier Ltd. Open access under CC BY-NC-ND license.
doi:10.1016/j.proeng.2012.01.983
10 Zhongliang Kang and Chao Yan / Procedia Engineering 31 (2012) 9 – 15

and slower computational rates than with structured-grid methods, for unstructured data sets have to be
used. To accelerate convergence, a parallel, matrix free GMRES+LU-SGS implicit scheme is used in the
present work.

1. Spatial discretisation

The solved governing equations are 3D unsteady compressible Navier-Stokes equations without the
source term. More detail description about it can be found in Ref. [4]. The solution method is based on
the cell-centered finite volume method, in which the control volumes are identical with the grid cells and
the flow variables are associated with the centres of the grid cells. All algorithms in this paper treat
different cell types in the same way, so they are grid-transparent and are appropriate to 3D arbitrary
polyhedral grids.
The approximate Riemann problem of convective fluxes is solved at each grid face by Roe¶s FDS
scheme[5]. To obtain second-order accuracy, the left and right states of each face are obtained by
extrapolating the control-volume values based on a reconstructed gradient, which is advanced by Barth
and Jespersen[6].
In the present work, a constrained reconstruction method to approximate discrete gradients at cell
centers is given based on least-squares method. The least-squares approach is based upon the use of a
first-order Taylor series proximation between cell I and its stencils (constructed from neighbors of
the cell, or even enlarge by neighbors of neighbors to avoid ill-conditioning matrix). For example,
the solution of stencil J can be written as
UJ U I  ’U I ˜ rIJ (1)
where U denotes any flow variable, ’U I denotes the gradient of U at cell centre I, r represents the
vector extending from cell-centroid to face-midpoint,
If U I is regarded as unknown and Eq. (1) is applied to all stencils of I, and boundary stencil (if
exist) is regarded as equality constraint, the resulting constrained least-squares problem can be
written as
ª T F,I 1 T F,I 1'xF,I 1 T F,I 1'yF,I 1 T F,I 1'zF,I 1 º ªT F,I 1U F,1 º
«     » «  »
« »ª U º « »
« T F,Ip T F,Ip 'xF,Ip T F,Ip 'yF,Ip T F,Ip 'zF,Ip » « » «T F,IpU F, p » (2)
« » «w xU » « »
«                 » «w U » «  »
« T I1 T I 1'xI 1 T I 1'yI 1 T I 1'z I 1 » « y » « T IJ U1 »
« » ¬w zU ¼ I « »
«     » «  »
« T T ' x T ' y T ' z » « T U »
¬ Iq Iq Iq Iq Iq Iq Iq ¼ ¬ Iq q ¼
The first p rows are related to stencils of boundary conditions and must be satisfied exactly, while
the following q rows can be satisfied approximatively. T stands for some weighting coefficient,
which is given by
m
T IJ rIJ (3)
In this work, inverse-distance weighting is used (m=1). The importance of weighting for highly-
stretched grids near curved boundaries was demonstrated in Ref. [7].
Zhongliang Kang and Chao Yan / Procedia Engineering 31 (2012) 9 – 15 11

Eq. (2) can be solved by elimination approach or by weighting approach[3]. In the present application,
elimination approach is adopted at most cells which have only one boundary face, and weighting
approach is adopted at corner cells which have more than one boundary face.

2. Temporal discretisation

The spatial discretization leads to a system of coupled ordinary differential equations in time. An
implicit scheme of it can be obtained by the following discretization
ª VI I § wR · º n (4)
«  ¨¨ ¸¸ » 'QI  RIn , 'QIn QIn1  QIn
¬ 't I © wQ ¹ I ¼

where V represents the volume, I stands for identity matrix, R denotes the residual, and Q denotes
conservative variables, the term in square brackets on the left-hand side is referred to as implicit
operator.
The linear system (4) is solved approximately at each time-step using GMRES method with LU-SGS
as preconditioner. Since we are strictly concerned with the steady-state solution, 't could be taken as
infinity and the equation simplified to Newton's method. However, in most practical cases this is not
possible due to the highly non-linear nature of the residual. Therefore, the time-step is gradually increased
to infinity as the iteration proceeds.
In general, the initial flow solution is far from the steady state, so we start firstly with a robust LU-
SGS implicit scheme to get a better initial solution and then switch to GMRES with LU-SGS as
preconditioner.
To save memory and operation, GMRES method allows us to circumvent an explicit computation and
storage of the flux Jacobian. This is because GMRES algorithm rely only on the result of matrix-vector
products which can be approximated without forming the matrix explicitly by 1-order finite difference as
wR R Q  hv  R Q (5)
v|
wQ h

where v is some vector, h is a small value which has to be chosen with some care in order to minimize the
numerical error[8].
In addition, OpenMP method is used to achieve parallelization on shared-memory system structure[9].
Before starting iteration, a special grid reordering process [10] should be carried out firstly, for that the
resulting hyperplanes are needed for the implement of both OpenMP and LU-SGS method.

3. Numerical Results

To test above algorithms, several typical cases are selected, including subsonic, transonic and
hypersonic flows.

3.1. Subsonic flow over flat plate

The subsonic laminar flow over a flat plate is a good test case for constrained reconstructions because
of the existence of Blasius solution which can test the velocity and temperature distribution rigorously.
The grids are shown in Fig. 1, which consists of 14715 hexahedral and 13554 prisms. The Mach number
is 0.3, the Reynolds number is 1.0h105 based on the plate length, and the wall is regard as adiabatic.
12 Zhongliang Kang and Chao Yan / Procedia Engineering 31 (2012) 9 – 15

Fig. 1 Grids of flat plate. (a) surface grids; (b) amplificatory show nearby start position of the wall

Fig. 2 shows us that numerical results agree very well with theory solutions, which proves that
algorithms developed in this work are accurate and reliable. In addition, even though the stretching ratio
of grids reaches to 10-4 near the wall, and grids are badly uniform at the interface of different cell type,
the solver performs a good robustness.

Fig. 2 Numerical results of flat plate. (a) u-velocity profile at x/L=0.5; (b) skin-friction factor along flat plate

3.2. Transonic flow over ONERA M6 wing

ONERA M6 wing is a classic CFD validation case because of its simple geometry combined with
complexities of transonic flow (i.e. local supersonic flow, shocks, and turbulent boundary layers
separation). The grids are shown in Fig. 3, which consists of 125370 hexahedral, 369240 prisms, 18326
pyramids and 1736410 tetrahedral. Flow solution is presented at a Mach number of 0.8395, a Reynolds
number of 1.17h107 based on the chord length, and an attack angle of 3.06嘙 The wall is regard as
adiabatic. Spalart-Allmaras turbulence model is used.
Zhongliang Kang and Chao Yan / Procedia Engineering 31 (2012) 9 – 15 13

Fig. 3 Grids of ONERA M6 wing. (a) surface grids; (b) amplificatory show nearby the wing

The residual convergence history for 1, 2, 4, 8 and 12 threads is shown in Fig. 4a. The convergence
history of 1 thread proves that above GMRES+LU-SGS method can perform much robust and efficient.
Compare with 1 thread, 2, 4, 8 and 12 threads can speed up 1.9, 3.3, 6.1 and 8.0 times respectively. The
pressure distribution for wing section at 65% semispan is shown in Fig. 4b. The numerical results agree
very well with experiments.

Fig. 4 Results of ONERA M6 wing. (a) residual convergence history; (b) pressure distribution for wing section at 65% semispan

3.3. Hypersonic flow over hollow cylinder/flare

To verify the ability of obtaining strong discontinuity, hypersonic flow over hollow cylinder/flare is
selected because of the existence of some strong shocks and a large separation region. The model is
described detailedly in Ref. [11]. The grids are shown in Fig. 5, which consists of 97265 hexahedral and
55830 prisms. To test reliability of the solver, the surface of different cell type is set nearby separation
region and through all shocks. The Mach number is 5, the Reynolds number is 0.38h106 based on the
cylinder length, and the wall temperature is 290 K.
14 Zhongliang Kang and Chao Yan / Procedia Engineering 31 (2012) 9 – 15

Fig. 5 Grids of hollow cylinder/flare. (a) surface grids; (b) amplificatory show nearby the corner

From Fig. 6a, a large separation region can be observed clearly extending from the separation shock to
the reattachment shock, which converge above the flare. The shocks can be obtained sharply inside one or
two grids, and is very smooth at the position of different grid cell type meet. The computed separation is
at X/LĬ0.71 and reattachment is at X/LĬ1.21, which agree well with experiment results[11] of 0.7 and
1.15 respectively. Fig. 6b also shows a good agreement between experiment and calculation.

Fig. 6 Numerical results of hollow cylinder/flare. (a) Mach number contous; (b) wall pressure distribution

4. Conclusions

(1) All algorithms in this paper treat different cell types in the same way, and do not require any
information of local cell topology, so they are grid-transparent and are appropriate to 3D arbitrary
polyhedral grids.
(2) A constrained least-squares reconstruction method is developed. The three tests, especially the
subsonic flow over a flat plate, prove that it is accurate and robust.
(3) With the help of LU-SGS method in start-up and preconditioning process, the GMRES scheme can
perform much more robust and efficient. OpenMP is a simple and efficient parallel method, for it can
accelerate about 8 times with 12 threads.
(4) Besides subsonic and transonic flows which previous research on unstructured-grid methods
usually concentrate on, the present solver is able to simulate hypersonic flows accurately other. Shocks
can be obtained sharply inside one or two grids.
Zhongliang Kang and Chao Yan / Procedia Engineering 31 (2012) 9 – 15 15

References

[1] D J Mavriplis. Unstructured-mesh discretizations and solvers for computational aerodynamics. AIAA Journal, 2008, 46(6):
1280-1296
[2] T M Smith. Comparison of reconstruction techniques for unstructured mesh vertex centered finite volume schemes. AIAA-
2007-3958
[3] A Haselbacher. A WENO reconstruction algorithm for unstructured grids based on explicit stencil construction. AIAA-2005-
879
[4] J Blazek. Computational fluid dynamics principles and application. Elsevier, 2001:5-25
[5] Roe PL. Approximate riemann solvers, parameter vectors, and difference schemes. Journal of Computational Physics, 1981,
43:357-372
[6] Barth TJ, Jespersen DC. The design and application of upwind schemes on unstructured meshes. AIAA-1989-0366
[7] Mavriplis D. Revisiting the least-squares procedure for gradient reconstruction on unstructured meshes. AIAA-2003-3986
[8] E J Nielsen, W K Anderson, R W Walters, D E Keyes. Application of Newton-Krylov methodology to a three-dimensional
unstructured Euler codes. AIAA-1995-1733
[9] Hong Luo, Dmitri Sharov, Joseph D Baum. Parallel unstructured grid GMRES+LU-SGS method for turbulent flows. AIAA-
2003-273
[10] Dmitri Sharov, Kazuhiro Nakahashi. Reordering of 3-D hybrid unstructured grids for vectorized LU-SGS Navier-Stokes
computations. AIAA-1997-2102
[11] R Benay, B Chanetz, B Mangin, L Vandomme. Shockwave/transitional boundary-layer interactions in hypersonic flow.
AIAA Journal, 2006, 44(6):1243-1254

You might also like