me554 lab 8 airfoil - calpoly.edukshollen/me554/labs/me554_lab_8_airfoil.pdf · airfoil to insure...

30
DRAFT 1 Lab 8: FLUENT: Turbulent Boundary Layer Flow with Convection Objective: The objective of this laboratory is to use FLUENT to solve for the total drag and heat transfer rate for external, turbulent boundary layer flow. In particular, we will investigate the flow of air over a symmetric airfoil (NACA 0012) with constant surface temperature. This flow has been investigated by many researchers and is used to validate turbulence models in CFD codes [1-8]. Concepts introduced in this lab will include domain requirements for external flow, external flow boundary conditions, and the use of wall functions for modeling turbulent flows and the corresponding grid requirements. Background: For this lab we will consider air flowing at a uniform velocity and temperature over a symmetric airfoil (NACA 0012) with constant surface temperature as shown in Figure 1. Initially, we will consider an angle of attack α = 0˚ (angle between free stream velocity and chord line), thus the airfoil chord length c = 1.00 m is aligned with the flow. We will assume a very long wingspan and model the flow as two-dimensional. The air upstream of the airfoil has uniform velocity U = 42.0 m/s, temperature T = 266.5K , and pressure p = 1.00 atm. The surface temperature of the airfoil is T s = 305 K . The Reynolds number for the airfoil based on chord length is Re c = ρ Uc μ = 2.88 × 10 6 . (1) where ρ and μ are the density and viscosity of air at the film temperature defined as T f = T + T s ( ) 2 . For this Reynolds number the flow will be turbulent by the end of the airfoil. Recall that the transition from laminar to turbulent flow typically occurs at a Reynolds number of approximately 5 x 10 5 . We will assume that the leading edge of the airfoil is rough such that the boundary layer is turbulent over the entire airfoil. Figure 1. Schematic of flow over a NACA 0012 airfoil at constant temperature. air at U = 42.0 m/s T = 266.5K p = 1.00 atm airfoil at T s = 305 K y x c

Upload: truonghanh

Post on 30-Jan-2018

263 views

Category:

Documents


2 download

TRANSCRIPT

Page 1: ME554 Lab 8 airfoil - calpoly.edukshollen/ME554/Labs/ME554_Lab_8_airfoil.pdf · airfoil to insure turbulent flow over most of the airfoil. The area used for the definition of the

DRAFT

1

Lab 8: FLUENT: Turbulent Boundary Layer Flow with Convection Objective: The objective of this laboratory is to use FLUENT to solve for the total drag and heat transfer rate for external, turbulent boundary layer flow. In particular, we will investigate the flow of air over a symmetric airfoil (NACA 0012) with constant surface temperature. This flow has been investigated by many researchers and is used to validate turbulence models in CFD codes [1-8]. Concepts introduced in this lab will include domain requirements for external flow, external flow boundary conditions, and the use of wall functions for modeling turbulent flows and the corresponding grid requirements. Background: For this lab we will consider air flowing at a uniform velocity and temperature over a symmetric airfoil (NACA 0012) with constant surface temperature as shown in Figure 1. Initially, we will consider an angle of attack α = 0˚ (angle between free stream velocity and chord line), thus the airfoil chord length c = 1.00 m is aligned with the flow. We will assume a very long wingspan and model the flow as two-dimensional. The air upstream of the airfoil has uniform velocity U = 42.0 m/s, temperature

T∞ = 266.5 K, and pressure p = 1.00 atm. The surface temperature of the airfoil is

Ts = 305 K . The Reynolds number for the airfoil based on chord length is

Rec =ρU c

µ= 2.88 ×106. (1)

where ρ and µ are the density and viscosity of air at the film temperature defined as

Tf = T∞ + Ts( ) 2. For this Reynolds number the flow will be turbulent by the end of the airfoil. Recall that the transition from laminar to turbulent flow typically occurs at a Reynolds number of approximately 5 x 105. We will assume that the leading edge of the airfoil is rough such that the boundary layer is turbulent over the entire airfoil.

Figure 1. Schematic of flow over a NACA 0012 airfoil at constant temperature.

air at U = 42.0 m/s

T∞ = 266.5 K p = 1.00 atm

airfoil at Ts = 305 K

y

x

c

Page 2: ME554 Lab 8 airfoil - calpoly.edukshollen/ME554/Labs/ME554_Lab_8_airfoil.pdf · airfoil to insure turbulent flow over most of the airfoil. The area used for the definition of the

DRAFT

2

Fluid Mechanics The turbulent hydrodynamic boundary layer that initially forms at the stagnation point (at x = 0) grows thicker downstream along the surface of the airfoil. Recall that a boundary layer is a thin region at the surface where the flow velocity goes from zero (due to the no-slip condition at the surface) to the free stream velocity. The turbulent boundary layer velocity distribution can be approximated by a power-law profile developed from a curve fit to experimental data

u(y) =U yδ

⎝ ⎜ ⎞

⎠ ⎟ 1/ 7

(2)

where y is the vertical coordinate measured upwards from the plate surface and δ is the boundary layer thickness. A correlation for δ for turbulent flow over a smooth plate is

δx

=0.382Rex

1/ 5 for

5 ×105 ≤ Rex ≤108 (3)

where x is the horizontal distance along the plate measured from the leading edge of the plate and the Reynolds number is defined using x as the length scale. For the same Reynolds number range, a correlation for the skin friction coefficient (dimensionless wall shear stress) on the flat plate has been developed

Cf x( ) =τw x( )12 ρU 2 = 0.0594 Rex

−1/5 for

5 ×105 ≤ Rex ≤108 (4)

where τw is the wall shear stress. Note that Cf and τw are theoretically infinite at the leading edge where the boundary layer is very thin and then decrease along the plate. Equation (4) can be averaged over the entire plate to calculate the friction drag coefficient using

CD, f =1L

Cf dxx =0

L∫ = 0.0743 ReL

−1/5 . (5)

This can be used to calculate the portion of total drag, FD, force on an object in external flow parallel to the flow, due to fluid friction (or viscosity) called the friction drag using

FD, f = 12 ρU 2 A CD, f (6)

where A is the total surface area of the plate in contact with the fluid. For an airfoil, the total drag will be greater than just the friction drag above due to pressure drag, FD,p, an additional force due to higher average pressure on the front than back of the airfoil. For inviscid flow (flow without friction) there is no pressure drag due to perfect recovery of the pressure on the back. However, for a real flow there will be pressure drag and the magnitude will increase as the size of the wake grows with increasing angle of attack.

Page 3: ME554 Lab 8 airfoil - calpoly.edukshollen/ME554/Labs/ME554_Lab_8_airfoil.pdf · airfoil to insure turbulent flow over most of the airfoil. The area used for the definition of the

DRAFT

3

Figure 2. Drag coefficient versus Reynolds number and angle of attack for a NACA 0012 airfoil with a tripped boundary layer. Experimental data is from Ladson [2]. Turbulent flat plate correlation is given by Equation 5.

Figure 2 shows the effect of both Reynolds number and angle of attack on the drag coefficient for an aerodynamically smooth NACA 0012 airfoil. The boundary layer was intentionally tripped to turbulent at

x = 0.05 c by a strip of fine grit

0.01c wide on the top and bottom of the airfoil to insure turbulent flow over most of the airfoil. The area used for the definition of the airfoil drag coefficient is the planform area, Ap, defined as chord length, c, times wingspan, b. Also shown in Figure 2 is a curve fit to the experimental data given by

CD =FD

12 ρ U 2 Ap

= C Rem (7)

C = C0 + C2 α2 + C3 α

3 where

m = −0.2,

C0 = 0.1832 ,

C2 = 3.65 ×10−5 , and

C2 = 7.09 ×10−5 . Lift, FL, is the force on an object in external flow normal to the flow. Similar to drag, lift can be generated by both friction and an uneven pressure distribution, however only lift due to pressure is generally significant (except at very low Reynolds numbers for example for bees). The pressure distribution is given in dimensionless from by the pressure coefficient

Cp =p

12 ρU 2 (8)

0.000!

0.005!

0.010!

0.015!

0.020!

0.025!

0.030!

1.0E+06! 1.0E+07!

Dra

g C

oeffi

cien

t!

Reynolds Number!

15 ˚!

10 ˚!

5 ˚!

0 ˚!

angle of!attack!

turbulent flat plate!

Page 4: ME554 Lab 8 airfoil - calpoly.edukshollen/ME554/Labs/ME554_Lab_8_airfoil.pdf · airfoil to insure turbulent flow over most of the airfoil. The area used for the definition of the

DRAFT

4

Figure 3. Pressure coefficient, Cp, versus dimensionless horizontal location, x/c, and angle of attack, α, for a NACA 0012 airfoil. Experimental data is from Gregory and O'Reilly [2].

The pressure coefficient is plotted for the upper surface (open symbols and solid line) and lower surface (closed symbols and dashed line) of a NACA 0012 airfoil in Figure 3. Note that the lower pressure on the top of the airfoil versus the bottom generates the desired upwards lift for a positive angle of attack. The pressure coefficient can then be integrated to obtain the lift coefficient and the lift

CL =1Ap

Cp dAA∫ (9)

FL = 12 ρU 2 Ap CL (10)

where the planform area is again used. Figure 4 shows the lift coefficient for a NACA 0012 airfoil versus Reynolds number and angle of attack. Note that the lift coefficient for this range of conditions is not dependant on the type of boundary layer transition, either free or forced.

-6!

-4!

-2!

0!

2!0.00! 0.05! 0.10! 0.15! 0.20!

Pres

sure

Coe

ffici

ent!

x / c!

10 ˚! 6 ˚! 0 ˚!

angle of attack!

Page 5: ME554 Lab 8 airfoil - calpoly.edukshollen/ME554/Labs/ME554_Lab_8_airfoil.pdf · airfoil to insure turbulent flow over most of the airfoil. The area used for the definition of the

DRAFT

5

Figure 4. Lift coefficient versus Reynolds number and angle of attack for an aerodynamically smooth NACA 0012 airfoil. Experimental data with (a) open symbols from Ladson [2] with a tripped and free transition boundary layer

and (b) closed symbols from Sheldahl and Klimas [3] with a free boundary layer transition. Also shown in Figure 2 is a correlation developed by McCroskey [4] for the lift coefficient

CL

α= 0.1025+ 0.00485 log10

Re106

⎝ ⎜

⎠ ⎟

⎣ ⎢

