Intro To Fluent Tutorial Tutiafflen24
Intro To Fluent Tutorial Tutiafflen24
Intro To Fluent Tutorial Tutiafflen24
Mitchell Boots
University of Newcastle
Ansys Fluent is a comprehensive computational fluid dynamics (CFD) software that allows you to model
fluid domains.
In this set of tutorials, we will introduce basic functionalities of Ansys Fluent through the Ansys
Workbench interface. Ansys Workbench is the integration and workflow platform that connects Ansys
products.
This tutorial will cover the very basics on how to create or import geometry, create a basic mesh, apply
boundary conditions, and perform solutions setup and post analysis of your first CFD simulation.
This tutorial is #1 of a seven-part tutorial series that serves as an introduction to Ansys Fluent. Details
of the topics covered and the order can be found in the table below. These tutorials build on one
another, so it is recommended that they are followed in order. Other tutorials can be found on the
Ansys Education Resources site.
*This tutorial was created using the 2023R1 Student Version of Ansys Workbench. Some screens may
look different, depending on your version. Check the Ansys Learning Forum if you have any questions.
Table of Contents
To complete a fluid flow (fluent) solve, you will need to provide the following:
1. Geometry - Either created using Ansys Discovery or imported from a CAD program.
2. Mesh - A mesh defining the fluid domain into a finite number of cells.
3. Setup - Defining the boundary conditions, Solution methods and report functions.
4. Results - Post solution analysis, Contours, Streamlines, vectors and much more
Once that has been done, we will open the geometry interface. There are a few different modeling
options we can use:
• Ansys SpaceClaim1 is a non-parametric modeling program, which can be used to construct new
or alter externally constructed models. Being a non-parametric program makes it quick and easy to
adjust complex geometry.
• Ansys Discovery is a non-parametric modeling program that Ansys has developed, very similar
to SpaceClaim but integrated solving.
For this course we will be using SpaceClaim. Right click on the geometry tab and select “New Geometry
in SpaceClaim” and wait for the Interface to load.
By default, when you begin sketching, it will be on the XZ plane. However, for a 2D geometry, we need
to create a surface on the XY plane to ensure Ansys recognizes it as 2D in Fluent. To achieve this, follow
these steps:
1. Select “End Sketch Editing” in the “Sketch” tab to complete the current sketch.
2. Now, choose the “Sketch Mode” and select the XY plane, as illustrated in the figure below.
This will allow you to create a 2D surface that Ansys will recognize for further analysis in Fluent.
1 After the 2023R1 release, Ansys SpaceClaim became a legacy product and Ansys Discovery (a simulation-driven design
tool that combines instant physics simulation, high fidelity simulation and interactive geometry modeling in a single easy-
to-use experience) became the primary built-in Geometry tool. If you want to learn more about specifically modeling in
Ansys Discovery, check out this Ansys Innovation Course “Learn Solid Modeling with Ansys Discovery”.
Now, we may begin sketching. First, select the “Rectangle” icon located in the sketch tab. Draw a
rectangle on the XY plane with the dimensions of 100x1000mm, as shown below. To ensure precise
measurements, you can utilize the “Dimension” tool in the sketch tab to add appropriate dimensions
to this sketch.
Once you are satisfied with your sketch, press “End Sketch” in the sketch tab. You will notice that in
your model tree, a surface is created, and the sketch will appear green, indicating its completion.
We will begin by generating the default mesh. To do this, select “Generate” in the home tab. Once you
do so, you will be presented with the following coarse mesh.
Now, we want to refine the mesh to achieve a more accurate simulation. For this session, we will use
a basic meshing approach. In your model tree, click on “Mesh,” and you will notice a series of options
appear at the bottom of the model tree. Proceed to “Defaults” and change the “Element Size” to 5mm.
After making this change, hit “Generate” again. You should now see the following mesh, which is more
refined and will provide improved accuracy for your simulation.
Now, we will improve the boundary conditions of the pipe. To do this, we will first apply “face meshing,”
which will allow us to keep the face mesh as quadrilateral cells. To do this, right-click on “Mesh” ->
“Insert” -> “Face Meshing.” Scope the geometry to the face of the pipe, as shown in the image below.
To select an edge, you will need to use the edge selection tool. You can find this option in the top bar
above the geometry. The image below illustrates where you can locate this option. Once you select an
edge, it will be highlighted in green. Now, you can add this selection to the “Geometry” section seen at
the bottom left of the screen under “Scope” -> “Geometry”. This process allows you to define specific
regions in your mesh for further boundary condition assignments in Fluent.
Once you have defined the edge, you must rename the “selection” to “Inlet.” This action will inform
Ansys that we intend to designate it as an inlet in the boundary conditions when setting up the solution.
After defining the inlet, you need to repeat the same process for the outlet and the walls of the domain.
The following image illustrates how all three named selections (“Inlet,” “Outlet,” and “Walls”) should
look like:
Now that you have completed the meshing process and defined
your named selections, you can close the “Mesh” interface.
However, before proceeding to the “Setup” stage, it is essential to
“Update” the mesh. To do this, right-click on the “Mesh” tab and
select “Update.” This step ensures that any changes made to the
mesh are applied and up-to-date for the subsequent setup and
analysis in Fluent.
Once the Workbench has finished updating, you will notice a green tick displayed over the “Mesh” tab.
Now, you can proceed to open the “Setup” tab. Upon selecting this tab, you will be presented with the
following interface, where you need to specify a few options before continuing with the solution setup.
The first step is to enable “Double Precision,” as this setting will help reduce computational time and
enhance accuracy. The other necessary setting is to define the number of logical processors. As Ansys
limits the licenses to 4 processors, you should enter “4” in this field.
After making these changes, click on “Start” to initiate the setup process. This will configure the
necessary parameters for your simulation, preparing it for the solution stage in Fluent.
Once you enter the solution interface, you will notice a series of options listed down the left side. We
will gradually progress through this list, though some options may be skipped for now. I encourage you
to explore this interface to become familiar with its capabilities.
The first step is to define the type of CFD analysis you will be conducting. For today’s lab, we will
perform a steady-state pipe flow analysis. By default, the steady-state option should be selected, but
it is essential to ensure that the steady-state option is ticked.
Next, you need to define the effect of gravity in your analysis. To do this, tick the “Gravity” option and
since the pipe runs along the X-axis, we will define the gravity in the Y-axis. Enter the value “-9.81”
in the corresponding text box to represent the acceleration due to gravity in the Y-direction. This will
account for the gravity effects in your steady-state pipe flow simulation.
The next thing we need to define is the type of equations that will govern this simulation. We will go
into detail later on how to select and what to select for the type of simulation you want to achieve. But
for now, we will be using the “SST K Omega” option. Navigate to the “Models” tab, select “Viscous,”
and tick the “SST K Omega” option. Press “OK.” This should be set by default, but if not ensure this is
set correctly.
To add water, click on “Fluent Database,” and scroll down the list until you find water. Select water and
press “Copy.” You will notice that water now appears under the “Fluid” option in the tree. You may now
close the materials tab.
Following this, we need to define our boundary conditions, including the inlet, outlet, and walls. If
the named selections from the “Mesh” tab were defined correctly, the boundary conditions tab will
automatically set the inlet as “Velocity Inlet,” the outlet as “Pressure Outlet,” and the walls as “No Slip”
wall conditions.
To proceed, open the “Inlet” tab and define the fluid speed as 1m/s. Press “Apply” and close the
window to confirm the specified boundary conditions.
Move over to the “Run Calculations” tab. The solution will iterate until the number of iterations has
been reached or the solution has converged. We will discuss how to change the convergence criteria
in later weeks, but for now, we will leave it as is. For today’s simulation, the only thing you need to do
before running the simulation is to specify the number of iterations you would like to simulate. Set
“Number of Iterations” to 100 and press “Calculate.” This will initiate the simulation and perform 100
iterations.
Now, before we move over to the ‘Results’ tab, we will look at the velocity and pressure contours to
see if they make sense. The only difference between analyzing the results here and in Post CFD is that
we get a few more options to review and edit our results, create movies, etc.
To create a contour of the domain, you must go to ‘Results’ -> click on ‘Contours,’ and you will be
shown the following interface.
To create a contour, make sure “Filled,” “Node Values,” and “Auto Range” are the only boxes ticked. The
first contour we will check is the static pressure. Create a contour of “Pressure” -> “Static Pressure.”
Click “Save/Display,” and this will show you a contour of static pressure throughout the pipe, as seen in
the image below. You can modify the range it displays as well as whether the contour shows as banded
or smooth. Feel free to explore the options and customize the visualization to your preferences.
After generating the velocity magnitude and static pressure contours, compare these values to the
ones you have simulated to check if they make sense and align with your expectations.
Once you are satisfied with the contours and have compared them with the results obtained above,
you can proceed to the “Results” tab. When you open this tab, you will be presented with the following
user interface (UI). In this interface, you will have access to additional options to review, analyze, and
manipulate your simulation results, including creating animations and exploring various visualization
tools.
To create a contour in “Post CFD,” click the button that is boxed in the above image. You will be prompted
to name the contour, and then you will be presented with options at the bottom left corner, as shown
below. These options allow you to customize the contour visualization and explore the results in more
detail.
Again, like before, we will create a pressure contour. Change “Variable” to pressure and click apply.
We can further refine the contour by increasing the number of contour bands. This can be changed by
modifying “# of Contours.”
Create a contour for both pressure and velocity and compare the results below. This comparison will
help verify the consistency and accuracy of the simulation results.
You can save the contours as an image by going to “File” -> “Save Picture.” This will present you with
the following options:
You can specify the file save location with the file icon, and once done, just press “Save.”
Congratulations on completing your first CFD simulations! Now, you can explore further by trying to
improve the mesh and see how it affects the results you have obtained. Mesh refinement can have
a significant impact on the accuracy and reliability of the simulation, so experimenting with different
mesh settings and resolutions can help you achieve more accurate and detailed results in your future
CFD simulation.
Document Information
This case study is part of a set of teaching resources to help introduce students to topics
focused on structures and structural simulations.
Feedback
If you notice any errors in this resource or need to get in contact with the authors,
please email us at [email protected].
ANSYS, Inc. If you’ve ever seen a rocket launch, flown on an airplane, driven a car, used a computer, touched a
Southepointe mobile device, crossed a bridge or put on wearable technology, chances are you’ve used a product
2600 Ansys Drive where Ansys software played a critical role in its creation. Ansys is the global leader in engineering
simulation. We help the world’s most innovative companies deliver radically better products to
Canonsburg, PA 15317
their customers. By offering the best and broadest portfolio of engineering simulation software,
U.S.A. we help them solve the most complex design challenges and engineer products limited only by
724.746.3304 imagination.
[email protected]
visit www.ansys.com for more information
Any and all ANSYS, Inc. brand, product, service and feature names, logos and slogans are
registered trademarks or trademarks of ANSYS, Inc. or its subsidiaries in the United States or other
countries. All other brand, product, service and feature names or trademarks are the property of
their respective owners.