# LES of turbulent channel flows

 Register Blogs Members List Search Today's Posts Mark Forums Read

July 18, 2016, 00:23
#121
Senior Member

Mostafa Mahmoudi
Join Date: Jan 2012
Posts: 322
Rep Power: 15
Quote:
 Originally Posted by Elham Hi every body, I am simulating turbulent flow inside a channel. The channel size is 60*10*10(mm) and number of mesh are 300*80*80. I want to produce fully turbulent flow by means of mapping method. I produced a relatively good result with RAS. When I map data to LES the results get worse and not turbulent at all. And it takes so long time to proceed, eg. a full week just to proceed 0.2 sec. I will appreciate if anyone can give me a clue. Regards, Elham
Hi Elham,

I think the reason you cannot see the turbulent regime in your solution is that you just solve it for 0.2 s!

- what is the range of the Courant number and time step during the solution process?

- which LES subgrid model did you used?

Mostafa

 July 18, 2016, 00:35 #122 Senior Member     Mostafa Mahmoudi Join Date: Jan 2012 Posts: 322 Rep Power: 15 Hi guys, I'm really struggling with the mapped boundary condition in OF. I'm using it to reach a fully developed turbulent flow inside a channel with square cross-section and also using LES to model it. from the beginning I used the Smagorinsky model. During the first 50s of the solution process everything sounds normal. the velocity field shows it reached to its fully developed state. but when I let it solve to 100 s, the secondary flows got disappeared. they were dissipated! and I don't know what leads to this solution? Is it due to the boundary conditions or it is natural (though, I don't think so). Best regards, Mostafa

July 18, 2016, 01:28
RAS better than LES
#123
Senior Member

Elham
Join Date: Oct 2009
Posts: 184
Rep Power: 16
Quote:
 Originally Posted by adambarfi Hi Elham, I think the reason you cannot see the turbulent regime in your solution is that you just solve it for 0.2 s! - what is the range of the Courant number and time step during the solution process? - which LES subgrid model did you used? Mostafa

The max courant number is 0.4 and maxAlphaCo is 0.35. The time step is around 10e-6.
I use homogeneousDynSmagorinsky for LES modeling.
It takes a week just for 0.2 sec so I suppose there is something wrong with my case.

Cheers,

Elham

July 18, 2016, 04:14
#124
Senior Member

Timofey Mukha
Join Date: Mar 2012
Location: Stockholm, Sweden
Posts: 119
Rep Power: 14
Quote:
 Originally Posted by Elham Hi every body, I am simulating turbulent flow inside a channel. The channel size is 60*10*10(mm) and number of mesh are 300*80*80. I want to produce fully turbulent flow by means of mapping method. I produced a relatively good result with RAS. When I map data to LES the results get worse and not turbulent at all. And it takes so long time to proceed, eg. a full week just to proceed 0.2 sec. I will appreciate if anyone can give me a clue. Regards, Elham
Hello!
The depth of your domain looks a bit small, but that is probably no the main reason for things going bad.
I suppose you have a good reason for not using cyclic b.c.s?
What do you mean by "mapping method", do you recycle a velocity profile from downstream of the channel?
You may need to take more special care of the initial conditions, i.e introduce meaningfull perturbations. Use the perturbU utility, it works just fine.

Also, not to get dissipation that kills turbulence, use second order schemes for everything. For SGS modelling, pick up a dynamic model, or simply no model at all -- that works quite fine for me. If you use Smagorinsky or oneEqEddy, van Driest damping is a must.

Regaring performance, it is hard to say anything, it all depends on how many cores you use given your meshsize, which is around 2 million.
For such a mesh it would take one to three days to get a result using something like 64 cores. This is *very* approximate, since it all depends on how much time you want to sample your statistics. And this depends on what order statistics you want etc etc . The solver setting also play a role, e.g. the numre of inner/outer corrector loops.

Hope this helps!

Best,
Timofey

July 18, 2016, 04:22
#125
Senior Member

Timofey Mukha
Join Date: Mar 2012
Location: Stockholm, Sweden
Posts: 119
Rep Power: 14
Quote:
 Originally Posted by adambarfi Hi guys, I'm really struggling with the mapped boundary condition in OF. I'm using it to reach a fully developed turbulent flow inside a channel with square cross-section and also using LES to model it. from the beginning I used the Smagorinsky model. During the first 50s of the solution process everything sounds normal. the velocity field shows it reached to its fully developed state. but when I let it solve to 100 s, the secondary flows got disappeared. they were dissipated! and I don't know what leads to this solution? Is it due to the boundary conditions or it is natural (though, I don't think so). Best regards, Mostafa
