An Implicit Upwind Finite-Volume Scheme for 3D Unstructured Meshes of Arbitrary...

6
An Implicit Upwind Finite-Volume Scheme for 3D Unstructured Meshes of Arbitrary Topology FRANK BRAMKAMP, JOSEF BALLMANN Lehr- und Forschungsgebiet f¨ ur Mechanik RWTH Aachen, University of Technology Templergraben 64, D-52062, Aachen GERMANY Abstract: - We present a finite volume method for the solution of the compressible Euler equations on 3D un- structured grids. The spatial discretization is based on a second order accurate method employing the HLLC upwind scheme. Time integration is implicit, using Newton’s method. A preconditioned Krylov method is used to solve the resulting linear system. Distributed memory computer architectures are exploited following the domain decomposition approach. Numerical results for the transonic flow over the ONERA M6 wing using a tetrahedral mesh and about a generic F15 aircraft configuration employing a hybrid Cartesian grid demonstrate the flexibility of the finite volume scheme to cope with different grid topologies. Key-Words: - Finite Volume, Unstructured Grid, Implicit time integration, Upwind Method 1 Governing Equations In the present study, fluid flow is described by the Eu- ler equations for a compressible gas. Neglecting body forces and volume supply of energy, the conservation laws for any control volume V with boundary ∂V and outward unit normal vector n on the surface element dS ∂V can be written in integral form as ∂t V u dV + ∂V F c (u)n dS = 0 . (1) Here u =(ρ, ρv, ρe tot ) T denotes the vector of the un- known conserved quantities and F c represent the con- vective flux including pressure: F c = ρv ρv v + p I ρe tot v + pv (2) where ρ denotes the density, p the static pressure, v the velocity vector of the fluid and e tot the total energy. The symbol means the dyadic product. The static pressure is related to the specific internal energy according to the equation of state for a perfect gas p = ρ (γ 1) e tot 1/2 |v| 2 , where γ is the ratio of specific heats, which is taken as 1.4 for air. 2 Numerical Method 2.1 Data Structure The spatial discretization of the governing equations is based on a cell centered finite volume scheme suited for unstructured meshes composed of simply connected elements with otherwise arbitrary topology. The data structure of the flow solver is primarily based on the faces of the grid. A face based data structure has the advantage that there are no limitations on the number of faces, that can be connected to a cell. The evaluation of fluxes and their distribution to cells can be efficiently implemented by sweeps over the faces. 2.2 Spatial Discretization In order to account for the directed transport of in- formation, the inviscid fluxes are discretized with up- wind schemes. In the present study we employ the HLLC Flux-Difference Splitting due to Batten et al. [4] with modified wave speeds according to Davis [9]. The higher-order extension of the scheme is crucial to obtain accurate solutions of the governing equations. To obtain second-order accuracy in space, we choose a linear reconstruction of the primitive flow variables w ∈{ρ, v,p}: w (x)| V i := w i + φ i (x x i ) T ·∇w i , x V i (3)

Transcript of An Implicit Upwind Finite-Volume Scheme for 3D Unstructured Meshes of Arbitrary...

Page 1: An Implicit Upwind Finite-Volume Scheme for 3D Unstructured Meshes of Arbitrary Topologywseas.us/e-library/conferences/corfu2004/papers/488-366.pdf · 2006. 9. 30. · An Implicit

An Implicit Upwind Finite-Volume Scheme for 3D UnstructuredMeshes of Arbitrary Topology

FRANK BRAMKAMP, JOSEF BALLMANNLehr- und Forschungsgebiet fur MechanikRWTH Aachen, University of Technology

Templergraben 64, D-52062, AachenGERMANY