⎦ ⎥ 1− Ma2 (11)

where Ma is the Mach number which will have negligible effect at the low Mach number for our conditions because the flow is approximately incompressible. Heat Transfer In addition to the turbulent hydrodynamic boundary layer, a thermal boundary layer also forms at the forward stagnation point of the airfoil and grows thicker along the surface. Due to the significant turbulent mixing in the boundary layer region the growth rate of the hydrodynamic and thermal boundary layers will be the same. Thus, Equation (3) can also be used to approximate the thickness of the thermal boundary layer. For a flat plate, the local Nusselt number for the turbulent boundary layer is given by the following correlation developed by Reynolds et al. [9]

Nux =hx xk f

= 0.0296 Rex4 / 5 Pr0.6 Ts

T∞

⎝ ⎜

⎠ ⎟

−0.4

(12)

0.0!

0.5!

1.0!

1.5!

2.0!

1.0E+05! 1.0E+06! 1.0E+07!

Lift

Coe

ffici

ent!

Reynolds Number!

15 ˚! 10 ˚! 5 ˚!

angle of!attack!

Page 6: ME554 Lab 8 airfoil - calpoly.edukshollen/ME554/Labs/ME554_Lab_8_airfoil.pdf · airfoil to insure turbulent flow over most of the airfoil. The area used for the definition of the

DRAFT

6

where hx is the local convection coefficient, kf is the thermal conductivity of the fluid, and Pr is the Prandtl number. This correlation is valid for

5 ×105 ≤ Rex ≤108 and

0.6 ≤ Pr ≤ 60. Equation (7) can be integrated over the length of the plate to obtain the average Nusselt number

NuL =h Lk f

= 0.037 Rex4 / 5 Pr0.6 T s

T∞

⎝ ⎜

⎠ ⎟

−0.4

(13)

which can be used to calculate the average heat transfer coefficient,

h , and the total heat transfer from the plate using

q = h A Ts −T∞( ) . (14) For an airfoil, the heat transfer will be greater than the heat transfer from a flat plate due to the more complicated nature of the flow around the airfoil. Experimental data are available in the literature [2-3] and will be summarized here in the future. Note that all of the above correlations were developed for turbulent flows over a wide range of conditions such as free stream turbulence and actual plate roughness. Thus, they are only an approximation and are typically considered to be accurate to only about ±15% for any particular flow condition.

Page 7: ME554 Lab 8 airfoil - calpoly.edukshollen/ME554/Labs/ME554_Lab_8_airfoil.pdf · airfoil to insure turbulent flow over most of the airfoil. The area used for the definition of the

DRAFT

7

Laboratory: ICEM CFD To create the mesh for our flow field, we will consider what is necessary to model the “real flow” correctly. In particular, because this is an external flow, the domain will consist of the region surrounding the airfoil. We must decide how large to make the overall extent of the domain (similar to wind tunnel testing) and how to handle the boundary conditions far away from the airfoil. From Equation (3) we can estimate the thickness of the boundary layer at the end of the airfoil to be approximately 1.5 cm. However, as the boundary layer grows along the airfoil fluid has to move away from the surface to satisfy conservation of mass. To allow the boundary layer to grow unconstrained like it would for a real external flow we must make sure there is sufficient area around the airfoil well beyond the width of the boundary layer to allow for this growth. The best way to test if the extent of the domain is sufficient is to run your simulations on a series of meshes of increasing extent from the solid surfaces until the solution no longer depends on this parameter. For flat plate simulations a domain height equal to the length of the plate will generally be sufficient. For external simulations of blunt bodies, such as this airfoil, a general recommendation is that the domain be at least 3 body lengths in front of the body and 5 body lengths behind. Also, the body should not be more than about 1.5% of the total cross-sectional area of the domain. The boundary condition for the region directly upstream of the airfoil will be set to the free stream velocity, U. The boundary condition for the region directly downstream of the airfoil will be set to be a pressure outlet. For the boundary condition at the top and bottom of the domain, for an angle of attack of 0˚, the velocity will be approximately the same as the free stream velocity. For this case there are three boundary condition choices that will work: (1) fixed velocity of U, (2) pressure outlet, or (3) symmetry (or zero shear stress). Again, if the extent of the domain is sufficient it should not matter which one is used. Finally, similar to the pipe flow considered in Lab 6, it is desirable to concentrate the mesh in the boundary layer region where the gradients in velocity and temperature are the highest. In fact, due to the strong interaction of the mean flow and turbulence, the numerical results for turbulent flows are typically more susceptible to grid dependency than those for laminar flows. Thus, we need to carefully control the number of cells in the boundary layer and their location relative to the wall. We do this in terms of a dimensionless variable called the wall unit defined as

y + =ρ uτ y

µ (10)

where

uτ is the friction velocity defined as

uτ =τwρ

(11)

Page 8: ME554 Lab 8 airfoil - calpoly.edukshollen/ME554/Labs/ME554_Lab_8_airfoil.pdf · airfoil to insure turbulent flow over most of the airfoil. The area used for the definition of the

DRAFT

8

In particular, we need to make sure that the y+ value for the centroid of the cell closest to the airfoil is in the right range for the turbulence model we choose. We will discuss this further when we select turbulence models in the FLUENT section. We can estimate the size of the element along the plate that corresponds to a particular y+ value using Equation (4) for the skin friction coefficient to estimate the friction velocity. The results are shown in Figure 6.

Figure 6. Estimate of y-coordinate versus axial location and y+ value.

The range from

0 < y + < 5 is called the viscous sublayer because the effects of molecular viscosity dominate in this region. The velocity in this region is simply

u+ =uuτ

= y + (12)

The range from

5 < y + < 30 is called the buffer layer. There is no simple model to describe the velocity in this range. Next is the log-law layer (or logarithmic overlap layer) where shear stresses due to both molecular viscosity and turbulent mixing are both important. This layer extends from

y + > 30 up to approximately

y + ≈ 300 where the actual

y + magnitude is dependent on the details of the flow. The velocity distribution in this region is given by

u+ =uuτ

= 2.5 ln y +( ) + 5.0 (13)

Finally, at higher

y + values is the outer turbulent layer where turbulent shear dominates.

0.001

0.01

0.1

1

10

100

0.0 0.2 0.4 0.6 0.8 1.0

x

y

y+ = 300

y+ = 30

y+ = 5

x (m)

y (m

m)

Page 9: ME554 Lab 8 airfoil - calpoly.edukshollen/ME554/Labs/ME554_Lab_8_airfoil.pdf · airfoil to insure turbulent flow over most of the airfoil. The area used for the definition of the

DRAFT

9

To begin we will create a mesh where

30 < y + < 300 for the centroid of the wall adjacent cell which is in the log-law layer. Using Figure 6 as a guide, we will select a mesh size of 0.2 mm for the cell adjacent to the wall for our initial mesh. After we have completed our simulations we will calculate our observed y+ values along the flat plate to determine if they are in the estimated range. Also, we will insure that we have at least a few cells in the boundary layer region and that we do not use excessive stretching in the direction normal to the wall. We are now ready to create a mesh for the external flow over the airfoil by following the sequence of commands listed below. Your mesh will be a two-dimensional slice of the domain as shown in the Figure 7.

Figure 7. Schematic of computational domain. Note that the far field is shown much smaller than what is required for a simulation to make it easier to see both the airfoil and the far field boundaries.

To run ICEM CFD, click on the ICEM CFD icon on the desktop. In the Main Menu, from the Settings pull down menu select Product. In the DEZ verify under Product Setup that ANSYS Solvers - CFD Version is selected. If it is not, do so, click OK, exit the program, and then restart ICEM CFD. Step 1. Select Working Directory and Create New Project Main Menu - From File pull down menu, select Change Working Directory using LMB. In New Project directory dialog box create a new folder. Do not use a name with spaces, including all the directories in the path. Main Menu - From File pull down menu, select New Project using LMB.

pnt.00

pnt.01

pnt.02

pnt.03

pnt.07

pnt.05

pnt.06pnt.04

pnt.08

pnt.09

pnt.10

pnt.11

pnt.12

pnt.13

pnt.14

crv.00 crv.01

crv.02

crv.03

crv_af0

crv_af1

H

H

H

c

a

x

y

Page 10: ME554 Lab 8 airfoil - calpoly.edukshollen/ME554/Labs/ME554_Lab_8_airfoil.pdf · airfoil to insure turbulent flow over most of the airfoil. The area used for the definition of the

DRAFT

10

In New Project dialog box create a new project. Again, do not use a name with spaces. Step 2. Start Recording Replay Script Because we will create several meshes, we will use a replay script (written in the scripting language Tcl/Tk) to generate meshes for a range of domain extents automatically. Main Menu - From File pull down menu, select Reply Scripts -> Replay Control using LMB. Organize the ICEM CFD window and Replay Control window so you can see both simultaneously and ensure that Record (after current) is selected in the Replay Control window. While creating the geometry and mesh in the steps below note that script lines (or instructions) will be automatically recorded in the Replay Control window under Operations in script. Step 3. Import Airfoil Geometry We will use a text file named naca0012_200.txt available from my webpage that contains x, y, and z coordinates at 200 locations for a NACA 0012 airfoil with a chord length of 1.0 m to generate both the points and curves for the airfoil surface. Download this file and place it in your working directory for this project. The MATLAB code used to generate the coordinates and text file is also available from my web page. Note that a large number of points and high precision for the locations is required due to the fine mesh needed at the surface to resolve the boundary layer flow. Main Menu - From File pull down menu, select Import Geometry -> Formatted point data using LMB. In Select File dialog box select the file you downloaded above. DEZ - For Import Formatted INPUT point data enter the following: in Point Part text edit box click LMB and enter PNT_AF (replacing PNTS), in Curve Part text edit box click LMB and enter WALL_AF (replacing CRVS), in Point Prefix text edit box click LMB and enter PNT_AF (replacing pnt), in Curve Prefix text edit box click LMB and enter CRV_AF (replacing crv), deselect Import Surfaces using LMB, in Approximation Tolerance text edit box click LMB and enter 1e-8, and click OK using LMB.

Utilities - Select Fit Window using LMB to verify that the airfoil has been created. DCT - Expand Geometry and Parts menus by using LMB to change + to - for each. Under Model\Geometry use the LMB to check the box before Points and then use RMB to click on Points and select Show Point Names using LMB. Verify that 402 points have been created. Under Model\Parts use the LMB to uncheck the box before PNT_AF to hide these points. Under Model\Geometry use RMB to click on Curves and select Show Curve Names using LMB. Verify that two curves have been created using a b-spline.

