
[Sponsors] 
May 5, 2010, 05:07 
New implemented algebraic Reynolds stress model

#1 
New Member
Volker Tritschler
Join Date: Jan 2010
Posts: 20
Rep Power: 9 
Hi all,
I have implemented a new algebraic Reynolds stress model for two and three dimensional incompressible flows. The model is written in LowRe formulation in order to get accurate Reynolds stress in the nearwall region and to get the right gradients for heat and mass transfer purposes. The model is based on the Wallin paper “An explicit algebraic Reynolds stress model for incompressible and compressible turbulent flows”, J. Fluid. Mech., 200, vol. 403, pp. 89132. In addition, there are two production limiters implemented according to Jones and Launder and one according to Menter. Thanks to Wayne Zhang from the forum here, there is also a curvature correction included based on the Richardson number , to be found in the A. Hellsten paper “Some Improvements in Menter's KOmega SST Turbulence Model” AIAA A9832817. I made some simulations for a turbulent pipe flow and compared the results with data obtained from DNS and experiments. The results are in very good agreement. But there is still some room for improvements. At this stage, the crucial point is to loop back the Reynolds stress tensor obtained from the algebraic stress model into the momentum equation. This is to get rid of Boussinesq's analogy in standard eddy viscosity models. If anybody is interested in a well performing algebraic Reynolds stress model, I would appreciate any help and ideas for improvements. It might be also interesting to have it ready for the next release of OpenFOAM, since to my knowledge there is no Reynolds stress model in LowRe formulation which gives satisfying results. If anybody is interested in the papers, I can send it to him, no problem. Greets, volker The turbulence model needs dynamic compilation with: "wmake libso" and libs ("kOmegaSST_Wallin_CC.so"); has to be added in ControlDict 

May 6, 2010, 05:14 

#2 
Senior Member
Claus Meister
Join Date: Aug 2009
Location: Wiesbaden, Germany
Posts: 241
Rep Power: 10 
Hello volker,
i wanted to try it. Unfotunately, I got this error message: make: *** No rule to make target `/home/idrama/OpenFOAM/OpenFOAM1.6/src/meshTools/lnInclude/cellDistFuncsTemplates.C', needed by `kOmegaSST_Wallin_CC.dep'. Stop. What do I do to get it running? Cheers, Claus 

May 6, 2010, 06:30 

#3 
New Member
Volker Tritschler
Join Date: Jan 2010
Posts: 20
Rep Power: 9 
hi claus,
did you put "wclean" before "wmake libso"? It's hard say where the problem might be. I've never had this error message, but on the other side I've never tried to get to code running on another computer. would be interesting to know if others had the same kind of problem. volker 

May 6, 2010, 08:23 

#4 
Senior Member
Claus Meister
Join Date: Aug 2009
Location: Wiesbaden, Germany
Posts: 241
Rep Power: 10 
hi volker,
i did what you said and it is implemented now. I started an interFoam case with the new model. As usual, I chose linear schemes for U, k and epsilon. Up to the epsilon equation, all equations are solved fine. By the solving step of e, the simulations abords with an error msg: #0 Foam::error:rintStack(Foam::Ostream&) in "/home/idrama/OpenFOAM/OpenFOAM1.6/lib/linux64GccDPOpt/libOpenFOAM.so" #1 Foam::sigSegv::sigSegvHandler(int) in "/home/idrama/OpenFOAM/OpenFOAM1.6/lib/linux64GccDPOpt/libOpenFOAM.so" #2 ?? in "/lib64/libc.so.6" #3 Foam::incompressible::RASModels::kOmegaSST_Wallin_ CC::correct() in "/home/idrama/OpenFOAM/OpenFOAM1.6/lib/linux64GccDPOpt/kOmegaSST_Wallin_CC.so" #4 main in "/home/idrama/OpenFOAM/OpenFOAM1.6/applications/bin/linux64GccDPOpt/interFoam" #5 __libc_start_main in "/lib64/libc.so.6" #6 _start at /usr/src/packages/BUILD/glibc2.9/csu/../sysdeps/x86_64/elf/start.S:116 Segmentation fault I guess, there is something to fix it. Stick around, I will test it for you in interFoam cases. Cheers, Claus 