Abstract: - We present a finite volume method for the solution of the compressible Euler equations on 3D un-structured grids. The spatial discretization is based on a second order accurate method employing the HLLCupwind scheme. Time integration is implicit, using Newton’s method. A preconditioned Krylov method is used tosolve the resulting linear system. Distributed memory computer architectures are exploited following the domaindecomposition approach. Numerical results for the transonic flow over the ONERA M6 wing using a tetrahedralmesh and about a generic F15 aircraft configuration employing a hybrid Cartesian grid demonstrate the flexibilityof the finite volume scheme to cope with different grid topologies.

Key-Words:- Finite Volume, Unstructured Grid, Implicit time integration, Upwind Method

1 Governing Equations

In the present study, fluid flow is described by the Eu-ler equations for a compressible gas. Neglecting bodyforces and volume supply of energy, the conservationlaws for any control volumeV with boundary∂V andoutward unit normal vectorn on the surface elementdS ⊂ ∂V can be written in integral form as

∂t

∫V

u dV +∮

∂VF c(u)n dS = 0 . (1)

Hereu = (ρ, ρv, ρetot)T denotes the vector of the un-known conserved quantities andF c represent the con-vective flux including pressure:

F c =

ρv

ρv ◦ v + p Iρetotv + pv

(2)

whereρ denotes the density,p the static pressure,vthe velocity vector of the fluid andetot the total energy.The symbol◦ means the dyadic product.

The static pressure is related to the specific internalenergy according to the equation of state for a perfect

gasp = ρ (γ − 1)(etot − 1/2 |v|2

), whereγ is the

ratio of specific heats, which is taken as 1.4 for air.

2 Numerical Method

2.1 Data Structure

The spatial discretization of the governing equationsis based on a cell centered finite volume schemesuited for unstructured meshes composed of simplyconnected elements with otherwise arbitrary topology.The data structure of the flow solver is primarily basedon the faces of the grid. A face based data structurehas the advantage that there are no limitations on thenumber of faces, that can be connected to a cell. Theevaluation of fluxes and their distribution to cells canbe efficiently implemented by sweeps over the faces.

2.2 Spatial Discretization

In order to account for the directed transport of in-formation, the inviscid fluxes are discretized with up-wind schemes. In the present study we employ theHLLC Flux-Difference Splitting due to Batten et al.[4] with modified wave speeds according to Davis [9].The higher-order extension of the scheme is crucial toobtain accurate solutions of the governing equations.To obtain second-order accuracy in space, we choosea linear reconstruction of the primitive flow variablesw ∈ {ρ, v, p}:

w (x)|Vi:= wi + φi (x − xi)

T · ∇wi , x ∈ Vi (3)

Page 2: An Implicit Upwind Finite-Volume Scheme for 3D Unstructured Meshes of Arbitrary Topologywseas.us/e-library/conferences/corfu2004/papers/488-366.pdf · 2006. 9. 30. · An Implicit

wherewi represents the solution at the centroidxi ofVi andφi denotes a limiter function. The gradient∇wi

is determined in a least squares sense, as suggested byBarth [3]. At local extrema and discontinuities, the re-construction may generate new extrema and thereforecause oscillations in the numerical solution. In order tocircumvent this problem, the slope limiter by Venkata-krishnan [13] is employed.

2.3 Time Integration

After having completed the spatial discretization, weobtain a system of ordinary differential equations

∂t

∫V

u dV + R (u) = 0 , (4)

whereR (u) denotes the residual vector defined by thesum of the discretized fluxes. The solution is advancedin time by an implicit Euler method to reach steadystate. Eq. (4) is solved by a Newton scheme. For sta-tionary flows it is sufficient to take one Newton itera-tion per time step, so that the Newton scheme reads asfollows:

J (un){un+1 − un

}= −R (un) (5)

with

J (un) =V

∆tI +

∂R (un)∂un

(6)

The linearization of the convective fluxes is based on afirst order accurate method in space. The derivation ofthe Jacobian is accomplished using tools of AutomaticDifferentiation, namely by the ADIFOR software [5].The linear system of equations (5) is solved by Krylovsubspace methods, preconditioned by ILU(p). The im-plementation of the method is based on the PETSc soft-ware library [1, 2].

