# Session 3: Aerodynamics of an Aircraft - Part II Simulation Setup

**URL:** <https://www.simscale.com/forum/t/session-3-aerodynamics-of-an-aircraft-part-ii-simulation-setup/87653>\
**Category:** Aerospace Workshop\
**Created:** [February 11, 2020, 4:07am UTC](https://www.simscale.com/forum/t/session-3-aerodynamics-of-an-aircraft-part-ii-simulation-setup/87653 "2020-02-11T04:07:56Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Ricardopg](https://www.simscale.com/forum/user_avatar/www.simscale.com/ricardopg/32/26909_2.png) [@Ricardopg](https://www.simscale.com/forum/u/Ricardopg)\
**Post date:** [February 11, 2020, 4:07am UTC](https://www.simscale.com/forum/t/session-3-aerodynamics-of-an-aircraft-part-ii-simulation-setup/87653/1 "2020-02-11T04:07:56Z")

</div>

This post is a continuation of [Aerospace Workshop Session 3 - Part I](https://www.simscale.com/forum/t/session-3-aerodynamics-of-an-aircraft-part-i-meshing/87648). It contains the tutorial to setup the simulation for **Aerodynamics of an aircraft**.

## Simulation Setup

A total of 3 different inlet velocities will be simulated. For the sake of simplicity, this step-by-step simulation setup will focus on 0.15 Mach and can be easily adapted to other velocities.

Let’s create **Topological Entity Sets** to help us setting up **Boundary Conditions** later on. A new topological entity set is assigned as follows:

1. Left click on all faces that will constitute a topological entity set;
2. On the right-hand side panel, next to **Topological entity set** , click on the **+** icon;
3. Name your entity set as you deem suitable and click on **Create new set**.

Create an **Inlet** topological entity set as follows:

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/d/e/deb255c25f378b527bb1b28b22533efada8e0ccf.png)

Similarly, create an **Outlet** topological entity set (the face is in the opposite side from the **Inlet** face):

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/8/9/895a3436ae71e32ceaa21ff4be6239ef8d90ccda.png)

Create a **Symmetry** topological entity set as follows:

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/e/9/e99a5f87aa132879bc74f89594450eb9d91e3582.png)

Create a **Top and side** topological entity set as follows:

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/5/f/5f15c4f03a5a983b4ca6f3ec985aa582b123c52f.png)

Create a **Bottom wall** topological entity set as follows:

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/5/2/52075a3d697ae745ee14b5f200bd83ba125ef38f.png)

Create an **Aircraft - walls** topological entity set as follows:

There are ways to quickly select all surfaces from the aircraft. One of these ways is to first select all topological entity sets that have been previously created and then right click in the viewer to **Invert selection** :

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/c/4/c41f6f1cb49ba37b90472a1a86e4259279c17400.png)

Conveniently, all the aircraft walls will be selected:

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/1/c/1c9eb0f778783b138cc0be2ddb34d73645fea077.png)

### Select Fluid Material

In the simulation tree, navigate to **Materials**. In the materials library, select **Air** and hit **Apply** :

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/c/5/c5c2f7c237977826e3f9d11f87899bd807be98c1.png)

**Air** will be automatically assigned to the **BoundingVolume**. Just save and proceed to the next step.

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/d/2/d215d30a5fda284034abc8923ccf42fc7fc0e2fc.png)

### Initial conditions

The parameters in each one of the cells are initialized by **Initial conditions**. Starting from there, the solvers will try to converge to a final solution. Having good estimates for initial conditions can, therefore, enhance the convergence rate.  
**(k) Turb. kinetic energy** and **(ω) Specific dissipation rate** can be estimated from these [formulae](https://www.cfd-online.com/Wiki/Turbulence_free-stream_boundary_conditions). So, for external aerodynamics:  
k=1.5\*(I\*U)^2  
ω={ρk \over μ}\*{1 \over {μt \over μ}}

In low turbulence flows, such as those in external aerodynamics of cars and airplanes, turbulence intensity (I) is in the order of 1%. In such cases, the parameter {μt \over μ}, known as Eddy Viscosity Ratio, can be considered to be in the range of 1 to 10.

The table below shows initial condition values for k and ω assuming turbulence intensity = 1% and eddy viscosity ratio = 5:

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/9/6/965eca1e56d85008c2fca6f63403144deb88609d.png)

