CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Running, Solving & CFD

Changing turbulent viscosity in streamwise component.

Register Blogs Community New Posts Updated Threads Search

Like Tree1Likes
  • 1 Post By Tobermory

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   June 16, 2021, 07:33
Default Changing turbulent viscosity in streamwise component.
  #1
New Member
 
David
Join Date: Jan 2021
Posts: 13
Rep Power: 5
dalschouten is on a distinguished road
Hi there, I am performing a pimpleFoam simulation and would expect a steady state with parameters throughout my water column similar to the boundary conditions, however, the values at the boundaries are only what I expected. How can you explain this behaviour? I did the same boundaries as the pitzDaily example, with a nutkroughwallfunction at the bottom.
Attached Images
File Type: jpg MicrosoftTeams-image (4).jpg (17.5 KB, 11 views)
dalschouten is offline   Reply With Quote

Old   June 16, 2021, 09:09
Default
  #2
Senior Member
 
Join Date: Apr 2020
Location: UK
Posts: 668
Rep Power: 14
Tobermory will become famous soon enough
I assume that you are running this as a transient run, and you are comparing against an expected steady state condition. Fine. But have you run the case for long enough? It will take a while for the flow to reach a steady behaviour, and you may only be glimpsing a snapshot of a transient behaviour. Try putting some probes in the channel, at different downstream locations, and monitor these with time.

I also recommend checking your pressure field - is it showing pressure pulses up and down this channel? If yes, and if these are not dying out as the simulation progresses, then you have an issue with your BCs.
Tobermory is offline   Reply With Quote

Old   June 17, 2021, 09:56
Default
  #3
New Member
 
David
Join Date: Jan 2021
Posts: 13
Rep Power: 5
dalschouten is on a distinguished road
Thank you for your quick reply. With a steady state solver I get my desired fields, but when I run pimplefoam for for example 5000s, I get no difference compared to T=2000s for example. I want to simulate 2phaseflow and wanted to explore the flow field with a single phase solver first. is it possible to run steady state+twophase with twophaseeulerfoam? I want to find rouse profiles (equilibrium sediment profiles) with different simulations.
dalschouten is offline   Reply With Quote

Old   June 17, 2021, 11:27
Default
  #4
Senior Member
 
Join Date: Apr 2020
Location: UK
Posts: 668
Rep Power: 14
Tobermory will become famous soon enough
David,

ok - good news that the solution is not pulsing, and that you have a steady solution. You probably need to give us some more info though, to help you out:

1. In the picture in your first post, what solver are you using and what are your boundary conditions?
2. Can you also provide similar plots of pressure, velocity and turbulence?
Tobermory is offline   Reply With Quote

Old   June 18, 2021, 03:07
Default
  #5
New Member
 
David
Join Date: Jan 2021
Posts: 13
Rep Power: 5
dalschouten is on a distinguished road
I am using the pimpleFoam solver for the single phase. I am using the k epsilon turbulence model. I am modelling a rigid lid with a slightly rough uniform bed and my model dimensions are 15 m long x 0.25 m depth: a 2DV model. My boundary conditions are as follows:

u
PHP Code:
internalField   uniform (0.0 0 0);