For further details concerning the finite volumescheme, we refer to [7, 8, 6]

2.4 Parallelization

The parallelization of the method exploits distributedmemory computer architectures. The domain decom-position is performed using the ParMetis software [11],accessed via PETSc interfaces. To couple the domains,one layer of ghost cells is needed. In order to evalu-ate the convective fluxes, comprising the higher orderscheme in space, three communications are required,namely the exchange of the solution vector, its gradi-ents and the limiters within the ghost cells. The linear

system (5) is assembled in parallel, so that a matrix forthe complete system is determined, which is stored ondistributed memory. In that case, the Krylov method ispreconditioned by an additive Schwarz method, withan ILU(p) factorization on each subdomain.

3 Numerical Results

3.1 ONERA-M6 Wing

The first test case is concerned with the inviscid flowover the ONERA-M6 wing at Mach numberM∞ =0.84 and angle of attackα = 3.06◦ [12]. The compu-tational domain is tessellated by tetrahedral elements.The grid was kindly provided by Dr. R. Heinrich fromDLR Braunschweig. For tetrahedral meshes, the sten-cil selection for the higher-order reconstruction schemerequires particular care. The stencil has to be chosensufficiently large to obtain a well-conditioned problemfor computing the first order derivatives at cell cen-troids. To avoid an inaccurate or even singular behav-ior of the reconstruction at boundaries, the correspond-ing stencil of a tetrahedra should include direct faceneighbors as well as vertex neighbors.

The grid contains 582752 tetrahedra, with 36460cells located on the surface of the wing. Fig. 1 shows aperspective view of the computational grid and the cor-responding pressure distribution. The flow field on theupper surface is characterized by two shocks, whichproceed from the root of the wing towards the tip. Bothshocks merge into one single shock, which splits againin two distinct shocks near the tip edge. This flow pat-tern is known asλ-shock configuration. On the aver-age, the shocks are resolved by 2-3 grid cells. Nearthe tip of the wing, the grid is insufficiently resolvedto capture the splitting of the shock. Fig. 2 presents acomparison of the computed surface pressure distribu-tion for various cross-sections of the wing with experi-mental measurements [12]. Overall, a good agreementbetween the numerical results and the experimentaldata can be observed. The pressure distribution on thelower surface and the suction peaks on the upper sur-face of the wing are captured very well. On the uppersurface, the positions of the shocks are predicted toofar downstream in tendency, and the post-shock oscil-lations are over-estimated. Both effects are attributedto the neglect of viscous effects in the computation.

Page 3: An Implicit Upwind Finite-Volume Scheme for 3D Unstructured Meshes of Arbitrary Topologywseas.us/e-library/conferences/corfu2004/papers/488-366.pdf · 2006. 9. 30. · An Implicit

Figure 1: Inviscid flow over ONERA-M6 wing, (M∞ = 0.84, α = 3.06◦). Left Figure: Computationalgrid, 582752 tetrahedra, 36460 triangular surface elements.Right Figure: Pressure distribution,cp,min =−1.3, cp,max = 1.0, ∆cp = 0.1

x/c

-Cp

0 0.25 0.5 0.75 1-1

-0.5

0

0.5

1

(a) 20% span width

x/c

-Cp

0 0.25 0.5 0.75 1-1

-0.5

0

0.5

1

(b) 44% span width

x/c

-Cp

0 0.25 0.5 0.75 1-1

-0.5

0

0.5

1

(c) 65% span width

x/c

-Cp

0 0.25 0.5 0.75 1-1

-0.5

0

0.5

1

(d) 80% span width

x/c

-Cp

0 0.25 0.5 0.75 1-1

-0.5

0

0.5

1

(e) 90% span width

x/c

-Cp

0 0.25 0.5 0.75 1-1