May 6, 2010, 08:40 

#5 
New Member
Volker Tritschler
Join Date: Jan 2010
Posts: 20
Rep Power: 9 
hi claus,
I think the problem is that you will need an omega file instead of an epsilon one. since it is the SST model which blends the omega transport equation in the boundary layer to an epsilon transport equation in the free stream (but still omega based). greets volker 

May 6, 2010, 10:08 

#6 
New Member
Volker Tritschler
Join Date: Jan 2010
Posts: 20
Rep Power: 9 
in the actual implementation of Wallin's turbulence model two things need still to be added to have it properly implemented
1) the Reynolds stress tensor needs to be looped back into the momentum equation. Which is actually already included, but with unsatisfying results yet 2) the Reynolds stresses have to be used somehow in the production term of the k and omega transport equation. in the standard SST model here only Boussinesq's approximation for isotropic turbulence comes in. The normal Reynolds stresses are fairly well predicted already without point 1) and 2), but in order to get for instance secondary flows etc and the right prediction of shear stress, it is crucial to get the model fully implemented. Hope someone has some ideas!? cheers volker 

May 7, 2010, 08:03 

#7 
Member
Markus Weinmann
Join Date: Mar 2009
Location: Stuttgart, Germany
Posts: 77
Rep Power: 10 
Hi,
I suggest you have a look at the nonlinear RAS models available in OF. You can follow the same procedure to include your nonlinear terms. Markus 

May 7, 2010, 10:30 

#8 
New Member
Volker Tritschler
Join Date: Jan 2010
Posts: 20
Rep Power: 9 
hi markus,
many thanks! that sounds like a good idea. I will have a look at it. cheers, volker 

November 15, 2010, 13:12 
Wall boundary condition for Omega

#9 
Member
Heng Xiao
Join Date: Mar 2009
Location: Zurich, Switzerland
Posts: 58
Rep Power: 10 
Hi Volker,
I am very interested in this model. Did you use the following BC for omega, omega = 10*6*nu/(0.075*y^2) or did you use the wall function? As y = 0 at the wall, the expression should predict Omega to be Infinity ... then, what is the proper boundary conditionf for Omega? Best, Heng 

November 15, 2010, 13:23 
Wall boundary condition for Omega (cont)

#10 
Member
Heng Xiao
Join Date: Mar 2009
Location: Zurich, Switzerland
Posts: 58
Rep Power: 10 
Hi Volker,
From the following code in the function "correct", omegaEqn().boundaryManipulate(omega_.boundaryField ()); which also appeared in the high Re kOmega model (this model should be used with y+ > 30 and wall functions), it seems that the model you implemented is also intended to use wallfunctions (and together with a grid with y+ = 1?) I don't quite understand. Could you explain a bit? Thanks very much. BTW, did you implement the features you proposed (looping R back to momentum equation and k equation? If not, I think we can work together on this, as I am also interested. Best, Heng 

November 15, 2010, 14:01 
Bounday treatment