Page 11: ME554 Lab 8 airfoil - calpoly.edukshollen/ME554/Labs/ME554_Lab_8_airfoil.pdf · airfoil to insure turbulent flow over most of the airfoil. The area used for the definition of the

DRAFT

11

Step 4. Create Points for Far Field Function Tab - From Geometry select Create Point using LMB. DEZ - For Create Point enter the following: deselect Inherit Part (NOTE, this is only needed for Windows OS), in Part text edit box click LMB and enter PNT (replacing GEOM),

select Explicit Coordinates using LMB, under Explicit Locations ensure Create 1 point is selected from pull down menu, in X text edit box click LMB and enter -9.9 for point at (-9.9, 0, 0), click Apply using LMB and verify the Message Done: points pnt.00, repeat this process to create all the points in Table 1, and click Dismiss using LMB.

Table 1. Coordinates for far field points with part name PNT_FF. Name x (m) y (m) z (m) pnt.00 -9.9 0.0 0 pnt.01 0.1 10.0 0 pnt.02 0.1 -10.0 0 pnt.03 1.0 10.0 0 pnt.04 1.0 -10.0 0 pnt.05 10.1 10.0 0 pnt.06 10.1 -10.0 0 pnt.07 10.1 0.0 0

NOTE: The location of these points shown in Figure 7 are for c = 1.0 m, H = 10.0 m, and a = 0.1 m. Utilities - Select Fit Window using LMB to verify that eight points have been created surrounding the airfoil with the correct corresponding names. In the Replay Control Window click Clean and Renumber using LMB. Note that lines that mark the beginning and ending of an undo group are deleted. The first line in the replay script reads in the airfoil geometry. There are then five lines that set boundary conditions (ic_boco) and system parameters that are not necessary and can be deleted using Delete One. The line that creates the new geometry family PNT_FF (ic_geo_new_family) and the lines that create the actual points (ic_point) are required.

Page 12: ME554 Lab 8 airfoil - calpoly.edukshollen/ME554/Labs/ME554_Lab_8_airfoil.pdf · airfoil to insure turbulent flow over most of the airfoil. The area used for the definition of the

DRAFT

12

Step 5. Create Curves for Far Field

Function Tab - From Geometry select Create/Modify Curve using LMB. DEZ - For Create/Modify Curve enter the following: ensure Inherit Part is NOT selected, in Part text edit box click LMB and enter INLET (replacing PNT_FF),

select Arc using LMB, under Create Arc Method ensure From 3 Points is selected from pull down menu, select Select location(s) using LMB (if not in screen select mode), select pnt.01, pnt.00, and pnt.02 using LMB to create inlet, verify the Message Done: curves crv.00, in Part text edit box click LMB and enter UPPER,

select From Points using LMB, select Select location(s) using LMB (if not in screen select mode), select pnt.01, pnt.03, and pnt.05 using LMB and then click MMB to create top, verify the Message Done: curves crv.01, in Part text edit box click LMB and enter LOWER, select pnt.02, pnt.04, and pnt.06 using LMB and then click MMB to create bottom, verify the Message Done: curves crv.02, in Part text edit box click LMB and enter OUTLET, select pnt.05, pnt.07 and pnt.06 using LMB and then click MMB to create outlet, verify the Message Done: curves crv.03, in Part text edit box click LMB and enter INTERIOR, select pnt.01 and pnt.02 using LMB and then click MMB, verify the Message Done: curves crv.04, and click DISMISS using LMB. DCT - Under Model\Geometry use RMB to click on Points and unselect Show Point Names using LMB. Verify that five curves have been created. Step 6. Create Additional Points for Blocking (described below) Function Tab - From Geometry select Create Point using LMB. DEZ - For Create Point enter the following: in Part select PNT_FF from pull down menu,

select Parameter Along Curve using LMB, under Points Method ensure Parameters is selected from pull down menu,

From Points

The From Points option allows you to create a Bspline curve by interpolating through n number of points.

From PointsClick on the icon and select any location on the screen to create points that define a curve.

Arc from 3 Points

The Arc option allows you to create an arc from three points.

From 3 PointsCreates a Bspline arc through three points.

Center and 2 Points

• Radius

If enabled, the radius will be set as the specified value. If disabled, the radius will be set at the distancebetween the first two points selected.

• Keep Center or Start/End

The Keep Center option will take the first point selected as the center, the second point as the firstarc beginning, and calculate the arc end from the vector defined by the first point and third point.The radius used will be determined by the Radius parameter.

The Keep Start/End option will use the first and second points selected as the arc ends and calculatethe center using the Radius parameter if specified, or else the average distance between the firstand second points, and the first and third points. The plane will be defined by the three selectedpoints.

• Points

Select 3 points.

Circle from Center and 2 Points

The Circle from Center and 2 Points option allows you to create a circle of known radius and center pointin a plane.

• Radius

If toggled ON, the radius will be set as the specified value. If toggled OFF, the radius will be set at thedistance between the first two points selected.

• Start angle

For a full circle, the start angle is 0. Otherwise, specify the desired start angle.

• End angle

The end angle for a full circle is 360, and for a semi-circle is 180.

• Points

ANSYS ICEM CFD 13.0 - © SAS IP, Inc. All rights reserved. - Contains proprietary and confidential in-formation of ANSYS, Inc. and its subsidiaries and affiliates.178

Geometry

Curve Ends

The Curve Ends option allows you to select a curve to create points at the 2 ends of the curve. Specifywhether the selected curve is Bspline or Faceted.

For Bspline curves the following options are available.

Curve(s)Click on the icon and select the curve(s).

How

• Both

This option creates two points at the ends of the curve. The point at the start of the curve (parameter= 0) will be named by default “pnt.01” and the end point (parameter = 1) will be named “pnt.02”.

• Min or Max coordinates

These options will create a point at the location along the curve at the specified minimum or max-imum coordinate. For example, if the xmin option is selected, the point along the curve with theminimum X coordinate will be created.

Note

If xmin = xmax for a curve, xmin will be created at the starting point of the curve andxmax at the end point. This command creates end points and not the peak points of theentire curve.

For Faceted curves, the following options are available.

Curve(s)Click on the icon and select the curve(s).

Angle for curvesAllows you to extract points only for curves with angles greater than the specified angle.

Curve-Curve Intersection

The Curve-Curve Intersection option allows you to create a point at the intersection of two curves. Selectthe intersecting curves.

Gap ToleranceThe distance between the two curves should be less than this value to create an intersection point.

Parameter along a Curve

The Parameter along a Curve option allows you to create a parametric point along a curve, select fromthe following two methods.

• N Points

Enter a number (N) of parametric points that you want to create along a curve.

ANSYS ICEM CFD 13.0 - © SAS IP, Inc. All rights reserved. - Contains proprietary and confidential in-formation of ANSYS, Inc. and its subsidiaries and affiliates.176

Geometry

Page 13: ME554 Lab 8 airfoil - calpoly.edukshollen/ME554/Labs/ME554_Lab_8_airfoil.pdf · airfoil to insure turbulent flow over most of the airfoil. The area used for the definition of the

DRAFT

13

in Parameter(s) text edit box click LMB and enter 0.25, select Select curve(s) using LMB (if not in screen select mode), select crv.00 using LMB and verify the Message Done: points pnt.08, in Parameter(s) text edit box click LMB and enter 0.75, select crv.00 using LMB and verify the Message Done: points pnt.09, in Part text edit box click LMB and enter PNT_INT, in Parameter(s) text edit box click LMB and enter 0.05, select crv_af0 using LMB and verify the Message Done: points pnt.10, select crv_af1 using LMB and verify the Message Done: points pnt.11,

select Curve-Curve Intersection using LMB, select crv.04 and crv_af0 using LMB and verify the Message Done: points pnt.12, select crv.04 and crv_af1 using LMB and verify the Message Done: points pnt.13,

select Curve Ends using LMB, under Curve Type ensure BSpline is selected, under Curve Ends, How select xmax from pull down menu, select crv_af0 using LMB and then click MMB to create point at end of airfoil, verify the Message Done: points pnt.14, and click Dismiss using LMB. Function Tab - From Geometry select Delete Any Entity using LMB. DEZ - For Delete Any Entity enter the following: select Select geometry using LMB (if not in screen select mode), select crv.04 using LMB and then click MMB to delete curve, and click Dismiss using LMB. Step 7. Create Surface for Fluid Flow Function Tab - From Geometry select Create/Modify Surface using LMB. DEZ - For Create/Modify Surface enter the following: ensure Inherit Part is NOT selected, in Part text edit box click LMB and enter FLUID,

select Simple Surface using LMB, under Surf Simple Method ensure From 2-4 Curves is selected from pull down menu, select Select curve(s) using LMB (if not in screen select mode), select crv.00, crv.01, crv.02, and crv.3 using LMB and then click MMB, verify the Message Done: surface srf.00, and click DISMISS using LMB.

Curve Ends

The Curve Ends option allows you to select a curve to create points at the 2 ends of the curve. Specifywhether the selected curve is Bspline or Faceted.

For Bspline curves the following options are available.

Curve(s)Click on the icon and select the curve(s).

How

• Both

This option creates two points at the ends of the curve. The point at the start of the curve (parameter= 0) will be named by default “pnt.01” and the end point (parameter = 1) will be named “pnt.02”.

• Min or Max coordinates

These options will create a point at the location along the curve at the specified minimum or max-imum coordinate. For example, if the xmin option is selected, the point along the curve with theminimum X coordinate will be created.

Note

If xmin = xmax for a curve, xmin will be created at the starting point of the curve andxmax at the end point. This command creates end points and not the peak points of theentire curve.

For Faceted curves, the following options are available.

Curve(s)Click on the icon and select the curve(s).

Angle for curvesAllows you to extract points only for curves with angles greater than the specified angle.

Curve-Curve Intersection

The Curve-Curve Intersection option allows you to create a point at the intersection of two curves. Selectthe intersecting curves.

Gap ToleranceThe distance between the two curves should be less than this value to create an intersection point.

Parameter along a Curve

The Parameter along a Curve option allows you to create a parametric point along a curve, select fromthe following two methods.

• N Points

Enter a number (N) of parametric points that you want to create along a curve.