-0.5

0

0.5

1

(f) 96% span width

Figure 2: Pressure distributions for ONERA-M6 wing (M∞ = 0.84, α = 3.06◦), – Inviscid Computation,�Experiment [12]

Page 4: An Implicit Upwind Finite-Volume Scheme for 3D Unstructured Meshes of Arbitrary Topologywseas.us/e-library/conferences/corfu2004/papers/488-366.pdf · 2006. 9. 30. · An Implicit

3.2 Generic F15 Aircraft Fighter

The second example investigates the three-dimensional, inviscid flow past a generic F15 aircraftfighter configuration atM∞ = 0.95 and angle of at-tackα = 3◦. Since the flow is symmetric, only a halfmodel is computed.

The computational mesh has been kindly providedby Dr. F. Deister (EADS) using the CARTFLOW gridgeneration software [10]. It is a fully automatic hybrid-Cartesian grid generator for inviscid and viscous flowsabout complex configurations. The surface of the flightconfiguration is tessellated with 81130 triangles. Theresulting body surface is intersected with the Cartesiangrid forming polyhedral elements on the triangulatedsurface. Fig. 3 illustrates the hybrid-Cartesian grid. Itcomprises 1329261 grid points and 814704 cells (halfmodel). The complete grid generation procedure took307 seconds on a Workstation with R10000 processor[10].

The intake and exhaust of the jet engines are mod-eled via the following boundary conditions: At intake,the density and pressure are extrapolated from the in-terior domain. An inflow Mach number ofMin = 0.5is prescribed, assuming a uniform distribution of thevelocity field across the plane of inflow, aligned withthe direction of flight. The exhaust is modeled as an

over-expanding jet of hot gas. The ratios between theexhaust conditions,Tex, pex, and ambient conditions,T∞, p∞, areTex/T∞ = 5 andpex/p∞ = 1.5, respec-tively. The outlet Mach number isMex = 1.15. Theseparameters are chosen according to [10].

To obtain a robust solution procedure, the initialdensity residual has been decreased about two ordersof magnitude using a first order accurate method inspace, withCFLmax = 50. The solution is advancedfurther based on a second order accurate method, withCFLmax = 150. The linear system of equations issolved with BiCGSTAB, with ILU(0) serving as pre-conditioner.

Fig. 4 shows the pressure distribution on the air-craft surface. Near the leading edge of the wing, theflow is accelerated toM ≈ 1.7. The supersonic regionis closed by a shock. Between the vertical tails, theflow reaches supersonic conditions as well. The shockplane between the vertical tails crosses the engine ex-hausts near the outlet.

Fig. 5 shows the domain decomposition of the sur-face for 16 processors. Computations have been con-ducted on a cluster of Linux PCs, each with PentiumIII, 1266MHz processor. Fig. 6 shows a good scal-ing between 4 and 16 processors. For 16 processorsa superlinear speedup is obtained, which indicates animproved cache usage due to the smaller domain sizes.

Figure 3: Inviscid flow about generic F15 aircraft fighter,M∞ = 0.95, α = 3◦: Computational grid

Page 5: An Implicit Upwind Finite-Volume Scheme for 3D Unstructured Meshes of Arbitrary Topologywseas.us/e-library/conferences/corfu2004/papers/488-366.pdf · 2006. 9. 30. · An Implicit

Figure 4: Inviscid flow about generic F15 aircraft fighter,M∞ = 0.95, α = 3◦: Pressure distribution,cp,min = −1.2, cp,max = 1.2, ∆cp = 0.075

Figure 5: Domain decomposition for 16 processors

Number Processors

Sp

eed

up

4 8 12 16 200

1

2

3

4

5

ideal

Figure 6: Speedup on Linux PC cluster

Page 6: An Implicit Upwind Finite-Volume Scheme for 3D Unstructured Meshes of Arbitrary Topologywseas.us/e-library/conferences/corfu2004/papers/488-366.pdf · 2006. 9. 30. · An Implicit