#11 
Member
Heng Xiao
Join Date: Mar 2009
Location: Zurich, Switzerland
Posts: 58
Rep Power: 10 
Hi Volker,
I noticed that for the following expression in function "correct()", index "inletPatchID" appeared on the RHS. Logically I would expect it to be "outletPatchID" and "wallPatchID" respectively, just to be consistent with the LHS. Or may be am I missing something? Another question: is this treatment genral enough? What if my walls are called "topWall" and "bottom wall"? Best, Heng forAll(P2.boundaryField()[outletPatchID], ox) { if (P2.boundaryField()[outletPatchID][ox] >= 0.0) { N_.boundaryField()[outletPatchID][ox] = (A_3.boundaryField()[inletPatchID][ox]/3.0) + pow(P1.boundaryField()[inletPatchID][ox] + sqrt(P2.boundaryField()[inletPatchID][ox]),(1.0/3.0)) + sign(P1.boundaryField()[inletPatchID][ox]sqrt(P2.boundaryField()[inletPatchID][ox]))*pow(mag(P1.boundaryField()[inletPatchID][ox]  sqrt(P2.boundaryField()[inletPatchID][ox])),(1.0/3.0)); } } forAll(P2.boundaryField()[wallPatchID], wx) { if (P2.boundaryField()[wallPatchID][wx] >= 0.0) { N_.boundaryField()[wallPatchID][wx] = (A_3.boundaryField()[inletPatchID][wx]/3.0) + pow(P1.boundaryField()[inletPatchID][wx] + sqrt(P2.boundaryField()[inletPatchID][wx]),(1.0/3.0)) + sign(P1.boundaryField()[inletPatchID][wx]sqrt(P2.boundaryField()[inletPatchID][wx]))*pow(mag(P1.boundaryField()[inletPatchID][wx]  sqrt(P2.boundaryField()[inletPatchID][wx])),(1.0/3.0)); } } 

August 7, 2012, 05:08 

#12 
Member
wided
Join Date: Jul 2010
Posts: 54
Rep Power: 8 
Hi Volker,
thank you for the implementation. I am also working on implementing an algebraic model in openfoam and I wanted to test your model. Unfortunately I get the following error when I try to compile it, any ideas? wmake libso wmakeLnInclude: linking include files to ./lnInclude Making dependency list for source file kOmegaSST_Wallin_CC.C SOURCE=kOmegaSST_Wallin_CC.C ; g++ m64 Dlinux64 DWM_DP Wall Wextra Wnounusedparameter Woldstylecast Wnonvirtualdtor O3 DNoRepository ftemplatedepth100 I/home/wided/OpenFOAM/OpenFOAM2.1.1/src/finiteVolume/lnInclude I/home/wided/OpenFOAM/OpenFOAM2.1.1/src/meshTools/lnInclude I/home/wided/OpenFOAM/OpenFOAM2.1.1/src/transportModels I/home/wided/OpenFOAM/OpenFOAM2.1.1/src/turbulenceModels/incompressible/RAS/lnInclude I/home/wided/OpenFOAM/OpenFOAM2.1.1/src/turbulenceModels IlnInclude I. I/home/wided/OpenFOAM/OpenFOAM2.1.1/src/OpenFOAM/lnInclude I/home/wided/OpenFOAM/OpenFOAM2.1.1/src/OSspecific/POSIX/lnInclude fPIC c $SOURCE o Make/linux64GccDPOpt/kOmegaSST_Wallin_CC.o kOmegaSST_Wallin_CC.H: In constructor ‘Foam::incompressible::RASModels::kOmegaSST_Wallin _CC::kOmegaSST_Wallin_CC(const Foam::volVectorField&, const Foam::surfaceScalarField&, Foam::transportModel&)’: kOmegaSST_Wallin_CC.H:137: warning: ‘Foam::incompressible::RASModels::kOmegaSST_Wallin _CC::epsilon_’ will be initialized after kOmegaSST_Wallin_CC.H:136: warning: ‘Foam::volScalarField Foam::incompressible::RASModels::kOmegaSST_Wallin_ CC::nut_’ kOmegaSST_Wallin_CC.C:95: warning: when initialized here kOmegaSST_Wallin_CC.C: In member function ‘virtual void Foam::incompressible::RASModels::kOmegaSST_Wallin_ CC::correct()’: kOmegaSST_Wallin_CC.C:488: error: ‘k0_’ was not declared in this scope kOmegaSST_Wallin_CC.C:612: error: conversion from ‘Foam::tmp<Foam::GeometricField<Foam::Tensor<doubl e>, Foam::fvPatchField, Foam::volMesh> >’ to nonscalar type ‘Foam::volSymmTensorField’ requested In file included from kOmegaSST_Wallin_CC.H:82, from kOmegaSST_Wallin_CC.C:27: /home/wided/OpenFOAM/OpenFOAM2.1.1/src/turbulenceModels/incompressible/RAS/lnInclude/RASModel.H: In static member function ‘static Foam::autoPtr<Foam::incompressible::RASModel> Foam::incompressible::RASModel::adddictionaryConst ructorToTable<RASModelType>::New(const Foam::volVectorField&, const Foam::surfaceScalarField&, Foam::transportModel&, const Foam::word&) [with RASModelType = Foam::incompressible::RASModels::kOmegaSST_Wallin_ CC]’: /home/wided/OpenFOAM/OpenFOAM2.1.1/src/turbulenceModels/incompressible/RAS/lnInclude/RASModel.H:138: instantiated from ‘Foam::incompressible::RASModel::adddictionaryCons tructorToTable<RASModelType>::adddictionaryConstru ctorToTable(const Foam::word&) [with RASModelType = Foam::incompressible::RASModels::kOmegaSST_Wallin_ CC]’ kOmegaSST_Wallin_CC.C:44: instantiated from here /home/wided/OpenFOAM/OpenFOAM2.1.1/src/turbulenceModels/incompressible/RAS/lnInclude/RASModel.H:126: error: no matching function for call to ‘Foam::incompressible::RASModels::kOmegaSST_Wallin _CC::kOmegaSST_Wallin_CC(const Foam::GeometricField<Foam::Vector<double>, Foam::fvPatchField, Foam::volMesh>&, const Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh>&, Foam::transportModel&, const Foam::word&)’ kOmegaSST_Wallin_CC.C:95: note: candidates are: Foam::incompressible::RASModels::kOmegaSST_Wallin_ CC::kOmegaSST_Wallin_CC(const Foam::volVectorField&, const Foam::surfaceScalarField&, Foam::transportModel&) kOmegaSST_Wallin_CC.H:101: note: Foam::incompressible::RASModels::kOmegaSST_Wallin_ CC::kOmegaSST_Wallin_CC(const Foam::incompressible::RASModels::kOmegaSST_Wallin_ CC&) make: *** [Make/linux64GccDPOpt/kOmegaSST_Wallin_CC.o] Error 1 