Please input these initial values in the corresponding fields:

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/8/1/8162dd79068510134711262a52362c547ba3638b.png)

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/c/6/c60cfab311b3ab8152d7935d1aa55a987e8d6113.png)

### Boundary conditions

As a reminder from the first part of Session 3, here is the summary of the boundary conditions for the different setups:

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/3/6/367c9d3a39fa38b5ab7cb3a79b8cd19cbf117f65.png)

The **Boundary Conditions** define the flow variables at the boundary surfaces. To add a boundary condition, click on the **+** icon and choose the appropriate type.

Boundary condition for the **Inlet** topological entity set: please create a **Custom** boundary condition and set it up as shown:

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/3/6/36ce91892a10110b64162714d2bbff6f33dc2e02.png)

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/3/9/39d7bed480ece4a7286d7b9fe3eec36b5e2e7425.png)

Boundary condition for the **Outlet** topological entity set:

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/2/5/254e6e13cb8a39c01e71cda1fc1103c952090601.png)

Boundary condition for the **Symmetry** topological entity set:

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/1/7/17acdfd237f3440066328cb585c5f133d60508bc.png)

Boundary condition for the **Top and side** topological entity set:

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/b/2/b2e32f79435052d81e7608af3f0cebf619e8be15.png)

Boundary condition for the **Bottom wall** topological entity set:

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/3/f/3f84e3ebc7bfa55ffd6912c6954c11c64fab1072.png)

Boundary condition for the **Aircraft - walls** topological entity set: it will be a **Wall** boundary condition with a **No-slip** condition for velocity and **Zero gradient** for **Temperature** :

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/f/7/f7046f1c8f4d00cdc8efa81036dfb887a0e7d69e.png)

### Numerics

Select **Numerics** from the simulation tree and enter the following inputs. This enhances the solver to get the appropriate results.

- Set the relaxation factors to:

**p: 0.2**  
**U: 0.5**  
**Density field: 0.05**  
**Enthalpy equation (h): 0.5**  
**k: 0.5**  
**Omega: 0.5**  
**Number of non-orthogonal correctors: 2**

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/b/a/ba7a6a6a1e1d77620796ceac817bce938651ecb0.png)

In **Residuals control** , set all values to 1e-7. When and if this criteria has been met, SimScale automatically stops the simulation. Otherwise it will run until the specified number of iterations has been achieved.

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/2/f/2f2b652f9205db82807e40f8f6c2e23c9d6638a0.png)

Change the pressure solver to **GAMG** with absolute and relative tolerances to **1e-8** and **0.005** respectively.

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/3/8/389fa4b9d469346d005e2bb5f9b56e7941a3059e.png)

All other solvers should be changed to **Smooth solver** with absolute tolerance **0.0000001** and relative tolerance **0.001**.

Set the following **Divergence** schemes to **Bounded Gauss Upwind** :

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/d/6/d6a99cd2b879e497eb70f6d800b95237ca689bb6.png)

Now, in **Simulation control** change **End time** and **Write interval** to **1800**. Raise **Maximum runtime** to **40000** seconds. The number of processors is automatically determined by SimScale to optimize core hours usage.

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/0/9/09be566ab01660246ac6a3c33d410a5d271421e3.png)

We can now proceed to creating a **Simulation Run**.

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/3/2/32a8fbd06e7368411d92bf398c40874f9186bf44.png)

Create new simulations for Mach 0.25 and 0.35 by duplicating the first compressible setup.

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/c/3/c3a386cbeb6f63f4361ea8e955140096d153e63d.png)

Configuring the 0.25 Mach simulation is straight forward. It only requires you to update velocity inlet, k and omega.  
For 0.35 Mach, velocity will be ramped to avoid divergence early on in the simulation. To set up a ramped velocity, do as follows:

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/e/7/e768a2d1a62fcea62e5397f5c345ef1f8be3ea74.png)

At t = 0 iterations, a velocity of -15 m/s (in **Z** ) will be applied to the **Inlet**. When the number of iterations reaches 900, the velocity in the **Z** direction is updated to -116 m/s.

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/a/4/a45d441391a6032685e856ba6510e349dbf7b580.png)