ANSYS ICEM CFD 13.0 - © SAS IP, Inc. All rights reserved. - Contains proprietary and confidential in-formation of ANSYS, Inc. and its subsidiaries and affiliates.176

Geometry

Curve Ends

The Curve Ends option allows you to select a curve to create points at the 2 ends of the curve. Specifywhether the selected curve is Bspline or Faceted.

For Bspline curves the following options are available.

Curve(s)Click on the icon and select the curve(s).

How

• Both

This option creates two points at the ends of the curve. The point at the start of the curve (parameter= 0) will be named by default “pnt.01” and the end point (parameter = 1) will be named “pnt.02”.

• Min or Max coordinates

These options will create a point at the location along the curve at the specified minimum or max-imum coordinate. For example, if the xmin option is selected, the point along the curve with theminimum X coordinate will be created.

Note

If xmin = xmax for a curve, xmin will be created at the starting point of the curve andxmax at the end point. This command creates end points and not the peak points of theentire curve.

For Faceted curves, the following options are available.

Curve(s)Click on the icon and select the curve(s).

Angle for curvesAllows you to extract points only for curves with angles greater than the specified angle.

Curve-Curve Intersection

The Curve-Curve Intersection option allows you to create a point at the intersection of two curves. Selectthe intersecting curves.

Gap ToleranceThe distance between the two curves should be less than this value to create an intersection point.

Parameter along a Curve

The Parameter along a Curve option allows you to create a parametric point along a curve, select fromthe following two methods.

• N Points

Enter a number (N) of parametric points that you want to create along a curve.

ANSYS ICEM CFD 13.0 - © SAS IP, Inc. All rights reserved. - Contains proprietary and confidential in-formation of ANSYS, Inc. and its subsidiaries and affiliates.176

Geometry

Delete Point

The Delete Point option deletes selected points.

Delete unattachedautomatically deletes unattached points.

Delete permanentlypermanently deletes the selected points and removes them from the database.

Join incident curvesIf two curves are attached at a point, and they do not form a sharp angle, then if the point is deleted,this option will concatenate the curve.

Delete All Dormant Pointsdeletes all dormant points.

Delete Curve

The Delete Curve option deletes selected curves.

Delete unattachedautomatically deletes unattached curves.

Delete permanentlypermanently deletes the selected curves and removes them from the database.

Delete All Dormant Curvesdeletes all dormant curves.

Delete Surface

The Delete Surface option permanently deletes the selected surfaces and removes them from the database.

Delete Body

The Delete Body option permanently deletes the selected bodies and removes them from the database.

Delete Any Entity

The Delete Any Entity option deletes selected entities.

Delete unattachedautomatically deletes unattached entities.

Delete permanentlypermanently deletes the selected entities and removes them from the database.

ANSYS ICEM CFD 13.0 - © SAS IP, Inc. All rights reserved. - Contains proprietary and confidential in-formation of ANSYS, Inc. and its subsidiaries and affiliates.238

Geometry

Page 14: ME554 Lab 8 airfoil - calpoly.edukshollen/ME554/Labs/ME554_Lab_8_airfoil.pdf · airfoil to insure turbulent flow over most of the airfoil. The area used for the definition of the

DRAFT

14

DCT - Under Model\Geometry use RMB to click on Curves and unselect Show Curve Names using LMB. Under Model\Geometry use the LMB to check the box before Surfaces and then use RMB to click on Surfaces and select Show Surface Names using LMB. Verify that the surface has been created and then unselect the box before Surfaces to hide it. NOTE: This step is not necessary for creating our mesh because the required surfaces are also created during the blocking step below. Step 8. Create Blocking To create the meshes in Labs 6 and 7 we used 2-D surface (or shell) meshing. For this lab to create the mesh we will use blocking, a useful tool for creating 2-D and 3-D structured grids for complicated geometries. Step 1 is to create a block (or rectangle for 2-D) around the entire geometry, consisting of edges and vertexes, which can be split up into sub-blocks (some of which can be deleted) depending on the requirements of the geometry. Step 2 associates the block vertexes and edges with the actual geometry points and curves, respectively. Step 3 specifies the distribution of nodes along each edge from which a structured mesh is generated for each block and then mapped to the actual geometry. Figure 10 shows an example for a simple pipe flow. For step 1, an initial single block is split twice vertically and once horizontally. Then, the bottom left and right blocks are deleted leaving four sub-blocks as shown on the left. For step 2, the vertexes and edges of the block are associated with the actual pipe geometry on the right such that the bottom sub-block corresponds to the small pipe and the three top blocks corresponded to the large pipe. For step 3, node distributions on each edge of the sub-blocks are specified, structured meshes are created on each sub-block, and then mapped to the actual pipe flow as shown.

Figure 10. Example of a block mesh mapped onto a curved pipe geometry.

For the airfoil, a more complicated blocking strategy is required to obtain a higher quality mesh for the inlet and around the airfoil. The O-grid block option splits a single block into 5 sub-

!

Page 15: ME554 Lab 8 airfoil - calpoly.edukshollen/ME554/Labs/ME554_Lab_8_airfoil.pdf · airfoil to insure turbulent flow over most of the airfoil. The area used for the definition of the

DRAFT

15

blocks in 2-D (7 sub-blocks in 3D) as shown in Figure 11. It arranges grid lines into an “O” shape to reduce skew where a block corner lies on a continuous curve or surface. Figure 11 shows for a simple disk the mesh created using the O-grid option will have elements that are less skewed and orthogonal along the curved boundary.

Figure 10. Comparison of single block and O-grid block meshes mapped to a circle. For the airfoil we will use a modified O-grid called a C-grid to initially spit the blocks, make additional vertical and horizontal splits, and finally delete and merge some of the blocks to obtain the more complicated sub-block configuration shown in Figure 12. Note that the blocking strategy shown is a common configuration, but there are many others that can be used to map the flow around an object in external flow depending on its geometry.

!

"#!$%&!&'()*$!+,(-!.#/,01!-23341!5(!2!

)0,)'4!

607/'4!&'()*!/,01!-23341!5(!2!)0,)'4!

Page 16: ME554 Lab 8 airfoil - calpoly.edukshollen/ME554/Labs/ME554_Lab_8_airfoil.pdf · airfoil to insure turbulent flow over most of the airfoil. The area used for the definition of the

DRAFT

16

Figure 12. Schematic of blocking strategy for airfoil. Vertexes are indicated by number.

Function Tab - From Blocking select Create Block using LMB. DEZ - For Create Block enter the following: under Part select FLUID from pull down menu, under Initialize Blocks Type select 2D Planar from pull down menu, and click Apply and Dismiss using LMB. DCT - Expand Blocking menu by using LMB to change + to -. Under Model\Blocking use LMB to check the boxes left of Vertices and Blocks, use RMB to click on Vertices, and select Numbers using LMB.

Function Tab - From Blocking select Split Block using LMB. DEZ - For Split Block enter the following:

select Ogrid Block using LMB, select Select Block(s) using LMB, select block 4 (the only one) using LMB and then click MMB, select Select Edge(s) using LMB, select edge between verticies 19 and 21 using LMB and then click MMB, click Apply using LMB to create sub-blocks for C-grid (notice the shape), and click Dismiss using LMB.

select Split Block using LMB.

pnt.00

pnt.01

pnt.02

pnt.03

pnt.07

pnt.05

pnt.06pnt.04

pnt.08

pnt.09

pnt.10

pnt.11

pnt.12

pnt.13

pnt.14

crv.00 crv.01

crv.02

crv.03

crv_af0

crv_af1

11

13

41 21

19

3542

33

32

39

47

45

48

46

Blocking

Figure: Blocking Menu

The Blocking tab contains the following options to create blocking over any geometry.Create BlockSplit BlockMerge VerticesEdit BlockAssociateMove VertexTransform BlocksEdit EdgePre-Mesh ParamsPre-Mesh QualityPre-Mesh SmoothBlock ChecksDelete Block

Create Block

Figure: Create Block Options

The following options are available for creating blocks:Initialize BlockFrom Vertices/FacesExtrude Face2D to 3D Blocks3D to 2D

317ANSYS ICEM CFD 13.0 - © SAS IP, Inc. All rights reserved. - Contains proprietary and confidential in-

formation of ANSYS, Inc. and its subsidiaries and affiliates.

Figure: 3D Blocking

Figure: 2D Blocking

Split Block

The following options are available for splitting blocks:Split BlockOgrid BlockExtend SplitSplit FaceSplit VerticesSplit Free FaceImprint Free Face

ANSYS ICEM CFD 13.0 - © SAS IP, Inc. All rights reserved. - Contains proprietary and confidential in-formation of ANSYS, Inc. and its subsidiaries and affiliates.336

Blocking

Note

The Split Block option will only propagate splits through mapped faces, and will terminate atfree faces. For 2D blocking, all mapped blocks attached edge to edge will be split, but the splitwill terminate at any free block. For 3D blocking, a split will propagate through mapped blocksand swept blocks, if the split is along the sweeping direction. A split in 3D blocking will terminateat free 3D blocks and swept blocks, if the split is in any direction other than the sweeping direction.

Ogrid Block

The Ogrid Block option allows you to modify a single block or blocks to a 5 sub-block topology (7 sub-blocks in 3D) as shown below. It arranges grid lines into an “O” shape to reduce skew where a block cornerlies on a continuous curve or surface. There are several variations of the basic O-grid generation technique.

Figure: O-grid Demonstration

The O-grid can be created with or without face selection as shown in Figure: O-grid Creation With and WithoutFace Selection (p. 339).

ANSYS ICEM CFD 13.0 - © SAS IP, Inc. All rights reserved. - Contains proprietary and confidential in-formation of ANSYS, Inc. and its subsidiaries and affiliates.338

Blocking

Figure: 3D Blocking

Figure: 2D Blocking

Split Block

The following options are available for splitting blocks:Split BlockOgrid BlockExtend SplitSplit FaceSplit VerticesSplit Free FaceImprint Free Face

ANSYS ICEM CFD 13.0 - © SAS IP, Inc. All rights reserved. - Contains proprietary and confidential in-formation of ANSYS, Inc. and its subsidiaries and affiliates.336

Blocking

Page 17: ME554 Lab 8 airfoil - calpoly.edukshollen/ME554/Labs/ME554_Lab_8_airfoil.pdf · airfoil to insure turbulent flow over most of the airfoil. The area used for the definition of the

DRAFT

17

