|
[Sponsors] |
April 6, 2009, 11:29 |
Negative values in scalar transport
|
#1 |
New Member
James Nally
Join Date: Apr 2009
Posts: 7
Rep Power: 17 |
I am trying to solve the following scalar transport equation using a steady state flow solution obtained using simpleFoam:
fvm::ddt(Y) + fvm::div(phi, Y) – fvm::laplacian(DY + (turbulence->nut() / Sct), Y) Where Sct is the turbulent Schmidt number. The solver seems to run fine however, I sometimes get negative values reported when tracking the scalar using probes throughout the domain. I have looked through the forums and found a couple of posts that describe the same situation although trying out the solutions found there does not solve my problem. My fvSchemes file is as follows: ddtSchemes { default none; ddt(Y) Euler; } gradSchemes { default none; snGradCorr(Y) Gauss linear; grad(Y) Gauss linear; } divSchemes { default none; div(phi,Y) Gauss Gamma01 1; } laplacianSchemes { default none; laplacian((DY+(((Cmu*spr(k))|epsilon+epsilonSmall))|Sct)),Y) Gauss linear limited 1; } interpolationSchemes { default none; } snGradSchemes { default none; } fluxRequired { default no; Y; } Does anyone have any suggestions? |
|
April 7, 2009, 05:12 |
|
#2 |
Senior Member
Mark Olesen
Join Date: Mar 2009
Location: https://olesenm.github.io/
Posts: 1,714
Rep Power: 40 |
Are you using "inletOutlet" conditions for the inlets of your scalar?
This is important if your inlets have backflow anytime during the solution. |
|
April 7, 2009, 07:44 |
Thanks for the reply
|
#3 |
New Member
James Nally
Join Date: Apr 2009
Posts: 7
Rep Power: 17 |
Thanks for the reply.
I am not using the inletOutlet condition but I have just checked and made sure that there is no backflow on the inlets. It is a steady state flow so there will be no fluctuations throughout the simulation. All of the inlets are using a fixedValue for velocity and turbulence, one is also using fixedValue to introduce the scalar (pressure is set as zeroGradient). The outlet patches are set as zeroGradient for velocity, turbulence and scalar with a fixedValue (0) for the pressure. James |
|
September 26, 2009, 10:56 |
Solved!!
|
#4 |
New Member
James Nally
Join Date: Apr 2009
Posts: 7
Rep Power: 17 |
I revisited and have solved my problem (which incidentally only occurred when using tet-meshes) by using these schemes:
grad: leastSquares div: Gauss upwind laplacian: Gauss linear uncorrected Just in case anyone else has a similar problem. |
|
June 2, 2017, 15:12 |
Thanks
|
#5 |
Member
Sugajen
Join Date: Jan 2012
Location: Tempe, USA
Posts: 52
Rep Power: 14 |
Thank you! Your schemes worked for me too.
|
|
August 23, 2018, 16:32 |
|
#6 | |
Senior Member
Reviewer #2
Join Date: Jul 2015
Location: Knoxville, TN
Posts: 141
Rep Power: 11 |
Quote:
This is only first order and very diffusive. You should use TVD and other shock capturing scheme to handle the discontinuity in your simulation, such as vanLeer |
||
Tags |
negative values, numerical scheme, scalar transport |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Preventing negative scalar (UDS) values?? | Matthew Brannock | FLUENT | 5 | September 1, 2020 13:32 |
[blockMesh] BlockMesh FOAM warning | gaottino | OpenFOAM Meshing & Mesh Conversion | 7 | July 19, 2010 15:11 |
[blockMesh] Axisymmetrical mesh | Rasmus Gjesing (Gjesing) | OpenFOAM Meshing & Mesh Conversion | 10 | April 2, 2007 15:00 |
negative values for diffusion scalar | cmv | Siemens | 0 | April 18, 2005 07:21 |