Vous êtes sur la page 1sur 22

Workshop 10 Vortex Shedding

14.5 Release

Introduction to ANSYS CFX


2012 ANSYS, Inc. December 17, 2012 1 Release 14.5

Introduction
Workshop Description:
Set up a transient simulation of vortex shedding behind a cylinder (Krmn vortex street) and compare the predicted Strouhal number with experimental data. The cylinder has a diameter of 2m.

Learning Aims:
This workshop introduces several new skills: Preparing a simulation for transient analysis Learning how to post-process a transient simulation, including performing a FFT

Introduction
2012 ANSYS, Inc.

Setup
December 17, 2012

Solution
2

Results

Summary
Release 14.5

Reynolds Number Effects


Re < 5
Creeping flow (no separation)

5-15 < Re < 40

A pair of stable vortices in the wake

40 < Re < 150

Laminar vortex street

150 < Re < 3105

Laminar boundary layer up to the separation point and turbulent wake Boundary layer transition to turbulent Turbulent vortex street but the separation is narrower than the laminar case
Results Summary
Release 14.5

3105 < Re < 3.5106 Re > 3.5106


Introduction
2012 ANSYS, Inc.

Setup
December 17, 2012

Solution
3

Mesh Import
1. Launch Workbench
2. Drag and drop a CFX component system in
the project page

3. Start CFX-Pre by double clicking Setup 4. Right-click on Mesh > Import Mesh > ICEM
CFD

5. Set the Mesh Units to m


For some mesh formats it is important to
know the units used to generate the mesh

6. Import the mesh F10_S10_B15_Hex010.cfx5


(workshop_input_files\WS_10_Vortex Shedding)
Introduction
2012 ANSYS, Inc.

Setup
December 17, 2012

Solution
4

Results

Summary
Release 14.5

Define Simulation Type


The first step is to change the Analysis Type to Transient: 1. Edit the Analysis Type object in the Outline tree 2. Set the Analysis Type option to Transient

3. Set the Total Time to 20 [s]


4. Set the Timesteps to 0.01 [s] and click OK
The simulation will have 2000 timesteps

Introduction
2012 ANSYS, Inc.

Setup
December 17, 2012

Solution
5

Results

Summary
Release 14.5

Define Expressiond and New Material


1. Create the expressions shown to the right. They will be used to define the inlet velocity and the density and viscosity of the fluid.
2. Right-click on Materials and select Insert > Material 3. Name = MyFluid 4. Insert CEL expressions for Density and Dynamic Viscosity
The expression, FluidViscosity, is designed to produce a target Reynolds number of 100

5. Click OK
Introduction
2012 ANSYS, Inc.

Setup
December 17, 2012

Solution
6

Results

Summary
Release 14.5

Edit Default Domain


1. Edit Default Domain from the Outline tree

2. On Basic Settings select MyFluid for the


Material

3. On the Fluid Models tab set the Heat Transfer


option to None

4. Set the Turbulence option to None (Laminar) 5. Click OK

Introduction
2012 ANSYS, Inc.

Setup
December 17, 2012

Solution
7

Results

Summary
Release 14.5

Create Boundary Conditions (Walls)


Start by creating the Walls boundary conditions: 1. Insert a new boundary named Cylinder

Set the Boundary Type to Wall and the Location to CYLINDER On the Boundary Details tab set Option = No Slip Wall

2. Insert a new boundary named RightWall


Set the Boundary Type to Wall and the Location to RIGHT On the Boundary Details tab set Option = Free Slip Wall

3. Insert a new boundary named LeftWall


Set the Boundary Type to Wall and the Location to LEFT On the Boundary Details tab set Option = Free Slip Wall

Introduction
2012 ANSYS, Inc.

Setup
December 17, 2012

Solution
8

Results

Summary
Release 14.5

Create Boundary Conditions (Outlet & Sym)


1. Insert a new boundary named Inlet

Set the Boundary Type to Inlet and the Location to IN On the Boundary Details tab set Normal Speed = FlowVelocity