Hi!

Ditch Smagorinsky, it is very dissiaptive. You can start with no SGS model a t all, to make sure you don't get dissipation from that. Once things work, you can test different models, but don't count on a lot of improvement.
Make sure you use second order discretization.

Best,
Timofey

July 18, 2016, 21:47
#126
Senior Member

Elham
Join Date: Oct 2009
Posts: 184
Rep Power: 16
Quote:
 Originally Posted by tiam Hello! The depth of your domain looks a bit small, but that is probably no the main reason for things going bad. I suppose you have a good reason for not using cyclic b.c.s? What do you mean by "mapping method", do you recycle a velocity profile from downstream of the channel? You may need to take more special care of the initial conditions, i.e introduce meaningfull perturbations. Use the perturbU utility, it works just fine. Also, not to get dissipation that kills turbulence, use second order schemes for everything. For SGS modelling, pick up a dynamic model, or simply no model at all -- that works quite fine for me. If you use Smagorinsky or oneEqEddy, van Driest damping is a must. Regaring performance, it is hard to say anything, it all depends on how many cores you use given your meshsize, which is around 2 million. For such a mesh it would take one to three days to get a result using something like 64 cores. This is *very* approximate, since it all depends on how much time you want to sample your statistics. And this depends on what order statistics you want etc etc . The solver setting also play a role, e.g. the numre of inner/outer corrector loops. Hope this helps! Best, Timofey
Dear Tiam,

I think mapping is the same as cyclic b.c as it maps from some where inside the domain to the inlet during the solution.
I also mapped inlet condition from RAS results. I haven't used perturbU and supposed it will produce turbulence itself due to turbulent Re number.
Does it necessory to have perturbU? What is a meaningful perturbation?

Cheers,

Elahm

 August 31, 2016, 05:59 channel395 with different dimension #127 Senior Member   Elham Join Date: Oct 2009 Posts: 184 Rep Power: 16 Hi everybody, I want to use channel395 to produce a fully turbulent channel flow. Size of the channel is 4*2*2(mm). So I need to change initial velocity to have a turbulent flow. I tried purturbedU utility for Retau 395 and changed the internal flow velocity at zero time but I got a small perturbation. I tried to manipulate with all parameters but the solver stopped running. I even tried to decrease time step to have Co<1 that didn't work. I tried to map channel395 to my case but it crashed may be due to very different mesh size. Would you please let me know how I can set a turbulent initial flow for channel395 while dimension of channel is different. Regards, Elham

August 31, 2016, 06:03
#128
Senior Member

Timofey Mukha
Join Date: Mar 2012
Location: Stockholm, Sweden
Posts: 119
Rep Power: 14
Quote:
 Originally Posted by Elham Hi everybody, I want to use channel395 to produce a fully turbulent channel flow. Size of the channel is 4*2*2(mm). So I need to change initial velocity to have a turbulent flow. I tried purturbedU utility for Retau 395 and changed the internal flow velocity at zero time but I got a small perturbation. I tried to manipulate with all parameters but the solver stopped running. I even tried to decrease time step to have Co<1 that didn't work. I tried to map channel395 to my case but it crashed may be due to very different mesh size. Would you please let me know how I can set a turbulent initial flow for channel395 while dimension of channel is different. Regards, Elham
Hi Elham,

What do you mean by getting a "small perturbation". It got difffused out in the solution process and you didn't get turbulence? Or what was the problem?

Timofey

August 31, 2016, 22:04
#129
Senior Member

Elham
Join Date: Oct 2009
Posts: 184
Rep Power: 16
Quote:
 Originally Posted by tiam Hi Elham, What do you mean by getting a "small perturbation". It got difffused out in the solution process and you didn't get turbulence? Or what was the problem? Timofey
I mean the flow is not fully turbulent from the beginning to the end.
Another question: I am wondering if the initial flow field in channel395 is not turbulent, after some iteration the solution tends to turbulence or no?

Thanks,

