
[Sponsors] 
March 29, 2010, 17:20 
Usinng divDevReff vs div(R) + laplacian(nu,U)

#1 
Member
Matthew J. Churchfield
Join Date: Nov 2009
Location: Boulder, Colorado, USA
Posts: 49
Rep Power: 12 
I am wondering if anyone can help with a problem I am encountering. I need to apply boundary conditions on SGS stresses in addition to nuSgs. I would like to perform nearwall modeling in LES by setting the stess at the wall.
Therefore, I have reformulated the UEqn matrix in a PISO solver to look like: fvm::ddt(U) + fvm:div(phi,U) + div(R) + laplacian(nu,U) where R = turbulence>R(); Originally, the code is as follows: fvm::ddt(U) + fvm:div(phi,U) + turbulence>divDevReff(U) I am finding that if I set the value of the shear stress at the ground, the solution develops very oscillatory instabilities. If I set the boundary condition of R to zeroGradient, things are okay, but I need to be able to set specific stress tensor values at the ground. Any ideas?? Thanks, Matt 

April 5, 2010, 15:27 

#2 
Member
Matthew J. Churchfield
Join Date: Nov 2009
Location: Boulder, Colorado, USA
Posts: 49
Rep Power: 12 
I just want to ask the above question again. If anyone can help, it would be much appreciated.
Matt 

April 8, 2010, 07:34 

#3 
New Member
CHB
Join Date: Oct 2009
Posts: 3
Rep Power: 10 
Could it be that the signs of your div() and laplacian() term are wrong?
Maybe fvm::ddt(U) + fvm:div(phi,U)  fvc::div(R)  fvm::laplacian(nu,U) solves your problem. 

April 8, 2010, 09:26 
Using divDevReff vs div(R)  laplacian(nu,U)

#4 
Member
Matthew J. Churchfield
Join Date: Nov 2009
Location: Boulder, Colorado, USA
Posts: 49
Rep Power: 12 
Christof, Thanks for your reply. You are correct about my signs being partially incorrect. I typed them into my original posting at the top of the thread incorrectly, but I had them coded correctly. They should be fvm::ddt(U) + fvm:div(phi,U) + fvc::div(R)  fvm::laplacian(nu,U) where R = turbulence>R(). One interesting thing that I am finding is that in the code for a full Reynolds or SGS stress model like the LRR model, divDevReff(U) is defined as: + fvc::div(R_ + couplingFactor_*nut_*fvc::grad(U), "div(R)") + fvc::laplacian((1.0  couplingFactor_)*nut_,U,"laplacian(nuEff,U)")  fvm::laplacian(nuEff(), U) which is interesting. Why not just define it as + fvc::div(R)  fvm::laplacian(nu, U) like I have unsuccessfully tried to do? The above formulation contains both a "coupling factor", which could possibly by used for stability reasons, and it contains an implicit Laplacian that uses nuEff (which is larger than just nu), which seems to be important for stability in OpenFOAM solvers. divDevReff(U) in the eddyviscosity based solvers also is formulated to include an implicit Laplacian that uses nuEff, although there would be other ways to formulate this term without a Laplacian using nuEff such as  fvc::div(nut_*twoSymm(fvc::grad(U)))  fvm::laplacian(nu,U) Since at least the OpenFOAM PISObased solvers do not include added dissipation terms, I am wondering if this fvm::laplacian(nuEff,U) is in there for stability reasons. Matt 

April 9, 2010, 04:37 

#5 
New Member
CHB
Join Date: Oct 2009
Posts: 3
Rep Power: 10 
Since fvc::div(R) is an explicit term, it might cause numerical instabilities when your time step is too large. Maybe reducing the time step to get a cell CFL number less than 1 helps. CFL = U_ref * DT / DX where DX is the cell size and DT the time step. I'd try DT = 0.25 * DX / U_ref to get the explicit formulation stable. (Depending on the diffusion number it could be that you even need an much smaller time step with an explicit formulation.)
Last edited by chb; April 9, 2010 at 04:55. 

April 8, 2015, 08:29 

#6 
New Member
Panagiotis Giannatselis
Join Date: Jan 2015
Location: Athens, Greece
Posts: 5
Rep Power: 5 
hi everyone
I am trying to use the following UEqn tmp<fvVectorMatrix> UEqn ( fvm::div(phi, U)  fvm::laplacian(nueff, U)  g  fvm::div(nueff, fvc::grad(U))  fvm::div(nueff, T(fvc::grad(U))) //this line == fvOptions(U) ); nueff is volScalarField errors that no matching function for call to ‘div(Foam::volSca.......... appear and I can't find out where I am wrong. Can anyone point out how I should syntax the two terms. Without these terms no errors appear. Thanks a lot in advance. 

Thread Tools  
Display Modes  