2. Insert a new boundary named Outlet


Set the Boundary Type to Outlet and the Location to OUT On the Boundary Details tab set Average Static Pressure > Relative Pressure = 0 [Pa]

3. Insert a new boundary named Sym1

Set the Boundary Type to Symmetry and the Location to SYM1

4. Insert a new boundary named Sym2

Set the Boundary Type to Symmetry and the Location to SYM2

Introduction
2012 ANSYS, Inc.

Setup
December 17, 2012

Solution
9

Results

Summary
Release 14.5

Create Initial Conditions


1. Create Expressions for the initial flow angle, U and V
velocities, as shown at the bottom of the slide The initial velocity field is asymmetric in order to accelerate
the generation of vortices and reduce the computational time

2. Insert Global Initialization


3. Under Cartesian Velocity Components insert the
Expressions for U and V velocities

4. Set the Relative Pressure to 0 Pa

5. Click OK

Introduction
2012 ANSYS, Inc.

Setup
December 17, 2012

Solution
10

Results

Summary
Release 14.5

Solver Control
1. Under Solver Control > Basic Settings set the following parameters:

Min. Coeff. Loops = 1 Max. Coeff. Loops = 5 Residual Type = MAX Residual Target = 1E-3 These parameters together with the Timestep are the key numerical inputs for a transient calculations

Introduction
2012 ANSYS, Inc.

Setup
December 17, 2012

Solution
11

Results

Summary
Release 14.5

Output Control
1. Under Output Control > Trn Results perform the following steps:

Insert new Transient Results Option = Selected Variables Output Variable List = Pressure, Velocity, Velocity u, Velocity v, Velocity w Timestep Interval = 5

2. Define the following CEL expressions for the drag and lift

Introduction
2012 ANSYS, Inc.

Setup
December 17, 2012

Solution
12

Results

Summary
Release 14.5

Output Control
1. Under Output Control> Monitor define the following Monitor Points: X [m] Y [m] Z [m] Variable/CEL Name

CdCylinder
ClCylinder HighPpt LowPpt Monitor Point 1 Monitor Point 2 Monitor Point 3 Monitor Point 4 Monitor Point 5 Monitor Point 6 Monitor Point 7
Introduction
2012 ANSYS, Inc.

-1 1 -2 2 3 4 6 8 28
Setup
December 17, 2012

0 0 2 2 2 2 2 2 2

0.25 0.25 0.25 0.25 0.25 0.25 0.25 0.25 0.25


Solution
13

CdCylinderExpression
ClCylinderExpression Pressure Pressure Velocity Velocity Velocity Velocity Velocity Velocity Velocity
Results Summary
Release 14.5

Run Solver
1. Save the project as Vortex.wbpj
2. In the Project Schematic Edit the Solution cell to start the CFX-Solver Manager 3. Start the run from the CFX-Solver Manager

You can monitor the velocity of water in the domain and the coefficients of lift and drag
during the simulation on the User Points tab The simulation will take about 15 min to complete. Therefore results files have been provided with this workshop

4. After a few timesteps stop your run 5. Select File > Monitor Finished Run in the CFX-Solver Manager

6. Browse to the results file provided with the workshop

View the mass and momentum residuals and the User Points. Right-click in the User Points window and select Monitor Properties. On the Range Settings tab check the box by Set Manual Scale (Linear). Set the Lower Bound to -10 and the Upper Bound to 30. The transient behaviour of the flow can then be clearly seen.

Introduction
2012 ANSYS, Inc.

Setup
December 17, 2012

Solution
14

Results

Summary
Release 14.5

Post-Process Results

1. Using Windows Explorer, locate the results file supplied, CFX_001.res, and drag it into an empty region of the Project Schematic 2. A new CFX Solution and Results cell will appear. Double-click on the Results cell to open the file in CFD-Post.

Introduction
2012 ANSYS, Inc.

Setup
December 17, 2012

