CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > General Forums > Main CFD Forum

Nut modification in k-omega turbulence model

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   August 9, 2021, 11:25
Default Nut modification in k-omega turbulence model
  #1
New Member
 
renos
Join Date: Dec 2019
Posts: 16
Rep Power: 6
renos is on a distinguished road
Hello,

I want to modify turbulent viscosity of the k-omega turbulence model to avoid the overprediction according to the proposed limiter:

nut= min(k/omega,(sqrt(2)/3)*k/(magnitude of the strain tensor))

How I can write this in openfoam?

I have tried with this format, the compile of the turbulence model is without errors, but when I run the solver, then there is a division with zero.

template<class BasicMomentumTransportModel>
void kOmega2006<BasicMomentumTransportModel>::correctNu t
(
const volTensorField& gradU
)
{

this->nut_ = min(k_/omega_, (double(0.81649)*k_)/sqrt(magSqr(symm(gradU)))));
this->nut_.correctBoundaryConditions();
fv:ptions::New(this->mesh_).correct(this->nut_);
}


Anybody knows what's the error?

Kind regards,

Renos
renos is offline   Reply With Quote

Old   October 8, 2021, 06:39
Default
  #2
New Member
 
Tomas Korinek
Join Date: Dec 2013
Location: Prague, CZ
Posts: 2
Rep Power: 0
korenml is on a distinguished road
Hello Renos,
did you figured it out?
I would rather to code it in this form

Code:
template<class BasicMomentumTransportModel>
void kOmega2006<BasicMomentumTransportModel>::correctNut
(
     const volScalarField& S2
)
{
     this->nut_ = min(k_/omega_, ((sqrt(2)/3)*k_)/sqrt(S2);
     this->nut_.correctBoundaryConditions();
     fv::options::New(this->mesh_).correct(this->nut_);
}

template<class BasicEddyViscosityModel>
void kOmega2006<BaxicMomentumTransportModel>::correctNut
{
     correctNut(2*magSqr(symm(fvc::grad(this->U_))));
}
See the code for kOmegaSST.

Or you can try if the kOmegaSST model is calculating without error, just to check your BC's are set correctly.

Best,
Tomas
korenml 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
[swak4Foam] swakExpression not writing to log alexfells OpenFOAM Community Contributions 3 March 16, 2020 18:19
Initial/boundary conditions for k and omega in k-omega-SST turbulence model elmo555 OpenFOAM Pre-Processing 0 January 24, 2018 10:31
Question about adaptive timestepping Guille1811 CFX 25 November 12, 2017 17:38
Overflow Error in Multiphase Modelling with Two Continuous Fluids ashtonJ CFX 6 August 11, 2014 14:32
Scaling omega in SST turbulence model TedBrogan Main CFD Forum 0 January 23, 2013 00:00


All times are GMT -4. The time now is 19:09.