Sie sind auf Seite 1von 6

2D Unstructured Euler Solver

Department of Aeronautics and Astronautics


Stanford University
AA-215B: Advanced CFD
Professor A. Jameson
Britton J. Olson
May 24, 2010
Abstract
In Aeronautical Engineering, the ability to solve the governing equations
of motion in a complex domain is vital. In a general sense, unstructured
solvers can provide robust treatment of nearly any boundary which might
represent some engineering interest. For design purposes, the wave drag or
drag produces by shock waves is of interest in designing airfoil shapes which
are optimal. Neglecting viscous eect, the full Navier-Stokes equations re-
duce to the Euler equations which capture all the compressibility eects of
transonic ow. (eg Shock waves, Prandlt-Meyer expansion fans, entropy
waves, etc.) In this brief note, we report our method and implementation
of a simple low-order unstructured solver of the Euler equations. We test
our code on 2 simple test cases whose results are given in a latter section.
The solutions converge to steady state in a reasonable amount of time and
given insight on the physics of the compressible equations of motion. Such
a solver, might be used to produce or validate aerodynamic design.
1 Algorithm
A node based edge ux method was used to solve the 2D Euler equations. In this
scheme, the conserved variables (, u, v, and E) are stored at each node while
uxes are computed across edges. The data is stored so that each edge contains
a list of 4 nodes listed in a consistent manner (counter-clockwise in this case). At
each iteration, a loop over all edges was performed to nd the total ux residual
at each node. Using the example in gure 1, the ux across edge 24 is computed
by averaging the ow variables at nodes 2 and 4. The ux contribution is then
applied to nodes 1 and 3 across from the edge.
Figure 1: Node based edge ux method.
1
At free stream boundaries, node values are set to the prescribed free stream
values. At the wall boundary, the ux computation is done similarly as with inte-
rior edges, except ow tangency is enforced. Additionally, to maintain consitency
in the control volume, the ux on a wall boundary edge is applied to the wall
nodes as well. For interior nodes, the boundaries of the control volume surround
the node (see gure 2) so the scheme described above will ensure proper conserva-
tion at each node. However, at wall edges, a node resides on the control volume
boundary (see gure 3). As a result, the computed wall ux must be applied to
the wall node as well to maintain conservation.
Figure 2: Control volume around an interior node.
Figure 3: Control volume around a boundary node.
In order to maintain stability in ows with shocks, a scalar articial diusion
was added. The scalar diusion was taken as the maximum eigenvalue of the Roe
matrix and is applied everywhere in the ow. Although this method works, it is
quite diuse and leads to smeared shocks. There are two major issues with this
2
method in terms of accuracy. First, the highest value of the Roe diusion is used
everywhere since the maximum eigenvalue of the Roe matrix is taken as the scalar.
This leads to unncesssary diusion in the majority of the domain. In addition, the
articial eld is applied everywhere, whereas a more sophisticated method would
detect and apply diusion only to necessary areas (namely at shocks).
2 Governing Equations
We provide here, for reference, the governing equations. 2-D Euler equations
(conservation of mass, momenta and energy) can be simply written as:
U
t
+ F
x
= 0 (1)
U =

u
v
E

, F
x
=

u
u
2
+ p
uv
u(E + p)

, F
y
=

v
uv
v
2
+ p
v(E + p)

, (2)
E =
p
( 1)
+
1
2
u
i
u
i
(3)
We solve then using a simple integration and in weak form as:

Udt +

(F
x
dy F
y
dx) = 0 (4)
We can discretely solve this by summing the edge contributions to each node
k as:

k
A

U
n
t
+
1
2

(F
k+1
x
+F
k
x
)(y
k+1
y
k
) (F
k+1
y
+F
k
y
)(x
k+1
x
k
)

= 0
(5)
Were k are the nodes which surround a particular point n, as in gure 2 and S
is the area. We the above approximations, we can now readily solve the discrete
approximation to the Euler equation. The source code (written in fortran 90) can
be provided by means a simple svn repository checkout by issuing: svn checkout
http://cybo.googlecode.com/svn/trunk/ euler2d.
3
3 Results
3.1 Circular Arc
Transonic ow (M

= 0.9) over a 5% thick (at 50% chord) circular arc bump was
computed. Results showing contours of Mach number and pressure are below. In
both plots, a supersonic region is visible over the bump (although the shock is
visibly diuse due to the use of rst order scalar articial diusion). The surface
pressure distribution shows that the shock is captured in approximately 5 points.
Since the method is low order (especially the shock capturing scheme), a fairly ne
triangulation was used.
(a) (b)
0.5 0 0.5 1 1.5
0.5
0
0.5
1
Xaxis

C
p
(c) (d)
Figure 4: 5% Cicular arc foil. M

= 0.9
4
3.2 NACA 0012
Transonic ow (M

= 0.75) over a NACA 0012 airfoil at = 10

was also
computed. Contours of Mach number and pressure show a supersonic region on
the upper surface of the airfoil. Again, due to the lower order of the method a
relatively ne mesh was used to allow for a reasonable shock.
(a) (b)
0.5 0 0.5 1 1.5
1
0.5
0
0.5
1
1.5
Xaxis

C
p
(c) (d)
Figure 5: NACA 0012. M

= 0.75, = 10

.
5

Das könnte Ihnen auch gefallen