under Split Method select Prescribed point from pull down menu, select Select Edge(s) using LMB, select edge between verticies 13 and 21 using LMB, select pnt.03 using LMB to create first vertical split, select edge between verticies 13 and 41 using LMB, select pnt.01 using LMB to create second vertical split, and click Dismiss using LMB.

Function Tab - From Blocking select Delete Block using LMB. DEZ - For Delete Block enter the following: select Select Blocks(s) using LMB (if not in screen select mode), select blocks 4 and 21 using LMB and then click MMB, and click Dismiss using LMB. NOTE: This step removes the blocks in the middle of the domain corresponding to the airfoil.

Function Tab - From Blocking select Merge Verticies using LMB. DEZ - For Merge Verticies enter the following:

under Merge Verticies select Collapse Blocks , select edge between verticies 34 and 35 using LMB, select block 17 using LMB and then click MMB, and click Dismiss using LMB. NOTE: This step removes the blocks at the back of the airfoil for an airfoil with a pointed trailing edge. This is not done for a blunt trailing edge. DCT - Under Model\Blocking use LMB to uncheck the box left of Blocks. NOTE: For the block, boundary edges are colored black and interior edges are light blue. Also, some of the blocks are twisted. This will be fixed when we associate the verticies and edges. Function Tab - From Blocking select Associate using LMB. DEZ - For Blocking Associations enter the following:

under Edit Associations select Associate Vertex using LMB, under Entity ensure Point is selected, select Select vert(s) using LMB, select vertex 47 using LMB and select pnt.01 using LMB (where these overlap), repeat selecting the remaining verticies and corresponding points in Table 2, and click Dismiss using LMB.

Block Checks

The Block Checks option allows you to check the blocks. The following methods are available for check-ing/fixing blocks:

Run Check/Fixchecks the internal data structures for inconsistencies and fixes them if possible.

Fix Inverted Blockfixes all the Inverted blocks. Inverted blocks have a negative determinant.

Invert Selected Block Methodinverts the selected blocks.

Pack Block Numbersautomatically renumbers all blocks in sequential order. This is to avoid very large block numbers thatcan result after repeated block editing and VORFN rebuilds.

Delete Block

The Delete Block option allows you to delete the blocks from the topology. The Delete permanently optionis disabled by default.

If Delete permanently is disabled, the block will be moved to the VORFN part. The VORFN part is essentiallydormant and mesh is not computed for it, however it does help to maintain connectivity. Blocks can be re-trieved from the VORFN region using the Add Blocks to Part option.

If Delete permanently is enabled, the block will be permanently deleted. At this point connectivity will bebroken and the VORFN region will be rebuilt. This can be useful in some situations, but this will also resultin a re-indexing of the blocking. The resulting index structure is usually more complicated and may be moredifficult to work with.

Figure: Example of Delete Blocks Permanently

Note that there are an equal number of nodes across the hole.

Block selected to be deleted.

ANSYS ICEM CFD 13.0 - © SAS IP, Inc. All rights reserved. - Contains proprietary and confidential in-formation of ANSYS, Inc. and its subsidiaries and affiliates.404

Blocking

Merge Vertices

Figure: Merge Vertices Options

The following options are available for merging vertices:Merge VerticesMerge Vertices by ToleranceCollapse BlockMerge Vertex to Edge

Merge Vertices

The Merge Vertices option allows you to merge two or more vertices.

Two vertices can be merged with the following options:

Propagate mergepropagates the merged vertices throughout the affected block(s).

Merge to averagemerges at the average distance of the two vertices.

Rebuild orphandeletes the VORFN part and rebuilds it. This may be necessary in some cases to clean up the VORFNblocks.

These options can be used in different combinations as illustrated for the example of the two vertices to bemerged in Figure: Selection of Vertices to be Merged (p. 347). When selecting the vertices, the first vertex isretained and the second vertex is merged with the first.

ANSYS ICEM CFD 13.0 - © SAS IP, Inc. All rights reserved. - Contains proprietary and confidential in-formation of ANSYS, Inc. and its subsidiaries and affiliates.346

Blocking

Collapse Block

The Collapse Block option allows you to collapse a block or an edge by shrinking one or more edges tozero length. This modifies the topology of the remaining non-degenerate blocks. Select the edge to definethe direction that is to be collapsed to zero size. It is possible to add blocks interactively, which will all becollapsed in the specified direction.

In Figure: Selection of Blocks and Edge for Collapse (p. 349), the edges and blocks selected to be collapsed areshown in red. Figure: Collapsed Blocks (p. 349) shows the collapsed blocks.

Figure: Selection of Blocks and Edge for Collapse

Figure: Collapsed Blocks

Merge Vertex to Edge

The Merge Vertex to Edge option allows you to merge a selected vertex and edge. The selected edge willbe split and merged with the selected vertex.

This is most often utilized when the region between the edge and vertex contains no blocks, and the twodisconnected topologies which do not have matching vertices can be merged. Examples of this would includeconnecting bottom up blocking or merging blocking topologies.

Figure: Connected Blocking Topologies (p. 350) shows two sub topologies which are connected at the cornersbut not the middle. The resulting surface mesh is shown in Figure: Resulting Surface Mesh — Unmatched (p. 350).The top of the lower part is curved to fit the upper part as the edges are projected to the same curves.However, as the edges are not shared, the mesh across these edges is neither connected nor matched.

349ANSYS ICEM CFD 13.0 - © SAS IP, Inc. All rights reserved. - Contains proprietary and confidential in-

formation of ANSYS, Inc. and its subsidiaries and affiliates.

Merge Vertex to Edge

Associate

Figure: Blocking Associations Options

The following options are available for blocking associations.Associate VertexAssociate Edge to CurveAssociate Edge to SurfaceAssociate Face to SurfaceDisassociate from GeometryUpdate AssociationsReset AssociationsSnap Project VerticesGroup/Ungroup CurvesAuto Associate

Associate Vertex

The Associate Vertex option allows you to associate vertices and project the vertex onto itself, points,curves, and surfaces. Select the vertex and the entity to project it onto.

Associate Edge to Curve

The Associate Edge to Curve option allows you to associate the edges of blocks to curves. The vertices atthe end of the edges are also associated to the same curve unless they were previously associated to anothercurve or point. Edge segments can be individually associated after using edge splits. Multiple edges can beassociated with multiple curves, but all the curves will be grouped into a single composite curve.

Note

Associating edges to curves also results in the creation of line elements along those curves. For2D planar blocking, it is essential that all the perimeter edges be associated with perimeter curvesbecause many solvers use the perimeter line elements as boundaries.

Project verticesIf enabled, the vertices will automatically be projected to the corresponding curves.

Project to surface intersectionIf enabled, the surface-surface intersection will be captured correctly. This is for poor geometry situationswhere the intersection curve may not match with the intersection of the surfaces. If you associate anedge with a curve using this option, the edge will be colored purple. The edge is associated with the

359ANSYS ICEM CFD 13.0 - © SAS IP, Inc. All rights reserved. - Contains proprietary and confidential in-

formation of ANSYS, Inc. and its subsidiaries and affiliates.

Associate Edge to Curve

Associate

Figure: Blocking Associations Options

The following options are available for blocking associations.Associate VertexAssociate Edge to CurveAssociate Edge to SurfaceAssociate Face to SurfaceDisassociate from GeometryUpdate AssociationsReset AssociationsSnap Project VerticesGroup/Ungroup CurvesAuto Associate

Associate Vertex

The Associate Vertex option allows you to associate vertices and project the vertex onto itself, points,curves, and surfaces. Select the vertex and the entity to project it onto.

Associate Edge to Curve

The Associate Edge to Curve option allows you to associate the edges of blocks to curves. The vertices atthe end of the edges are also associated to the same curve unless they were previously associated to anothercurve or point. Edge segments can be individually associated after using edge splits. Multiple edges can beassociated with multiple curves, but all the curves will be grouped into a single composite curve.

Note

Associating edges to curves also results in the creation of line elements along those curves. For2D planar blocking, it is essential that all the perimeter edges be associated with perimeter curvesbecause many solvers use the perimeter line elements as boundaries.

Project verticesIf enabled, the vertices will automatically be projected to the corresponding curves.

Project to surface intersectionIf enabled, the surface-surface intersection will be captured correctly. This is for poor geometry situationswhere the intersection curve may not match with the intersection of the surfaces. If you associate anedge with a curve using this option, the edge will be colored purple. The edge is associated with the

359ANSYS ICEM CFD 13.0 - © SAS IP, Inc. All rights reserved. - Contains proprietary and confidential in-

formation of ANSYS, Inc. and its subsidiaries and affiliates.

Associate Edge to Curve

Page 18: ME554 Lab 8 airfoil - calpoly.edukshollen/ME554/Labs/ME554_Lab_8_airfoil.pdf · airfoil to insure turbulent flow over most of the airfoil. The area used for the definition of the

DRAFT

18

NOTE: Each vertex should turn from black to red indicating it is associated with a point. For the first column, each vertex and point should already overlap. For the second column, each vertex will move to its associated point. When finished your blocking should look like Figure 12.

Table 2. Associations for each vertex and point. Vertex Point Vertex Point

47 pnt.01 13 pnt.08 45 pnt.02 11 pnt.09 41 pnt.03 33 pnt.10 39 pnt.04 32 pnt.11 21 pnt.05 48 pnt.12 19 pnt.06 46 pnt.13 35 pnt.07 42 pnt.14

DEZ - For Blocking Associations enter the following:

under Edit Associations select Associate Edge to Curve using LMB, select edges between verticies 11-13, 11-45, and 13-47 using LMB and then click MMB, select curve crv.00 using LMB and then click MMB, repeat selecting the remaining edges and corresponding curves in Table 3, and click Dismiss using LMB.

Table 3. Associations for each edge and curve. Description Edges Curve(s)

Far Field Inlet 11-13, 11-45, 13-47 crv.00 Far Field Upper 21-41, 41-47 crv.01 Far Field Lower 19-39, 39-45 crv.02 Far Field Outlet 19-35, 21-35 crv.03

Airfoil Wall 33-48, 42-48, 32-46, 42-46,

32-33

crv_af0, crv_af1

NOTE: Each block edge should turn from black to green indicating it is associated with a curve. Step 6. Mesh Blocks and Surface

Function Tab - From Blocking select Pre-Mesh Params using LMB.

Associate

Figure: Blocking Associations Options