Solution
15

Results

Summary
Release 14.5

Post-Process Results

Insert > Contour


Name = myVelocity Location = Sym1 Variable = Velocity Range = User Specified Min = 0 [m s^-1] Max = 26 [m s^-1] # of Contours = 27

Introduction
2012 ANSYS, Inc.

Setup
December 17, 2012

Solution
16

Results

Summary
Release 14.5

Post-Process Results
1. 2. 3. 4. 5. 6. Use the Timestep Selector simulation to load results from different points in the

With the first Timestep loaded, open the Animation tool Select the Quick Animation toggle and select Timesteps as the object to animate Turn off the Repeat Forever button Enable the Save Movie toggle and choose the folder where the video will be saved Click the Play icon to animate the results and to generate the video file

Introduction
2012 ANSYS, Inc.

Setup
December 17, 2012

Solution
17

Results

Summary
Release 14.5

Post-Process Results
Behind the cylinder transient vortices are
formed

The appearance of these vortices have a


certain frequency that depends on the Reynolds number

The Strouhal number is a dimensionless


number used as a measure of the predominant frequency. For flow past a cylinder the value tends to be about 0.2 over a wide range of Reynolds number

The Strouhal number is defined as a function


of the frequency, diameter and velocity

The frequency will be calculated through a


FFT of the monitoring points

f D St U

Introduction
2012 ANSYS, Inc.

Setup
December 17, 2012

Solution
18

Results

Summary
Release 14.5

Post-Process Results
1. 2. 3. Go back to Workbench In the Vortex component system, right-click on the Solution cell and choose Display Monitors In the CFX-Solver Manager go to Workspace > Workspace Properties > Global Plot Settings. Set Plot Data By = Time Step On the User Points tab right-click in the window and select Monitor Properties > Range Settings > Plot Data By = Simulation Time and press Apply. Then click on the Plot Lines tab and expand the USER POINT object in the tree. Switch off all but Monitor Point 2; only these data are needed. Click OK. On the User Points tab right-click in the window and select Export Plot Data. You then have the option to save a csv file. The file requires editing so that it contains only Time and Monitor Point 2 columns. This has already been done in Monitor Point 2.csv, which is provided.
Introduction
2012 ANSYS, Inc.

4.

5.

6.

Setup
December 17, 2012

Solution
19

Results

Summary
Release 14.5

Post-Process Results
1. 2. Close the CFX-Solver Manager and return to CFD-Post Insert > Chart Name = myFFT General tab
Type = General XY- Transient Fast Fourier Transform = on Substract mean = on Range input Data Min = 10 and Max = 20

Data Series
Data Source > File = Monitor Point 2.csv

X Axis tab
Min = 1 and Max = 5

3. 4.

Y Axis tab Y Function = Magnitude Apply


Export chart and save it as a .csv file Open the .csv File and locate the frequency that gives the highest Magnitude

5.

Use this frequency together with the diameter (2 m) and velocity (20 m s-1) to calculate the Strouhal number
2012 ANSYS, Inc. December 17, 2012 20 Release 14.5

Post-Process Results
For this grid the Strouhal number is calculated to be about 0.151 compared with an
experimental value of 0.164.

The CFD calculations can be repeated for several finer grids in order to study the
discretisation error. Finer meshes are provided in the directory GRIDS.

As the grids are refined the Strouhal number will asymptotically approach a gridindependent value Strouhal number Grid 1 Grid 2 Grid 3 Grid 4 Experiment
Introduction
2012 ANSYS, Inc.

0.151 0.1657 0.1686

0.1690
0.164
Results Summary
Release 14.5

Setup
December 17, 2012

Solving
21

Summary
A transient simulation was performed for studying the laminar vortex shedding behind a cylinder.

The computed Strouhal number was compared with the experimental value.

Introduction
2012 ANSYS, Inc.

Setup
December 17, 2012

Solving
22

Results

Summary
Release 14.5

Vous aimerez peut-être aussi