For the **Aircraft close to the ground** , the set up follows the same logic as the one we just did:

1. Go to **Topological entity sets** and create similar sets for inlet, outlet, symmetry, top-side, bottom and aircraft walls for the new mesh.
2. Assign the **Material** air to the new region.
3. Assign the **Initial conditions** to the domain and **Boundary conditions** to the new topological entity sets created.
4. Duplicate the simulation for new cases using Mach 0.25 and Mach 0.35.

## Post-processing

Once the simulation finishes running, click on it and head over to the post-processing environment by clicking on **Post-process results**

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/f/9/f9fcb0c3b848526e170e719e32f6654b599d2ce1.png)

In the post-processing panel, you can find a list of filters and functions. Please click on **Cutting Planes** to create a slice.

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/d/b/db9d8cf20c33c64c997c2b4c4f259b110b117d2c.png)

In order to visualize the airplane, the placement of our cutting plane has to be adjusted. This can be done either by the adjusting the sliding bar next to **Point** or by entering the coordinates **0.0011 0 0** after clicking on the three dots next to the sliding bar.

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/d/e/de2cfcd204874fe2310299caee342540a06e8f63.png)

Click on the scale and adjust the settings to make it represent the data set better:

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/4/9/493b68fa94a98a3ec1eb26c7c382f52498606b32.png)

To show density, click on **Cutting Plane 1** and change **Scalar** to **Density [Node]**. Adjust the scale to the range of **1.2** to **1.31** :

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/3/5/355c42c145a7285c800e02fdd5d5e4e612e69802.png)

Now let’s check the pressure contours on the airplane’s surface. To do this, first delete the previously created cutting plane. Right click in the viewer and select **Show all parts**.

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/7/2/729ed7d835acb9533808c23292bdf1c4ba758585.png)  
 ![image](https://www.simscale.com/forum/uploads/default/original/3X/4/e/4ec22e94b045b9a664180b12b26551fd379f61e4.png)

After hiding the flow region, only the boundaries will be shown. Go ahead and hide the Bounding Volume Faces **0** , **1** , **2** and **3**. Then Click on **Results** and select **Pressure [Node]**:

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/7/2/72f13ef24be46e38ad02a014f2dc0e31539d9c96.png)

Please adjust the scale’s range from 100000 to 102920 Pa.

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/6/f/6f3e0732152268c243531eb7704c666cc72e4d33.png)

Let’s add **Particle traces** in order to get the flow streamlines. In the following pictures, the **BoundingVolume** is still hidden and only the **BoundingVolumeFace4** aswell as the aircraft surfaces are being displayed.

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/9/c/9c9e515eaf306057ca19fe9b0930ac68b992f10c.png)

Add a **Particle traces** and adjust **Compute vector** and **Map scalar** to **Velocity [node]** and **All Velocity [node]** respectively. Then click on the **Transparent surface** icon towards the top of the screen to give a nice effect to the walls.

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/a/b/ab65832127b0bfc96c85f744a9b888c97122e0e1.png)

Now, to create a new particle trace, click on **SEEDS** , then on **PICK** and select a surface from which the traces will be generated (you can use the bounding volume face to do that). The **Radius** of streamlines can be adjusted under **SETTINGS**. The number of streamlines aswell as the spacing between them can be adjusted in **SEEDS**.

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/c/5/c5da0f785ee87927d73c9c4b0c469abfc610ae9b.png)

 ![image](https://www.simscale.com/forum/uploads/default/original/3X/4/2/42f8c6f42b528d8d3a7e4fd9efa34ffa7bf4bace.png)

A lot of different particle traces configurations are possible, so we encourage you to play with the settings and get other cool pictures.

Now, for the other simulation runs, perform similar post-processing and compare!

---

<div class="post-metadata">

**Author:** ![jousefm](https://www.simscale.com/forum/user_avatar/www.simscale.com/jousefm/32/34908_2.png) [@jousefm](https://www.simscale.com/forum/u/jousefm)\
**Post date:** [March 20, 2020, 7:01pm UTC](https://www.simscale.com/forum/t/session-3-aerodynamics-of-an-aircraft-part-ii-simulation-setup/87653/2 "2020-03-20T19:01:05Z")

</div>

Listed on March 20, 2020, 7:01pm UTC