The following options are available for blocking associations.Associate VertexAssociate Edge to CurveAssociate Edge to SurfaceAssociate Face to SurfaceDisassociate from GeometryUpdate AssociationsReset AssociationsSnap Project VerticesGroup/Ungroup CurvesAuto Associate

Associate Vertex

The Associate Vertex option allows you to associate vertices and project the vertex onto itself, points,curves, and surfaces. Select the vertex and the entity to project it onto.

Associate Edge to Curve

The Associate Edge to Curve option allows you to associate the edges of blocks to curves. The vertices atthe end of the edges are also associated to the same curve unless they were previously associated to anothercurve or point. Edge segments can be individually associated after using edge splits. Multiple edges can beassociated with multiple curves, but all the curves will be grouped into a single composite curve.

Note

Associating edges to curves also results in the creation of line elements along those curves. For2D planar blocking, it is essential that all the perimeter edges be associated with perimeter curvesbecause many solvers use the perimeter line elements as boundaries.

Project verticesIf enabled, the vertices will automatically be projected to the corresponding curves.

Project to surface intersectionIf enabled, the surface-surface intersection will be captured correctly. This is for poor geometry situationswhere the intersection curve may not match with the intersection of the surfaces. If you associate anedge with a curve using this option, the edge will be colored purple. The edge is associated with the

359ANSYS ICEM CFD 13.0 - © SAS IP, Inc. All rights reserved. - Contains proprietary and confidential in-

formation of ANSYS, Inc. and its subsidiaries and affiliates.

Associate Edge to Curve

Unsplit Edge

The Unsplit Edge option allows you to remove splits from edges. For the Single method, select the vertexof the split edge to remove. For the All method, select the edge to remove all the splits.

Link Edge

The Link Edge option allows you to set the shape of edges. Select the target edges and then the edge forthe source of the shape.

Selectedsets the shape of only the selected edge.

In dimensionsets the shape automatically for all connected edges. Select the source edge for the Link Edge Dimension,the Source index or vertex, and the Target index or vertex.

Unlink Edge

The Unlink Edge option allows you to unset the shapes of edges linked by the Link Edge option.

Pre-Mesh Params

Figure: Pre-Mesh Parameters Options

The following options are available for Pre-Mesh parameters:Update SizesScale SizesEdge ParamsMatch EdgesRefinement

Update Sizes

The Update Sizes option allows you to update sizes in the pre-mesh. The following options are availablefor updating sizes in the pre-mesh:

Update Allcomputes the edge node spacing based on constraint equations with the default (BiGeometric) meshinglaw. You can adjust the number of nodes on each edge based on the Global Surface or Curve MeshSize and by default each edge will follow the BiGeometric geometry law.

ANSYS ICEM CFD 13.0 - © SAS IP, Inc. All rights reserved. - Contains proprietary and confidential in-formation of ANSYS, Inc. and its subsidiaries and affiliates.374

Blocking

Page 19: ME554 Lab 8 airfoil - calpoly.edukshollen/ME554/Labs/ME554_Lab_8_airfoil.pdf · airfoil to insure turbulent flow over most of the airfoil. The area used for the definition of the

DRAFT

19

DEZ - For Pre-Mesh Params enter the following:

under Meshing Parameters select Edge Params using LMB, scroll down and select Copy Parameters using LMB under Copy Method ensure To All Parallel Edges is selected from pull down menu, scroll up and select Select Edges(s) using LMB, select edge between verticies 11 and 13 using LMB, under Mesh law select Uniform from pull down menu, under Nodes enter 21, NOTE: The edge meshing will automatically be applied, recorded in the replay script, and shown in the display window using red tick marks and a number as soon as you enter or change the number of nodes so you do not need to click Apply. select Select Edges(s) using LMB, select edge between verticies 13 and 47 using LMB, under Mesh law select Uniform from pull down menu, under Nodes enter 11, select Select Edges(s) using LMB, select edge between verticies 47 and 41 using LMB, under Mesh law select Uniform from pull down menu, under Nodes enter 161, select Select Edges(s) using LMB, select edge between verticies 41 and 21 using LMB, under Mesh law select BiGeometric from pull down menu, under Spacing 1 enter 0.005 (for beginning node spacing based on arrow direction), under Ratio 1 enter 1.1 (for target geometric growth ratio), under Nodes enter 21 (for actual Ratio 1 of 1.52123 as indicated due to constraints), select Select Edges(s) using LMB, select edge between verticies 21 and 35 using LMB, under Mesh law select BiGeometric from pull down menu, under Spacing 2 enter 1e-3 (for ending node spacing based on arrow direction), under Ratio 2 enter 1.1 (for target geometric growth ratio), under Nodes enter 51 (for actual Ratio 1 of 1.31547 as indicated due to constraints), click Dismiss using LMB. DCT - Under Model\Blocking select Pre-Mesh. In Mesh Dialog Box select Yes to compute mesh. NOTE: You should produce a structured mesh in the flow region surrounding the airfoil with the node spacing specifications summarized in Table 4. Zoom in to inspect the details of the mesh surrounding the airfoil. Note that it is important for the elements (1) to be concentrated in the

Scale Sizes

The Scale Sizes option allows you to specify the factor by which the mesh size should be globally multiplied.After clicking Apply, you will be asked whether to recompute the mesh.

In Figure: Block Mesh Scaled by Factor of Two (p. 377), the mesh size (from Figure: Initial Block Mesh (p. 377))was changed by a factor of 2.

Figure: Initial Block Mesh

Figure: Block Mesh Scaled by Factor of Two

Edge Params

The Edge Params option allows you to modify the mesh parameters in a detailed manner by specifyingvarious bunching laws and the node spacing along any particular edge. Each edge has several parametersthat determine the spacing of the mesh along the edge: number of nodes, the meshing law, initial lengthat the beginning/end of the edge, the expansion of the mesh from the beginning/end of the edge to theinterior, and the maximum element length along the edge.

The Edge Params icon brings up a window with all the mesh parameters. Once an edge has been selected,the mesh parameters for that edge will be displayed. All parameter values may be modified, except for theEdge ID and the Edge Length, which are pre-defined.

377ANSYS ICEM CFD 13.0 - © SAS IP, Inc. All rights reserved. - Contains proprietary and confidential in-

formation of ANSYS, Inc. and its subsidiaries and affiliates.

Edge Params

Page 20: ME554 Lab 8 airfoil - calpoly.edukshollen/ME554/Labs/ME554_Lab_8_airfoil.pdf · airfoil to insure turbulent flow over most of the airfoil. The area used for the definition of the

DRAFT

20

boundary layer region near the airfoil wall, (2) to not be significantly skewed, (3) to have edges that are orthogonal with the wall, and (4) to vary smoothly in size in critical flow regions. Our mesh satisfies these requirements adequately. Additional blocks, smoothing, and many more nodes can be used to create a better mesh, but to keep this simple and reduce run time this is an adequate mesh for this lab. Refer to NASA's Turbulence Modeling Resource web site [1] to see a high quality mesh (with a much larger far field) for testing turbulence models.

Table 4. Node spacing for block edges with Copy to Parallel Edges. Mesh size is 20 (c/a) N2 elements.

Description Edges Nodes Mesh Law Spacing 1/ Ratio 1

Spacing 2/ Ratio 2

Inlet - Airfoil Front 11-13 2 N + 1 Uniform 0 / 2 0 / 2 Inlet -Airfoil Middle 13-47 N + 1 Uniform 0 / 2 0 / 2

Inlet - Airfoil Tail 47-41 2 (c/a – 2) N + 1 Uniform 0 / 2 0 / 2 Upper/Lower 41-21 2 N + 1 BiGeometric a/(2 N) / 1.1 0 / 2

Outlet 21-35 5 N + 1 BiGeometric 0 / 2 1e-3 / 1.1 NOTE: The mesh created above is for c = 1.0 m, a = 0.1 m, and N = 10 which corresponds to a total mesh size of 20,000 elements. Also, mesh law settings with spacing set to 0 and ratio set to 2 are ignored when calculating actual node spacing. Step 7. Save Files and Export Initial Mesh In Replay Control window unselect Record (after current) to stop recording your script. Click Save and use the Save Script File Dialog Box to save a copy of your script file. An edited version of a script file named lab_8_airfoil.rpl that can be used to create this mesh is available from my web page and in Appendix A. It is similar to the one you created, except that all unnecessary lines have been removed, comment lines have been added, geometry parameters are defined to make it easier to change mesh parameters, and lines to set the boundary conditions are included at the end. Main Menu - From File pull down menu, select Blocking -> Save Unstructured Mesh using LMB. Use the Save Mesh as Dialog Box to save the unstructured mesh. Function Tab - From Output select Output To Fluent V6 using LMB. In Family boundary conditions dialog box: expand Edges menu by using LMB to change + to -, expand INLET menu by using LMB to change + to -, click Create new to open the Selection dialog box, under Boundary Conditions select velocity-inlet using the LMB, click Okay using LMB to close the Selection dialog box, expand LOWER menu by using LMB to change + to -, click Create new to open the Selection dialog box,

Page 21: ME554 Lab 8 airfoil - calpoly.edukshollen/ME554/Labs/ME554_Lab_8_airfoil.pdf · airfoil to insure turbulent flow over most of the airfoil. The area used for the definition of the

DRAFT

21

under Boundary Conditions select symmetry using the LMB, click Okay using LMB to close the Selection dialog box, expand OUTLET menu by using LMB to change + to -, click Create new to open the Selection dialog box, under Boundary Conditions select pressure-outlet using the LMB, click Okay using LMB to close the Selection dialog box, expand UPPER menu by using LMB to change + to -, click Create new to open the Selection dialog box, under Boundary Conditions select symmetry using the LMB, click Okay using LMB to close the Selection dialog box, expand WALL_AF menu by using LMB to change + to -, click Create new to open the Selection dialog box, under Boundary Conditions select wall using the LMB, click Okay using LMB to close the Selection dialog box, click Accept using LMB. In Save dialog box click Yes using LMB to Save current project first. In Open dialog box select unstructured mesh for the current project and click Open. In Fluent V6 dialog box enter the following: in Grid dimension select 2D using LMB, in Scaling ensure No is selected, in Write binary file ensure No is selected, in Ignore couplings ensure No is selected, in Boco file retain the default file name, in Output file change the file from fluent to a new name for your first mesh, and click Done using LMB.