Elham

 September 1, 2016, 03:17 #130 Senior Member   Cedric DUPRAT Join Date: Mar 2009 Location: Nantes, France Posts: 195 Rep Power: 17 Dear Elham, "I tried perturbU utility for Retau 395 and changed the internal flow velocity at zero time but I got a small perturbation" Yes, that is the all idea of PerturbU utility, adding "nice" perturbations close to the wall, where the shear stress is high to trigg you laminar profile to a turbulent one (please have a look on this thread : http://www.cfd-online.com/Forums/ope...-perturbu.html for more information). Then, you have to run the calculation using periodic BC. After few cross channel time, you should see you flow becoming turbulent. By checking you statistics you'll see when it is fully converged. I hope this will help you Cedric

September 1, 2016, 03:46
#131
Senior Member

Timofey Mukha
Join Date: Mar 2012
Location: Stockholm, Sweden
Posts: 119
Rep Power: 14
Quote:
 Originally Posted by Elham I mean the flow is not fully turbulent from the beginning to the end. Another question: I am wondering if the initial flow field in channel395 is not turbulent, after some iteration the solution tends to turbulence or no? Thanks, Elham
Not necessarily. If the numerics you using are diffusive enough and you don't have an intiialy well-perturbed field, you might not get turbulence.

/Timofey

September 1, 2016, 08:43
#132
Senior Member

