Submitting all four homework assignments will qualify you for a free Professional Training (value of 500€) as well as a SimScale Certificate of Completion.
Homework 1 - Deadline: Date, 6th of December, 12pm
Homework Submission Form
In this exercise we will doing a full fledged flow simulation for the aerodynamics of a front wing. The focus of this simulation is to investigate the drag and lift forces on the wing and identify flow separations.
Your task is to investigate the behaviour of drag and lift and find out the stall zone for different front wing flap angles from 0 to 18 degrees considering constant inlet velocity of 20 m/s.
Let's take a look at the physics of the front wing before we start to set up our simulations:
As a first simplification we can exploit the symmetry of the front wing. Simulating only one half of the wing reduces the computational effort by defining the inner surrounding wall (brown) as a symmetry plane.
The body of the wing is a physical wall (grey), which means that it involves friction and should be defined as "non-slip walls".
The outer (not visible here) and upper surrounding walls (blue) are necessary to limit the size of the domain we want to simulate (we are not able to simulate an infinitely large domain). In reality, these walls do not exist and should not interact with the flow. A good approximation here is to assume this wall as frictionless or so-called "slip walls".
There is no relative motion between the air and the floor since the car is in motion. Thus, we will apply a wall velocity on the lower surrounding wall (cyan).
The bounding face on the right-hand side (red) will be defined as a inlet with a constant flow velocity profile.
The bounding face on the left-hand side (green) will be defined as a outlet with a constant pressure.
Different configurations which will be followed in this homework session are shown in the table below:
IMPORTANT UPDATE: For the homework 1 submission, complete the simulations for only configuration 1 and configuration 2
To start this exercise, you first have to import the geometries that will be used for all the configurations into your SimScale workbench by clicking on the link below. Please note that this can take several minutes and you will be automatically redirected to the Mesh Creator.
Click to Import the Homework Project (Crtl + Click to open in a new tab)
First we will start with Configuration 1 and follow all the steps in detail. The other configurations will follow the same procedure and therefore will not be documented in detail.
- In the Mesh Creator tab, click on the geometry FW-0deg-model
- Click New Mesh button in order to start creating a new mesh on this geometry.
- Next go to Background Mesh Box under Geometry Primitive and change the mesh box dimensions to the values shown in figure below. Click Save to save the changes. Click on reset icon over viewer to see the created mesh box in viewer.
- Go to MaterialPoint and change the values to the following shown in the figure below. The material point Click Save.
- Next go back to Geometry Primitives and click on New and then Cartesian Box to define a new Cartesian box that will be used to define mesh refinement area.
- After creating a new cartesian box, you will be directed to the definition of this cartesian box. Change the dimensions of the box to the following shown in the figure below. Click Save to register your changes after which you would be able to see the created cartesian box in the viewer.
- Follow the same procedure in order to define another cartesian box for further refinement definitions. Rename it to Cartesian Box 2. This time change the values to the following shown in the figure below. Click Save to register your changes after which you would be able to see the cartesian box in the viewer.
The best mesh requires well defined refinements. Now we will start creating the mesh refinements. For this proceed to Mesh Refinements and click New.
- The new mesh refinement will be created. Rename it to surf-wing-flap (optional). Change Type to Surface refinement and then both Level min and Level max to 7 respectively. Change Filter for entity types to faces and select FWing and flap. Click Select assignment in order to see the selected assignment highlighted in the viewer. Click Save to register your changes.
- Follow the same procedure and this time rename the newly created refinement to feature (optional). Change Feature refinement levels Distance and Level to 0.001 and 7 respectively. Then click Save.
- In order to create a separate region refinement for the inner cartesian box, create a new refinement and rename it to region-inner (optional). Change Type to Region refinement and then Feature refinement levels Level to 3. Select Cartesian Box under Assigned Geometry Primitives and click Save to register the refinements for this specific cartesian box.
- Follow the same procedure in order to define the refinement level for the other cartesian box. This time rename it to region-outer (optional). Change Type to Region refinement and select Cartesian Box 2 under Assigned Geometry Primitives and click Save to register the refinements for this specific cartesian box.
- Next we will define layers over the surfaces on the whole wing and the floor. Layers will allow us to capture the results more accurately within the areas we are interested in. Create a new refinement and rename it to Layer-wing (optional). Change Type to Inflate boundary layer and further change Expansion ratio for layer cell thickness [-] and Minimum overall layer thickness [-] to 1.8 and 0.0001 respectively. Select FWing and flap under Surfaces with layers and click Select assignment in order to review the selected surfaces in the viewer. Click Save to register your changes.
- For the floor layers, create a new refinement and rename it to Floor-layer (optional). Change Type to Boundary box layer addition. Change Bounding box face to Zmin and then the Number of layers [-] and Thickness of the final layer [-] to 3 and 0.35 respectively.
- Once you have defined all of the mesh refinements, go back to the Operation 1 and click Start in order to submit the meshing job to the server. Due to the fineness of the mesh, the meshing could take 15 to 20 minutes to finish. While the mesh is being generated, you can start setting up the meshes for other geometries following the same procedure (Follow the details below).
Setting up other configurations mesh
While the first mesh job is running, take advantage of the parallel computing and proceed to start setting up all the other configurations. You don't have to perform all the meshing operations again from scratch. Just duplicate the already created mesh by right clicking on it and then click Duplicate.
Rename the duplicated mesh to FW-XXdeg-model mesh (where XX is the flap degrees) and use the dropdown to change the Base Geometry to the model with the corresponding angle. Then click Save. Now you will have to reassign the Fwing and flap faces for surf-wing-flap and Layer-wing refinements and start the meshing operation.
- Once the meshing of the first geometry i.e. FW-0deg-model is finished, you can proceed to Simulation Designer without waiting for others to complete in order to set up the simulation in parallel.
- For Configuration 7: If you encounter meshing error, please see an important note below Goto Note
- Once you are in Simulation Designer, click New Simulation in order to start setting up the simulation. A new simulation creating window will pop up. Rename it to Flap-0deg-deflection-sim (optional) and click Create in order to create a new simulation.
- In Analysis Type, switch to Fluid dynamics and then select Incompressible. You don't have to change any properties here. Just click Save to select this analysis type.
- Next you have to select a domain on which this simulation will be performed. Proceed to Domain and select FW-0deg-model mesh and click Save. After a while you will see the loaded mesh of the selected domain in the viewer. For the easier mesh handling, it is recommended to switch to surfaces render mode from the viewer top.
- Next we have to define the fluid material. Go to Materials and click on New to create a new material.
- Click on Import from material library to import the desired material from the material database.
- Select Air and click Save to import this material directly from the library.
- Select region0 under Topological Mapping and then click Save in order to define the material for this region.
- We will now proceed to change the initial conditions. Go to k and change the Turbulent kinetic energy value [m²/s²] value to 0.24 and click Save.
- Next go to Omega and change Specific turbulence dissipation rate [1/s] to 44.7 and click Save.
Now we will proceed to the most crucial and important section of the simulation setup. We will define one by one the inlet and outlet boundary condition. We will then define the boundary condition for the sides and symmetry and next we will proceed to define the conditions for floor and wing.
Go to Boundary Conditions and click New in order to create a new boundary condition.
- Rename the newly created boundary condition to Inlet (optional). Change x value [m/s] of Velocity to 20. Select the front surface of the domain from the viewer and click on Add selection from viewer. This will add the selected surface under Topological Mapping i.e. boundingBox3 in this case. Click Save to define the inlet boundary condition.
- Follow the same procedure and rename the newly created boundary condition to Outlet (optional). Change Type to Pressure Outlet and select the back surface of the domain and click on Add selection from viewer. This will add the selected surface under Topological Mapping i.e. boundingBox4 in this case. Click Save to define the outlet boundary condition.
- Repeat the procedure and rename the newly created boundary condition to Sides (optional). Change Type to Wall and Velocity to Slip. Next select the two side surfaces of the domain and click on Add selection from viewer. This will add the selected surfaces under Topological Mapping i.e. boundingBox1 and boundingBox6 in this case. Click Save to define the boundary condition for the sides.
- Next we will define the symmetry condition. Repeat the procedure and rename the newly created boundary condition to Symmetry (optional). Change Type and select the surface along symmetry of the domain and click on Add selection from viewer. This will add the selected surface under Topological Mapping i.e. boundingBox2 in this case. Click Save to define the symmetry boundary condition.
- Create a new boundary condition and rename it to Floor (optional). Change Type to Wall and select the lower surface of the domain and click on Add selection from viewer. This will add the selected surfaces under Topological Mapping i.e. boundingBox5 in this case. Click Save to define the floor boundary condition.
- Lastly, we will define the boundary condition for the wing. Create a new boundary condition and rename it to Wing (optional). Change Type to Wall and Wall treatment to Zero gradient. Select solid_0_FWing and solid_0_flap under Topological Mapping and click Select assignment to see the selection in the viewer. Click Save to define the boundary condition for the wing.
- After defining all the boundary conditions, we will proceed to set up the numerics for our simulation. Go to Numerics and scroll down until you reach Solver. Under Solver, change [U] velocity solver to Smooth solver. Expand Details and change Smoother to symGaussSeidel and Absolute tolerance to 1e-7. Do similar changes for [k] Turbulent kinetic energy solver and [omega] Specific turbulence dissipation solver. Click Save to register your changes.
- Next we will define the our simulation interval and steps that needs to be recorded. Go to Simulation Control and change End time value [s] to 1500. Expand Details under Write control and change Write interval (simulation time steps) to 1500. Next change Number of computing cores and Maximum runtime [s] to 32 and 120000 respectively. Maximum runtime [s] is set too high just to be on a safe side. Click Save to register your changes.
- As our last step before going to prepare a simulation run, we will create some result control items in order to get a graphical data of some interesting quantities afterwards. Firstly, we will create the result control item for the forces and moments. Go to Result Control and click New next to Forces and Moments.
- A new force and moment result control item will be created. Rename it to Wing main (optional). Then change Density value [kg/m³], x value [m], z value [m] and Write interval (simulation time steps) to 1.2, -1.4, 0.47 and 10 respectively. Select solid_0_FWing under Faces for force calculation and click Save to register your changes.
- Similarly, follow the same procedure and rename the newly created force and moment result control item to Flap (optional). Change same values as defined above but this time select solid_0_flap under Faces for force calculation. Click Save to save your changes.
- Secondly, we will create the field calculation items. For this go back to Result Control and click New next to Field calculations.
- Rename the newly created field calculation item to Yplus (optional). Change Type to Turbulence and click Save to register your changes.
- Follow the same procedure and rename the newly created field calculation item to WallShearStress (optional). Change Type to Wall fluxes and click Save to register your changes.
- Once all the above steps are defined, we will proceed to create our first simulation run. Go to Simulation Runs and click on New. A window will pop up, give a reasonable name to the run e.g. Run-Flap-0deg in this case (optional) and click Create in order to create a new run.
- After the run is created, click Start to start the created run. The simulation run can take up to ~120 minutes (~2 hrs.).
Setting up other configurations mesh
IMPORTANT UPDATE: For the homework 1 submission, complete the simulations for only configuration 1 and configuration 2
While the first simulation job is running, take advantage of the parallel computing and proceed to start setting up all the other configurations. You don't have to perform all the simulation set up operations again from scratch. Just duplicate the already created simulation by right clicking on it and then click Duplicate.
Rename the duplicated simulation to FW-XXdeg-deflection-sim (where XX is the flap degrees) and assign your new domain to the duplicated simulation under Domain. Then click Save. Now you have to just assign back all the entities to the material, boundary conditions and result control force plot items and then start the simulation job.
- When your simulation is completed, proceed to Post-Processor tab in order to post-process your results.
We will show the post-processing only for the first simulation results. You can then follow the same steps in order to post-process other configuration results
- Once in Post-Processor, click on Solution fields under Run-Flap-0deg in order to load the results in viewer. Due to fine mesh it can take up to 5 minutes to load the results in to the viewer.
- For faster and efficient reviewing of the results, we will use slice filter. In order to add the filter, do the following:
- Go to Add Filter and select Slice.
- Change Origin middle value i.e. y value to 0.6.
- Change Normal to (0,1,0).
- Uncheck Show Plane.
- Click Apply to save the changes.
- Next set camera orientation to +Y from the View tool over the viewer to get a proper view.
- Next change the Field to U [point-data] in order to see the velocity field. Zoom the results with the mouse roller and drag from middle mouse button to get a reasonable view. Turn on the color bar and drag it by holding mouse left button to the bottom.
- Next we will plot the pressure coefficient. Since this field doesn't exist therefore we need to create one. First uncheck the colorbar (important; if you don't do it, you may end up with two different colorbars in the next step) then select Calculator from Add Filter.
- Once the calculator filter is added:
- Change the Result Array Name and Function to Cp and (p-6.2)/(0.5*20*20) respectively.
- Click Apply to create a pressure coefficient field.
- Change Field to Cp[point-data] to see the results.
- If you want to take a screenshot of your results, click on the camera icon under View tools. Your screenshot will appear under Result Evaluation section.
- Furthermore, in order to save the state for later use, click on Save State button. A window will pop up, give a reasonable name e.g. Saved state - 0deg (optional) in this case. Your saved state will also appear under Result Evaluation section.
- Lastly to see the plotted data requested beforehand during simulation setup, switch over to WingMain under Force plot.
- Comparing the previous contour to the one we have obtained from flap at 18 degrees and moved 1 cm up (Configuration 8), one can clearly see the stalled region at the back of the flap showing that this flap angle would be a wrong choice as it will reduce the down force effecting the overall performance.