Page 22: ME554 Lab 8 airfoil - calpoly.edukshollen/ME554/Labs/ME554_Lab_8_airfoil.pdf · airfoil to insure turbulent flow over most of the airfoil. The area used for the definition of the

DRAFT

22

FLUENT Similar to the mesh, turbulence models must be carefully selected that are capable of correctly modeling wall interactions so that quantities like wall shear stresses (used to calculate drag) and temperature gradients (used to calculate heat transfer rates) can be accurately predicted. For this class will use the k-ε turbulence model which is an older, but still very popular model for CFD simulations. However, this model in its simplest form is primarily valid for the turbulent core region away from walls. Therefore, the simplest version of the k-ε model must be modified to model the near-wall region. The following are two common approaches used: (1) Wall Function Method: The viscous sublayer and buffer layer are not resolved. Instead, semi-empirical formulas called “wall functions” (Equations (12) and (13) for the velocity) are used to bridge the viscosity-affected regions between the wall and the log-law layer. The use of wall functions eliminates the need to modify the turbulence models to account for the presence of the wall. The wall function method is in general economical, robust, and reasonably accurate. The wall function method is further divided into “standard” and “non-equilibrium” versions. The non-equilibrium version more accurately accounts for the effects of pressure gradients and departures from equilibrium and is recommended for flows with high pressure gradients and separation. The following mesh requirements should be used for this method:

• The wall-adjacent cell’s centroid should be located between

30 < y + < 300 which is in the log-law layer. A

y + value close to the lower bound (

y + ≈ 30) is most desirable.

• Excessive stretching in the direction normal to the wall should be avoided.

• There should be at least about 3-5 cells inside the boundary layer. (2) Near-Wall Modeling: The turbulence models are modified to enable the viscosity-affected region to be resolved with a mesh all the way to the wall, including the viscous sublayer. Because the resulting equations are more complicated and the mesh needs to be more refined near the wall this method is computationally more expensive. However, in situations where the details of the boundary layer need to be resolved or they do not follow the standard relations given by the wall functions this method will be much more accurate. The following mesh requirements should be used for this method:

• The wall-adjacent cell’s centroid should be located between

0 < y + < 5 which is in the viscous sublayer. A

y + value close to 1 is most desirable.

• Excessive stretching in the direction normal to the wall should be avoided.

• There should be at least 10 cells inside the viscosity-affected near-wall region. Note that for both of these methods it is very important that the wall adjacent cell’s centroid not lie in the buffer region (

5 < y + < 30).

Page 23: ME554 Lab 8 airfoil - calpoly.edukshollen/ME554/Labs/ME554_Lab_8_airfoil.pdf · airfoil to insure turbulent flow over most of the airfoil. The area used for the definition of the

DRAFT

23

For our case of turbulent flow over an airfoil for low angle of attack with minimal flow separation, any of these models will perform reasonably well. Complete the following steps: Step 1. Read In Mesh Import your first mesh created using ICEM CFD into FLUENT. Check to make sure the mesh imported correctly and that your scale is correct such that the airfoil is 1 m in length. Step 2. Problem Setup for Initial Simulation In the Navigation Pane under Problem Setup use the following steps to setup your simulation: General, Solver • Type: Pressure-Based • Time: Steady • Velocity Formulation: Absolute • 2D Space: Planar Models (remaining models off) • Energy: On • Viscous (use defaults for coefficients and remaining options)

o Model: k-epsilon o k-epsilon Model: Realizable o Near-Wall Treatment: Non-Equilibrium Wall Functions

Materials, Fluid, air (change the properties for air to those at 300 K) • Density: 1.236 kg/m3 • Specific Heat: 1,006 J/kg•K • Thermal Conductivity: 0.0250 W/m•K • Viscosity: 1.80e-5 kg/m•s Cell Zone Conditions • Zone: fluid

o Type: fluid o Material Name: air

• Operating Conditions o Operating pressure: 101,325 Pa o Gravity: NOT selected

Boundary Conditions • Zone: inlet

o Type: velocity-inlet o Edit: Momentum tab

• Velocity Specification Method: Components • x-Velocity: 42.0 m/s, y-Velocity: 0 m/s • Turbulence, Specification Method: Intensity and Viscosity Ratio

Page 24: ME554 Lab 8 airfoil - calpoly.edukshollen/ME554/Labs/ME554_Lab_8_airfoil.pdf · airfoil to insure turbulent flow over most of the airfoil. The area used for the definition of the

DRAFT

24

• Turbulent Intensity: 1% • Turbulent Viscosity Ratio: 1.0

o Edit: Thermal tab • Temperature: 266.5 K

• Zone: outlet o Type: pressure-outlet o Edit: Momentum tab

• Gage Pressure: 0 Pa, • Turbulence, Specification Method: Intensity and Viscosity Ratio • Turbulent Intensity: 1% • Turbulent Viscosity Ratio: 1.0

o Edit: Thermal tab • Temperature: 266.5 K

• Zone: wall o Type: wall_af o Edit: Momentum tab

• Wall Motion: Stationary Wall • Shear Condition: No-Slip

o Edit: Thermal tab • Temperature: 305 K

• Zone: bottom o Type: symmetry

• Zone: top o Type: symmetry

Step 3: Solution Setup for Simulation In the Navigation Pane under Solution use the following steps to setup your solution methods, controls, monitors, and initialization: Solution Methods • Pressure-Velocity Coupling

o Scheme: SIMPLE • Spatial Discretization

o Gradient: Least Squares Cell Based o Pressure: Standard o Momentum: Second Order Upwind o Turbulent Kinetic Energy: Second Order Upwind o Turbulent Dissipation Rate: Second Order Upwind o Energy: Second Order Upwind

Solution Controls • Under-Relaxation Factors: default values Monitors, Residuals • Options

Page 25: ME554 Lab 8 airfoil - calpoly.edukshollen/ME554/Labs/ME554_Lab_8_airfoil.pdf · airfoil to insure turbulent flow over most of the airfoil. The area used for the definition of the

DRAFT

25

o Print to Console: selected o Plot: selected

• Equations, Residual o Monitor: selected for all o Check Convergence: selected for all o Absolute Criteria: 1e-6 for all

Solution Initialization • Compute from: inlet Step 4. Run Calculation Navigation Pane - Under Solution select Run Calculation. Task Page - Under Number of Iterations enter 500 and click Calculate. The residuals should flatten out after 500 iterations which will take about 10 minutes. Because a significant portion of the domain does not change this can be considered as sufficient for convergence. Step 5. Make Contour Plots Visualize your results by displaying a contour plot of temperature. You should see a VERY thin layer of hot fluid near the surface of the airfoil. You will have to zoom in to see this. Step 6. Define Reference Values Set the reference values used to calculate the pressure coefficient and heat transfer coefficient. For depths and length use 1 m (for the chord length and wing span) and for area use 1 m2. For the flow conditions use those upstream of the airfoil and the properties for air set earlier using the following steps: Navigation Pane - Under Problem Setup select Reference Values. Task Page - Under Reference Values select the following: under Compute From select inlet and under Reference Zone select fluid from the pull-down menus. Step 7. Make xy Plots Make an x/y plot of dimensionless wall unit, y+, for first cell along plate: In the Solution XY Plot Dialog Box do the following steps: select Position on X Axis, under Plot Direction for X enter 1 and for Y enter 0, under Y Axis Function select Turbulence and Wall Yplus, under Surfaces select wall_af, click on Plot.

Page 26: ME554 Lab 8 airfoil - calpoly.edukshollen/ME554/Labs/ME554_Lab_8_airfoil.pdf · airfoil to insure turbulent flow over most of the airfoil. The area used for the definition of the

DRAFT

26

NOTE: Check that y+ values are greater than 30, but not too high. This satisfies our mesh requirements for y+ when using the k-ε turbulence model with standard wall functions. Write the data to a file. Make an x/y plot of the pressure coefficient versus x-location: Navigation Pane - Under Results select Plots. Task Page - Under Plots select XY Plot and Set Up to open Solution XY Plot Dialog Box. In the Solution XY Plot Dialog Box do the following steps: select Position on X Axis, under Plot Direction for X enter 1 and for Y enter 0, under Y Axis Function select Pressure and Pressure Coefficient, under Surfaces select wall_af, click on Plot. NOTE: Compare your results to Figure 3. The pressure coefficient should be approximately 1 at the nose and have a minimum of approximately 0.4 along the airfoil. Write the data to a file. Make an x/y plot of Nusselt number versus x-location: In Solution XY Plot Dialog Box do the following steps: select Position on X Axis, under Plot Direction for X enter 1 and for Y enter 0, under Y Axis Function select Wall Fluxes and Nusselt Number, under Surfaces select wall_af, and click on Plot. NOTE: Future work for this lab will be to give data for comparison. Write the data to a file. Step 8. Calculate Total Drag Force and Heat Transfer Rate Navigation Pane - Under Results select Reports. Task Page - Select Forces and click Set Up to open the Force Reports Dialog Box. In Force Reports Dialog Box under Wall Zones select af_wall and click Print to display calculated forces in the Console. The pressure force should be very small because the airfoil is symmetric and at a 0˚ angle of attack. Record the magnitude of the total drag force. Under Direction Vector for X enter 0 and for Y enter 1 to calculate the total lift force. Again, at a 0˚ angle of attack this should be negligible for both friction and pressure. Task Page - Select Fluxes and click Set Up to open the Flux Reports Dialog Box.

Page 27: ME554 Lab 8 airfoil - calpoly.edukshollen/ME554/Labs/ME554_Lab_8_airfoil.pdf · airfoil to insure turbulent flow over most of the airfoil. The area used for the definition of the

DRAFT

27

In Force Reports Dialog Box under Options select Total Heat Transfer Rate, under Boundaries select wall, and click Compute to display calculated fluxes in Console. Record the magnitude of the total heat transfer rate. Step 9. Test Near-Wall Treatments Future work will be to add instructions to test the effect of near-wall treatments. Step 10. Test Mesh Refinement Future work will be to add instructions to test the effect of mesh refinement. Step 11. Test Domain Extents Future work will be to add instructions to test the effect of domain height. Step 12. Test Angle of Attack Future work will be to add instructions to test the effect of angle of attack and compare to published data to validate results. Assignment Future work will be to add instructions for documenting results from this laboratory.

Page 28: ME554 Lab 8 airfoil - calpoly.edukshollen/ME554/Labs/ME554_Lab_8_airfoil.pdf · airfoil to insure turbulent flow over most of the airfoil. The area used for the definition of the