Elham
Join Date: Oct 2009
Posts: 184
Rep Power: 16
Quote:
 Originally Posted by cedric_duprat Dear Elham, "I tried perturbU utility for Retau 395 and changed the internal flow velocity at zero time but I got a small perturbation" Yes, that is the all idea of PerturbU utility, adding "nice" perturbations close to the wall, where the shear stress is high to trigg you laminar profile to a turbulent one (please have a look on this thread : http://www.cfd-online.com/Forums/ope...-perturbu.html for more information). Then, you have to run the calculation using periodic BC. After few cross channel time, you should see you flow becoming turbulent. By checking you statistics you'll see when it is fully converged. I hope this will help you Cedric
Dear Cedric,

Did you use a DNS result for initial condition.

"you have to run the calculation using periodic BC. After few cross channel time, you should see you flow becoming turbulent. " I am not at the office today and tomorrow. When I come back there I will check it.

Thanks

Elham

September 1, 2016, 08:44
#133
Senior Member

Elham
Join Date: Oct 2009
Posts: 184
Rep Power: 16
Quote:
 Originally Posted by tiam Not necessarily. If the numerics you using are diffusive enough and you don't have an intiialy well-perturbed field, you might not get turbulence. /Timofey
Dear Timofey,

How can I know that the numerics that I am using is diffusive enough?

Regards,

Elham

September 1, 2016, 08:46
#134
Senior Member

Timofey Mukha
Join Date: Mar 2012
Location: Stockholm, Sweden
Posts: 119
Rep Power: 14
Quote:
 Originally Posted by Elham Dear Timofey, How can I know that the numerics that I am using is diffusive enough? Regards, Elham
Elham,

With OpenFoam your limit is second-order accuracy. To have that use central differencing and a second-order time-stepping scheme. That is about as much as you can do.

/Timofey

September 1, 2016, 08:48
#135
Senior Member

Elham
Join Date: Oct 2009
Posts: 184
Rep Power: 16
Quote:
 Originally Posted by tiam Elham, With OpenFoam your limit is second-order accuracy. To have that use central differencing and a second-order time-stepping scheme. That is about as much as you can do. /Timofey
Ok. I will try it.

Thanks,

Elham

 September 1, 2016, 08:57 #136 Senior Member   Cedric DUPRAT Join Date: Mar 2009 Location: Nantes, France Posts: 195 Rep Power: 17 Dear Elham, To initialize my calculation, I've only used PertrubU (parabolic profile for the streamwise velocity + perturbation close to the wall on different velocity component). Note that you can change the size (amplitude, frenquency, ...) of these perturbations in perturbU. If I remember correctly, you could "map fields" the channel395 velocity field to your channel, even if the size is not the same. Timofey has also done a nice work on channel flow (@Timofey; by the way, which version of OF had you used ?) that you can find online including a report and datas. I'm sure you'll find cooking receipe to run your LES calculations. Last point, in the forum I've also described quite a lot how I did do run LES calculations in pipes and channels. I hope this will help you, Best regards Cedric

September 1, 2016, 09:37
#137
Senior Member

Timofey Mukha
Join Date: Mar 2012
Location: Stockholm, Sweden
Posts: 119
Rep Power: 14
Quote:
 Originally Posted by cedric_duprat Dear Elham, To initialize my calculation, I've only used PertrubU (parabolic profile for the streamwise velocity + perturbation close to the wall on different velocity component). Note that you can change the size (amplitude, frenquency, ...) of these perturbations in perturbU. If I remember correctly, you could "map fields" the channel395 velocity field to your channel, even if the size is not the same. Timofey has also done a nice work on channel flow (@Timofey; by the way, which version of OF had you used ?) that you can find online including a report and datas. I'm sure you'll find cooking receipe to run your LES calculations. Last point, in the forum I've also described quite a lot how I did do run LES calculations in pipes and channels. I hope this will help you, Best regards Cedric
Hi Cedric! I used 2.2.0.

September 2, 2016, 02:00
#138
Senior Member

Elham
Join Date: Oct 2009
Posts: 184
Rep Power: 16
Quote:
 Originally Posted by cedric_duprat Dear Elham, To initialize my calculation, I've only used PertrubU (parabolic profile for the streamwise velocity + perturbation close to the wall on different velocity component). Note that you can change the size (amplitude, frenquency, ...) of these perturbations in perturbU. If I remember correctly, you could "map fields" the channel395 velocity field to your channel, even if the size is not the same. Timofey has also done a nice work on channel flow (@Timofey; by the way, which version of OF had you used ?) that you can find online including a report and datas. I'm sure you'll find cooking receipe to run your LES calculations. Last point, in the forum I've also described quite a lot how I did do run LES calculations in pipes and channels. I hope this will help you, Best regards Cedric

Regards,

Elham

September 5, 2016, 22:10
y+ for whole channel width
#139
Senior Member

Elham
Join Date: Oct 2009
Posts: 184
Rep Power: 16
Quote:
 Originally Posted by cedric_duprat Dear Elham, To initialize my calculation, I've only used PertrubU (parabolic profile for the streamwise velocity + perturbation close to the wall on different velocity component). Note that you can change the size (amplitude, frenquency, ...) of these perturbations in perturbU. If I remember correctly, you could "map fields" the channel395 velocity field to your channel, even if the size is not the same. Timofey has also done a nice work on channel flow (@Timofey; by the way, which version of OF had you used ?) that you can find online including a report and datas. I'm sure you'll find cooking receipe to run your LES calculations. Last point, in the forum I've also described quite a lot how I did do run LES calculations in pipes and channels. I hope this will help you, Best regards Cedric
Dear Cedric and Timofey,

I have used perturbU and run my case. It is working well. I also read Timofey report about LES in the channel. It is really great. Thanks for all.

My new issue is calculating y+ and u_tau. I looked at Timofey controlDict. He used the following command for y+:

yPlus
{
type patchExpression;
autowrite true;
patches ( bottomWall topWall);
outputControlMode timeStep;
outputInterval 1;
verbose true;
accumulations ( average );
}

and I developed the following one for u_tau myself:

uTau
{
type patchExpression;
autowrite true;
patches ( bottomWall topWall);
outputControlMode timeStep;
outputInterval 1;
verbose true;
accumulations ( average );
}

Both of them generate y+ and u_tau just for the first cell near the wall. How can I have y+ and u_tau for the whole channel width, something similar to the one that Timofey has shown in figure 4.1 or Cedric at the very first post of this topic. I am also wondering if u_tau that I have developed is correct?

Cheers,

Elham

 September 6, 2016, 02:52 #140 Senior Member   Cedric DUPRAT Join Date: Mar 2009 Location: Nantes, France Posts: 195 Rep Power: 17 Dear Elham, You should have a look at the postChannel tool in applications/utilities/postProcessing/miscellaneous/postChannel http://cpp.openfoam.org/v4/a04646.html " Post-processes data from channel flow calculations. Original source file postChannel.C For each time: calculate: txx, txy,tyy, txy, eps, prod, vorticity, enstrophy and helicity. Assuming that the mesh is periodic in the x and z directions, collapse Umeanx, Umeany, txx, txy and tyy to a line and print them as standard output. " I guess you'll find a usage of this tool in the tutorial related to channelFlow. Best Regards, Cedric