boundaryField
{
    
outlet
    
{
       
type             zeroGradient;
    }
    
inlet
    
{
        
type            fixedValue;
        
value           uniform (0.1 0 0);
    }
    
bottom
    
{
        
type            noSlip;
    }
    
surface
    
{
        
type            slip;
    }
    
defaultFaces
    
{
        
type             empty;
    }


p
PHP Code:
internalField   uniform 0;

boundaryField
{
    
inlet
    
{
       
type            zeroGradient;
      
    }
    
    
outlet
    
{
        
type            fixedValue;
        
value           uniform 0.0;
    }
    
    
bottom
    
{
        
type            zeroGradient;
    }
    
surface
    
{
        
type             zeroGradient;
    }
    
    
defaultFaces
    
{
        
type            empty;
    } 
k
PHP Code:
internalField   uniform 0.00015;

boundaryField
{
    
inlet
    
{
        
type            fixedValue;
        
value           uniform 0.00015;
    }
    
outlet
    
{
        
type            zeroGradient;
    }
    
surface
    
{
        
type            kqRWallFunction;
        
value            uniform 0.00015;
        
    }    
    
bottom
    
{
        
type            kqRWallFunction;
        
value           uniform 0.00015;
    }    
    
    
defaultFaces
    
{
        
type            empty;
    } 
epsilon
PHP Code:
internalField   uniform  1.7249667E-05;

boundaryField
{
    
inlet
    
{
        
type            fixedValue;
        
value           uniform  1.7249667E-05;
;
    }
    
outlet
    
{
        
type            zeroGradient;
    }
    
surface
    
{
        
type            epsilonWallFunction;
        
value           uniform  1.7249667E-05;
    }
    
bottom
    
{
        
type            epsilonWallFunction;
        
value           uniform  1.7249667E-05;
    }
    
    
defaultFaces
    
{
        
type            empty;
    }


nut
PHP Code:
boundaryField
{
    
inlet
    
{
        
type            calculated;
        
value           uniform 0;
    }
    
    
outlet
    
{
        
type            calculated;
        
value           uniform 0;
    }
    
    
surface
    
{
        
type            nutkWallFunction;
        
value           uniform 0;
    }
    
    
bottom
    
{
        
type               nutkRoughWallFunction;
        
Ks                uniform 0.00420855;
        
Cs              uniform 0.5;
        
value           $internalField;
        
    }
    
    
defaultFaces
    
{
         
type               empty;
         
    }
    

Attached Images
File Type: jpg screenshot_k.jpg (15.0 KB, 6 views)
File Type: jpg screenshot_pressure.jpg (11.8 KB, 5 views)
File Type: jpg screenshot_u.jpg (16.1 KB, 5 views)
dalschouten is offline   Reply With Quote

Old   June 18, 2021, 05:16
Default
  #6
New Member
 
David
Join Date: Jan 2021
Posts: 13
Rep Power: 5
dalschouten is on a distinguished road
The grid length is the tricky part. It seems that it is not long enough to develop uniform flow conditions, see figure, this length is 30m. What I would like to do is to get the latter half of my simulation, but this is probably not possible, right?
Thank you for the help.
Attached Images
File Type: jpg longergridlength.jpg (13.1 KB, 5 views)

Last edited by dalschouten; June 18, 2021 at 05:18. Reason: addition figure
dalschouten is offline   Reply With Quote

Old   June 18, 2021, 09:20
Default
  #7
Senior Member
 
Join Date: Apr 2020
Location: UK
Posts: 668
Rep Power: 14
Tobermory will become famous soon enough
Ok. I understand now - your original results make sense and look okay. Making the domain longer will not help.

You have a reasonable looking boundary layer growing on your bottom (rough wall) surface. This BL looks fine. At the top boundary, you have a slip wall, which acts as a constraint on the free stream. In other words, as the BL grows and the BL displacement thickness increases, the cross sectional area for the free stream decreases and the flow therefore has to accelerate. That's why your nut is increasing downstream - you are enforcing quite a strong dPdx by your fixed lid top BC, and this accelerates the flow thereby increasing nut.

If you want to get rid of the free stream acceleration (ie most of the additional dPdX) then try sloping the top boundary upwards, to make room for the BL growth. In wind tunnels, the top surface is often flexible, to allow adjustment to give a "flat plate" or zero pressure gradient flow.
dalschouten likes this.
Tobermory is offline   Reply With Quote

Old   June 18, 2021, 09:44
Default
  #8
New Member
 
David
Join Date: Jan 2021
Posts: 13
Rep Power: 5
dalschouten is on a distinguished road
Thanks I will try this! The thing is however that I need to model it as rigid lid, as I am validating a rigid lid study. And which length is preferable, the 15m grid or 30m?
dalschouten is offline   Reply With Quote

Old   June 18, 2021, 09:50
Default
  #9
Senior Member
 
Join Date: Apr 2020
Location: UK
Posts: 668
Rep Power: 14
Tobermory will become famous soon enough
Understood, re: the necessity for a rigid lid. Can you make the domain taller? The % increase in free stream will be smaller if the domain is taller.

By the way, you can keep a rigid lid but have a slope on the upper boundary, and that will relieve some of the free stream acceleration - as a first step, just increase the height of the coords at the end of the channel by the BL thickness that you have modelled in your existing run and rerun blockMesh - that will give you a sloped upper surface. If you do this, and make the channel taller, you should be in a much better place.

Finally, to remove the initial period of flow development, you can take a profile out from your simulation and map that onto your inlet, using the timeVaryingMappedFixedValue boundary condition. That will give you a realistic inflow profile and avoid the flow development zone.

Good luck!
Tobermory is offline   Reply With Quote

Old   June 18, 2021, 10:09
Default
  #10
New Member
 
David
Join Date: Jan 2021
Posts: 13
Rep Power: 5
dalschouten is on a distinguished road
I just looked into the addition of this, but no result that yields better results.

fvOptions for constant pressure gradient
dalschouten is offline   Reply With Quote

Old   June 18, 2021, 10:14
Default
  #11
Senior Member
 
Join Date: Apr 2020
Location: UK
Posts: 668
Rep Power: 14
Tobermory will become famous soon enough
Well, yes - in my closed channelFlow simulations I use the following fvOptions:

Code:
pressureGradient
{
    type            semiImplicitSource;
    active               true;
    selectionMode   all;
    volumeMode      specific;  //absolute
    sources 
    {
        U
        {
            explicit (0.4900 0 0);    // kinematic pressure gradient, -(1/rho).dp/dx
            implicit  0;
        }
    }
}
where the dPdx value is calculated to balance the wall shear stress. I then use cyclic boundaries at each end, to feed the outflow back in as inflow.

But you have a different issue here - you don't have a fully developed channel flow, but instead have a boundary layer that is growing up off the bottom wall. You will eventually get to a develolped flow, I guess, a long way downstream when your BL spans the whole height of the channel - is that what you want? If yes, then maybe an approach like the one above makes sense. Otherwise, you need to make allowance for the BL growth.
Tobermory is offline   Reply With Quote

Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Drag Force Ratio for Flat Plate Rob Wilk Main CFD Forum 40 May 10, 2020 04:47
Identifying cells having Turbulent viscosity limited to viscosity ratio of 1.000e+05 Sayantan Biswas FLUENT 0 September 20, 2019 04:49
setting value of turbulent intensity and turbulent viscosity ratio in wind tunnel nuimlabib Main CFD Forum 0 August 4, 2009 00:05
Problems with changing turbulent viscosity by UDF sarah_ron FLUENT 0 February 14, 2005 00:31
Changing turbulent viscosity ap FLUENT 0 December 16, 2003 16:25


All times are GMT -4. The time now is 01:53.