DRAFT

28

References [1] NASA Langly Research Center, Turbulence Modeling Resource, “2D NACA 0012 Airfoil Validation Case, ” http://turbmodels.larc.nasa.gov/naca0012_val.html, October 10, 2011. [2] Poinsatte, P. E., Van Fossen, J. G., and DeWitt, K. J., “Convective Heat Transfer Measurements from a NACA 0012 Airfoil in Flight and in the NASA Leis Icing Research Tunnel,” NASA Technical Memorandum 102448 and AIAA-90-0199, Reno, Nevada, January 8-11, 1990. [3] Gregory, N. and O'Reilly. C. L., “Low-Speed Aerodynamic Characteristics of NACA 0012 Aerofoi] Section, including the Effects of Upper-Surface Roughness Simulating Hoar Frost,” Aerodynamics Division N.P.L, Reports and Memoranda No. 3726, January, 1970. [4] Ladson, C. L., “Effects of Independent Variation of Mach and Reynolds Numbers on the Low-Speed Aerodynamic Characteristics of the NACA 0012 Airfoil Section,” NASA Technical Memorandum 4074, October, 1988. [5] McCroskey, W. J., “A Critical Assessment of Wind Tunnel Results for the NACA 0012 Airfoil,” NASA Technical Memorandum 100019 and USA AVSCOM Technical Report 87-A-5, October 1987. [6] Sheldahl, R. E. and Klimas, P. C., “Aerodynamic Characteristics of Seven Symmetrical Airfoil Sections Through 180-Degree Angle of Attack for Use in Aerodynamic Analysis of Vertical Axis Wind Turbines,” Sandia National Laboratories Report, SAND80-2114, March 1981. [7] Swanson, R. C. and Turkel, E., “Artificial Dissipation and Central Difference Schemes for the Euler and Navier-Stokes Equations,” AIAA Computational Fluid Dynamics Conference, AIAA 87-1107-CP, 1987. [8] Wang, Q., “On the Prediction of Convective Heat Transfer Coefficients Using General-Purpose CFD Codes,” AIAA Meeting and Exhibit, AIAA 2001-0361, January 2001. [9] Reynolds, W. C., Kays, W. M., Kline, S. J., “Heat Transfer in the Turbulent Incompressible Boundary Layer,” NASA Memo 12-1-58W, December 1958. [10] Rubesin, M., “The Effect of an Arbitrary Temperature Variation Along a Flat Plate on the Convective Heat Transfer in an Incompressible Turbulent Boundary Layer,” NACA Technical Note 2345, 1951. [11] Seban, R. A. and Doughty, D. L., “Heat Transfer to Turbulent Boundary Layers with Variable Freestream Velocity,” Journal of Heat Transfer, 78, 217, 1956.

Page 29: ME554 Lab 8 airfoil - calpoly.edukshollen/ME554/Labs/ME554_Lab_8_airfoil.pdf · airfoil to insure turbulent flow over most of the airfoil. The area used for the definition of the

DRAFT

29

Appendix A: Replay Script (written in Tcl/Tk where comment lines start with #) 1. # Replay script for C-grid for NACA 0012 airfoil 2. # 3. # read in data file containing airfoil geometry 4. # 5. ic_geo_cre_geom_input ./naca0012_200.txt 1e-8 input PNT_AF pnt_af WALL_AF crv_af SURFS {} 6. # 7. # define parameters 8. # 9. ic_geo_new_family PNT_INT 10. set c 1.0 11. set a 0.1 12. set H 10.0 13. set N 10 14. # 15. # define points 16. # 17. ic_point {} PNT_FF pnt.00 ($a-$H)*$c,0,0 18. ic_point {} PNT_FF pnt.01 $a*$c,$H*$c,0 19. ic_point {} PNT_FF pnt.02 $a*$c,-$H*$c,0 20. ic_point {} PNT_FF pnt.03 $c,$H*$c,0 21. ic_point {} PNT_FF pnt.04 $c,-$H*$c,0 22. ic_point {} PNT_FF pnt.05 ($a+$H)*$c,$H*$c,0 23. ic_point {} PNT_FF pnt.06 ($a+$H)*$c,-$H*$c,0 24. ic_point {} PNT_FF pnt.07 ($a+$H)*$c,0,0 25. # 26. # define curves with boundary names and additional points 27. # needed for vertex associations for blocking 28. # 29. ic_geo_new_family INLET 30. ic_curve arc INLET crv.00 {pnt.01 pnt.00 pnt.02} 31. ic_geo_new_family TOP 32. ic_curve point TOP crv.01 {pnt.01 pnt.03 pnt.05} 33. ic_geo_new_family BOTTOM 34. ic_curve point BOTTOM crv.02 {pnt.02 pnt.04 pnt.06} 35. ic_geo_new_family OUTLET 36. ic_curve point OUTLET crv.03 {pnt.05 pnt.07 pnt.06} 37. ic_geo_new_family INTERIOR 38. ic_curve point INTERIOR crv.04 {pnt.01 pnt.02} 39. # 40. # define points for vertex associations for blocking 41. # 42. ic_point crv_par PNT_FF pnt.08 {crv.00 0.25} 43. ic_point crv_par PNT_FF pnt.09 {crv.00 0.75} 44. ic_point crv_par PNT_INT pnt.10 {crv_af0 0.05} 45. ic_point crv_par PNT_INT pnt.11 {crv_af1 0.05} 46. ic_point intersect PNT_INT pnt.12 {crv.04 crv_af0} tol 0.1 47. ic_point intersect PNT_INT pnt.13 {crv.04 crv_af1} tol 0.1 48. ic_point curve_end PNT_INT pnt.14 {crv_af0 xmax} 49. ic_delete_geometry curve names crv.04 0 1 50. # 51. # define surfaces with zone name 52. # 53. ic_geo_new_family FLUID 54. ic_surface bsinterp FLUID srf.00 {crv.00 crv.01 crv.02 crv.03} 55. # 56. # create blocks for C-grid 57. # 58. ic_hex_initialize_mesh 2d new_numbering new_blocking FLUID 59. ic_hex_mark_blocks unmark 60. ic_hex_mark_blocks superblock 4 61. ic_hex_mark_blocks numbers 19 21 edge_neighbors 62. ic_hex_ogrid 1 m FLUID -version 50 63. ic_hex_split_grid 13 21 pnt.03 m FLUID 64. ic_hex_split_grid 13 41 pnt.01 m FLUID 65. ic_hex_mark_blocks unmark 66. ic_hex_mark_blocks superblock 4 67. ic_hex_mark_blocks superblock 18 68. ic_hex_change_element_id VORFN 69. ic_hex_mark_blocks unmark 70. ic_hex_mark_blocks superblock 16

Page 30: ME554 Lab 8 airfoil - calpoly.edukshollen/ME554/Labs/ME554_Lab_8_airfoil.pdf · airfoil to insure turbulent flow over most of the airfoil. The area used for the definition of the

DRAFT

30

71. ic_hex_collapse_blocks 1 version 410 72. # 73. # associate each point with a block vertex 74. # 75. ic_hex_move_node 47 pnt.01 76. ic_hex_move_node 41 pnt.03 77. ic_hex_move_node 21 pnt.05 78. ic_hex_move_node 45 pnt.02 79. ic_hex_move_node 39 pnt.04 80. ic_hex_move_node 19 pnt.06 81. ic_hex_move_node 35 pnt.07 82. ic_hex_move_node 13 pnt.08 83. ic_hex_move_node 11 pnt.09 84. ic_hex_move_node 33 pnt.10 85. ic_hex_move_node 32 pnt.11 86. ic_hex_move_node 48 pnt.12 87. ic_hex_move_node 46 pnt.13 88. ic_hex_move_node 42 pnt.14 89. # 90. # associate each curve with a block edge 91. # 92. ic_hex_set_edge_projection 13 47 0 1 crv.00 93. ic_hex_set_edge_projection 11 13 0 1 crv.00 94. ic_hex_set_edge_projection 11 45 0 1 crv.00 95. ic_hex_set_edge_projection 41 21 0 1 crv.01 96. ic_hex_set_edge_projection 47 41 0 1 crv.01 97. ic_hex_set_edge_projection 39 19 0 1 crv.02 98. ic_hex_set_edge_projection 45 39 0 1 crv.02 99. ic_hex_set_edge_projection 21 35 0 1 crv.03 100. ic_hex_set_edge_projection 19 35 0 1 crv.03 101. ic_hex_set_edge_projection 33 48 0 1 crv_af0 102. ic_hex_set_edge_projection 48 42 0 1 crv_af0 103. ic_hex_set_edge_projection 32 46 0 1 crv_af1 104. ic_hex_set_edge_projection 46 42 0 1 crv_af1 105. ic_hex_create_composite {crv_af0 crv_af1} 106. ic_hex_set_edge_projection 32 33 0 1 crv_af0 107. # 108. # set parameters for mesh on block edges 109. # 110. ic_hex_set_mesh 11 13 n [expr 2*$N+1] h1 0.0 h2 0.0 r1 2 r2 2 lmax 0 uniform

copy_to_parallel unlocked 111. ic_hex_set_mesh 11 45 n [expr $N+1] h1 0.0 h2 0.0 r1 2 r2 2 lmax 0 uniform copy_to_parallel

unlocked 112. ic_hex_set_mesh 47 41 n [expr int(($c/$a-2)*2*$N+1)] h1 0.0 h2 0.0 r1 2 r2 2 lmax 0 uniform

copy_to_parallel unlocked 113. ic_hex_set_mesh 41 21 n [expr 2*$N+1] h1 [expr 0.5*$a/$N] h2 0.0 r1 1.1 r2 2 lmax 0 default

copy_to_parallel unlocked 114. ic_hex_set_mesh 11 32 n [expr 5*$N+1] h1 0.0 h2 1e-3 r1 2 r2 1.1 lmax 0 default

copy_to_parallel unlocked 115. # 116. # create mesh for blocks 117. # 118. ic_hex_create_mesh FLUID proj 2 dim_to_mesh 3 119. # 120. # set boundary conditions 121. # 122. ic_boco_set INLET {{1 VELI 0}} 123. ic_boco_set OUTLET {{1 PRESO 0}} 124. ic_boco_set TOP {{1 SYM 0}} 125. ic_boco_set BOTTOM {{1 SYM 0}} 126. ic_boco_set WALL_AF {{1 WALL 0}}