Week 1: Channel flow simulation using CONVERGE CFD
AIM:
Channel flow simulation using CONVERGE CFD
objectives:
1. Make sure the inlet pressure and initial pressure are the same.
2. Once you have the base setup ready, run the case for three different base mesh sizes i.e You need to run 3 simulations and compare the results between all the 3 simulations. 3 different base mesh sizes are,
- dx = 2e-4m, dy = 2e-4m, dz = 2e-4m
- dx = 1.5e-4m, dy = 1.5e-4m, dz = 1.5e-4m
- dx = 1.0e-4m, dy = 1.0e-4m, dz = 1.0e-4m
Contents to be shown in the report:
1. Velocity and pressure contours for all the 3 base mesh sizes
2. Show mesh (i.e surface with edges) for the 3 base mesh sizes
3. Plots for velocity, pressure,mass flow rate and total cell count for all 3 base mesh sizes.
4. Explain the plots and write a detailed report on your project.
5. Upload an animation to youtube and attach the link here using the add media option. Explain the development of the flow using the animation.
Make sure you make your project public. Once you are done, paste the link to your project here.
theory:
Channel flow is an internal flow in which the confining walls change the hydrodynamic structure of the flow from an arbitrary state at the channel inlet to a certain state at the outlet. The simplest illustration of internal flow is a laminar flow in a circular tube (see poiseuille flow). Poiseuille flow is pressure-induced flow (channel flow) in a long duct, usually a pipe. It is distinguished from drag-induced flow such as coutte flow. Specifically, it is assumed that there is laminar flow of an incompressible newtonian fluid of viscosity `mu`induced by a constant positive pressure difference or pressure drop Δp in a pipe of length L and radius R << L. while fluid flow through the channel, the parabolic velocity profile is created. because the friction of the walls slow the fluid down. In fact, the velocity of the fluid at the wall is zero. As you move away from the wall the velocity of the fluid increases, until you reach the middle of the pipe, where it is at its max. The resulting velocity profile is parabolic.

geometry:
here i have assumed the flow is poiseuille flow and i have taken the box type channel. to run the simulatin i have used converge software.

i have created the above geometry in converge. to create the geometry, i have taken shape tool in geometry and then i have selected box tool in the shape tool. the dimensions of the box are length along x axis is 0.1m , along y axis is 0.01m and along z axis is 0.01m. the centre of the box is 0.05m from the axis.
now i have used boundary tool in the geometry. here i have named the boundaries to the box. i have named the front and back as 2D because i have i have taken the geoemtry to be 2D geometry. i am considering the 2D geometry because the channel length along z axis is infinite. so we can take any plane normal to z axis, it shows the same results at every plane. i have taken xy plane

in the above figure, sum represents the number of triangles selected at the each boundary. now use normal toggle tool. in the converge,the normals are aloways directed to outside of the box faces as a default. but here the fluid is inward flow. so eliminate them, click on transform in geometry and slect of triangle and click apply. to check whethere the geometry is correct or not(ie open edges errors, overlap errors), click on the diagnosis which is shown at the bottem left of the display and click findings. mow buid the case setup.
case setup:
application type: time beased
materials: air
click on gas simulation as the air is gaseous state and click on species to calcuate how the mass fraction of N2 and O2 are changing along the flow.

species-

simulation parameters:
run parameters-
i am running the somulation using steady state solver. full hydrodynamic simulation mode is used for simple geometries.

- steady state moniter- it moniters the primitive variables wheather they reached the steady state or not. minimum number of cycles to be executed for steady state solver is 5000. it tells that even if we give the number of cycles to run the simulation at 15000, the software stop calculating the simulation if it reached the steady state in between 5000 and 15000 cycles. moniter start delay indicates the the simulation should run from zero cycles, that is from start. simple size indicates the soft ware takes the solution for every 1000 cycles and compar the difference in changing of primitive varisbles to see whether they reached steady state or not.tolerence denotes the diference in changing of primitive variables at every 1000cycles.

simulation time parameters-

solver parameters-
pressure based solver is used here and the max. cfl number taken is 0.5



initial conditions and events:
regions and initialization-
here i have named the entire box region as volumetric region.

boundary conditions:
boundary-
- inlet- the inlet pressure i have taken is 100001 pascals.

- outlet- the outlet pressure i have taken is 100000 pascals

- top-bottem-wall -

- front 2D and back 2D-

grid control:
base grid-

output/post-processing:
post variable selection-

output-

solution:
now export all the input files in a folder. so from this we can see that converge is used to create the input files for the simulation. now insert the two application files from the converge folder to the folder where i have exported all the input files.

for the simulation i have used cygwin64 terminal. in cygwin termpinal open the folder where you have pasted all the input and application files.
now for the simulation write mpiexec.exe -n 4 converge.exe restricted and click enter. here 4 represents the number of processors used at a time.
post processing of results:

for this copy post convert application from converge folder to output folder which is generated in the input files folder. we are doing this because we are goingto convert all the output files into a vtk file which can be easily read by paraview software. toconvert the files we have to use post conver application as shown in the figure. there we can see the results that are obtained. now in cygwin open the output folder and write mpiexec.exe -n 4 post_convert.exe and click enter. now the below figure will appear

after naming the case and choosing 10, hit enter. now click yes for boundary output surface. now all the output files will appear and then write 'all' to convert all the output files. now select 'all' at cell variable selection menu. now all the files gets converted into varaview vtk files.
now open paraview. in paraview, open file and select case name .. vtm file which is present in the output files. finally we see the geometry in the paraview. now choose slice tool to select the axis along which all the primitive variables are same. as we know that, along z axis the primitive varibles are equal. so select axis and click apply.
- dx = 2e-4m, dy = 2e-4m, dz = 2e-4m
velocity contour-

by seeing the velocity contour, we cann clearly see the boundary layers formed at the walls and the velocity of the fluid goes on increases from wall to centre of the channnel.
static pressure contour-

now open the cnverge and create the plots of primitive variables.
velocity profile at x 0.05m-

velocity plot at inlet-

velocity plot at outlet-

static pressure plot at inlet-

total pressure plot at outlet-

mass flow rate at inlet plot-

mass flow rate at outlet plot-

total cell count-

animation of above simulation-
- dx = 1.5e-4m, dy = 1.5e-4m, dz = 1.5e-4m
velocity contour-

static pressure contour-

velocity profile at x 0.05m-

velocity plot at inlet-

velocity plot at outlet-

static pressure plot at inlet-

total pressure plot at outlet-

mass flow rate plot at inlet-

mass flow rate plot at outlet-

total cell count-

as we are seeing thar plots are still not converged. it means ut will take more cycles for the primitive variables to get converge
animation for above simulation-
- dx = 1.0e-4m, dy = 1.0e-4m, dz = 1.0e-4m
velocity contour-

static pressure contour-

velocity profile at x 0.05m-

velocity plot at inlet-

velocity plot at outlet-

static pressure plot at inlet-

total pressure at outlet-

mass flow rate at inlet-

mass flow rate at outlet-

total cell count-

animation for above simulation-
conclusion:
- from the pressure contour we can clearly see that the there is a pressure difference between the inlet and outlet, so that the fluid can move.
- from the velocity contour we can see that the the velocity got increased from the wall to centre of the channel.
- the velocity profiles we got are parabolic.
- by decreasing the cell size, there the simulation to0k more time to get converge.