You are on page 1of 6

# The University of Edinburgh Computational Fluid Dynamics 5

2D turbulent flow past a cylinder in Star-CCM+ Overview Star-CCM+ is very much a 3D modelling package, but in order to demonstrate the ability to solve 2D flows, we can extract 2D grids. However, there is another way, which is to create a narrow 3D plane and make the two faces symmetry faces. This is what I have done in this example. I will show how to create the geometry, mesh it, and report the drag coefficient on the cylinder. The drag coefficient will also be used as the monitor to ensure that our solution has adequately converged. Firstly, decide the Reynolds number to be modelled. I have chosen 106, and I will therefore use water, with a 1m cylinder and a 1ms-1 inlet flow. The flow must take place in a domain, with the cylinder inside.

15D

5D

y x

The exact dimensions of the domain will depend on the problem being solved and need to be determined for each new situation encountered. It should be large enough that the boundaries do not affect the outcome of the simulation, in this case the force. Typically 5 and 15 times the obstacle size up and downstream is sufficient. Create a narrow rectangular box, (20,10,1) and a 1m diameter cylinder 1m long. Boolean subtract the cylinder from the box. This creates the domain. Remember that, in CFD, we work with the void containing the fluid, not the actual solids. Export the surface. Creating the geometry In Star-CCM+ start a new simulation and import the surface of the domain. Split the surface using the Regions>Body1>Boundary1>split by angle. Rename the front and back planes Symmetry1 and Symmetry2. Rename the top and bottom planes appropriately and give them all the property of symmetry. Change the inlet to velocity inlet and the outlet to pressure outlet and rename appropriately. Change the cylinder wall to cylinder and leave as a Wall.

Creating the mesh RC on Mesh1 and click Surface Remesher, Trimmer and Prism Mesher. We will want a close mesh on the cylinder, but not on the other walls of the domain. This will happen automatically, because the prisms are only applied to walls. Select appropriate sizes for the mesh. The base size will be the cylinder diameter, 1m. I set the maximum cell size to 100% (ie 1m); the number of prism layers to 5; the relative minimum surface size to 10%. All other values are default. This grows a mesh which is small close to the cylinder and increases to become sparse away from the cylinder.

Physics The flow is to be turbulent, so RC on Physics and select 3D, stationary, segregated, constant density, steady, turbulent, k-e. All other sub-models are selected automatically. Check that the fluid is water and set the Region>Inlet>Physics value to 1m/s. Creating a report coefficient and monitor Report>New Report>Force Coefficient Set the correct values in the Properties box. The software does not know the reference area. As mentioned in previous Fluid Mechanics lectures the choice of length in Reynolds number calculation is by convention. Similarly, the choice of area in calculation for the drag coefficient is convention. We will choose the frontal area, which happens to be 1x1m, in other words 1m2. The density must also be specified 997

kgm-3. Check that the direction of the force is correct (x in this example, as the flow is in the x-direction). If it was y, this would be a lift force. RC on the force coefficient you have created (you could rename it advisable if more than one) and ask for a report and monitor. When you run the simulation, a new window will appear, plotting the coefficient and a new column alongside the residuals in the output window. The simulation is complete when you are satisfied that the residuals have converged sufficiently and the force coefficient is constant. My value was CD=0.188.

Remeshing The vector map suggests there is not enough resolution in the wake. We can improve this by re-meshing that region. First a box will be created to define the region to be remeshed. Whilst in the vector scene, open Tools and RC Volume Shapes>Brick. Move the boundaries of the brick until they include the cylinder and the wake region as shown below. Now click Create and Close.

We will change the mesh refinement in the region defined by the brick. Open Continua>Mesh1>(RC)Volumetric Controls>New. In the Properties box select the shape Brick 1. This will now be highlighted in the display window. Open the new Volumetric Control 1>Mesh Conditions>Trimmer and tick Customize isotropic size in the Properties box. Under the new Mesh Values check that the Custom Size is Relative and set it to 25% of base. Now re-run the mesher. This will double the grid everywhere in the box as the mesh elements were previously 0.5m wide. The values from the larger mesh will be copied into the new mesh elements.

Now re-run the simulation. The residuals will be altered and the value of the force coefficient will change (CD = 0.178). This seems very small. We expect values of around CD = 1 for high speed laminar flow and around CD = 0.5 for turbulent flow. But Re is just beyond boundary layer transition and CD is very sensitive to the wake size. Separation may not be being properly modelled (see below).

I want to try a denser mesh, but first I tried it at u=10m/s. For a Re of 107, CD=0.344. But two things have happened. Firstly, the separation points are no longer symmetric, and secondly, the residuals do not look so good. So, Im happy that the drag coefficients are better, but Im concerned about the actual simulation. Im not taking this any further, but next time I would run an unsteady simulation and a simulation with forced symmetry, both at a higher mesh density to compare the results. WJE 21/10/08