December 2, 2012, 22:54 

#13 
New Member
Join Date: Sep 2012
Posts: 10
Rep Power: 6 
Hi all,
I am also working on implementing an algebraic reynolds stress model in OF (Gatski and Menter) and facing a lot of problems. Has anybody done this before and can post his files (regardless of the considered model)? Would appreciate it. Beeo 

October 21, 2013, 00:01 
Papers for perusal

#14 
Member
Manan
Join Date: Oct 2013
Location: Göteborg
Posts: 37
Rep Power: 5 
Hi Volker Could you send me the paper titled 'Elements Of Industrial Heat Transfer Prediction', (16 Nov 2001) by FR Menter and T Esch, which you have referenced in kOmegaSST_Wallin_CC.H? Thanks. My email address is manan.iitk@@gmail.com


Thread Tools  
Display Modes  


Similar Threads  
Thread  Thread Starter  Forum  Replies  Last Post 
implement explicit algebraic stress model EASM  Thomas Baumann  OpenFOAM  4  January 23, 2012 12:41 
Reynolds Stress Turbulence Model  cesar.14bis  Phoenics  2  December 2, 2010 22:28 
Reynolds Stress Models  Jade M  Main CFD Forum  0  April 21, 2010 16:38 
Reynolds Stress Model in Fluent Vs CFX  Tim  FLUENT  0  December 6, 2005 23:03 
Reynolds Stress model  Siqui  FLUENT  0  June 22, 2005 09:32 