4 Conclusion

We have presented numerical simulations of inviscidflows on unstructured grids for complex, three dimen-sional configurations. The use of tetrahedral meshesand hybrid Cartesian grids highlight the flexibility ofthe method to cope with different unstructured gridtopologies. The flow past the ONERA M6 wing anda genenic F15 aircraft show accurate flow prediction.The parallelization of the implicit solver is suited fordistributed memory architectures, using message pass-ing. First results indicate a good scaling of the methodfor a moderate number of processors. The use of highernumber of processors still has to be tested.

References

[1] S. Balay, K. Buschelman, W. Gropp, D. Kaushik,M. Knepley, L. McInnes, B. Smith, andH. Zhang. PETSc home page. http://www-unix.mcs.anl.gov/petsc/petsc-2/, 2001.

[2] S. Balay, K. Buschelman, W. Gropp, D. Kaushik,M. Knepley, L. McInnes, B. Smith, andH. Zhang. PETSc users manual. Technical Re-port ANL-95/11 - Revision 2.1.5, Argonne Na-tional Laboratory, 2002.

[3] T. Barth. Aspects of Unstructured Grids andFinite-Volume Solvers for the Euler and Navier-Stokes Equations, pages 6.1 – 6.61. SpecialCourse on Unstructured Grid Methods for Ad-vection Dominated Flows, AGARD Report 787,1992.

[4] P. Batten, M. Leschziner, and U. Goldberg.Average-State Jacobians and Implicit Methodsfor Compressible Viscous and Turbulent Flows.Journal of Computational Physics, 137:38–78,1997.

[5] C. Bischof, A. Carle, P. Khademi, and A. Mauer.ADIFOR 2.0: Automatic Differentiation of For-tran 77 Programs.IEEE Computational Science& Engineering, 3(3):18–32, 1996.

[6] F. Bramkamp. Unstructuredh-Adaptive Finite-Volume Schemes for Compressible Viscous FluidFlow. PhD thesis, Aachen University of Technol-ogy, 2004.

[7] F. Bramkamp, B. Gottschlich-Muller, M. Hesse,P. Lamby, S. Muller, J. Ballmann, K. Brakhage,and W. Dahmen. H-Adaptive MultiscaleSchemes for the Compressible Navier–StokesEquations — Polyhedral Discretization, DataCompression and Mesh Generation.Notes on Nu-merical Fluid Mechanics, 84:125–204, 2003.

[8] F. Bramkamp, P. Lamby, and S. Muller. An adap-tive multiscale finite volume solver for unsteadyand steady state flow computations.Journal ofComputational Physics, in Press.

[9] S. Davis. Simplified Second-Order Godunov-Type Methods. SIAM J. Sci. Stat. Comput.,9:445–473, 1988.

[10] F. Deister. Selbstorganisierendes hybrid-kartesisches Netzverfahren zur Berechnungvon Stromungen um komplexe Konfigura-tionen. Fortschritt-Berichte VDI, Reihe 7:Stromungstechnik, Nr. 430, ISBN 3-18-343007-X, 2002.

[11] G. Karypi, K. Schloegel, and V. Kumar.ParMeTiS: Parallel graph partitioning and sparsematrix ordering library. Technical report, Univer-sity of Minnesota, Department of Computer Sci-ence and Engineering, 1997.

[12] V. Schmitt and F. Charpin.Pressure Distribu-tions on the ONERA-M6 Wing at Transonic MachNumbers, pages B1.1 – B1.44. AGARD-AR-138,Experimental Data Base for Computer ProgramAssessment, 1979.

[13] V. Venkatakrishnan. Convergence to Steady StateSolutions of the Euler Equations on UnstructuredGrids with Limiters. Journal of ComputationalPhysics, 118:120–130, 1995.