CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > OpenFOAM Programming & Development

problem while defining a new volScalarField in a new turbulence model

Register Blogs Members List Search Today's Posts Mark Forums Read

Reply
 
LinkBack Thread Tools Display Modes
Old   January 24, 2013, 02:44
Default problem while defining a new volScalarField in a new turbulence model
  #1
Member
 
Nikesh Bhattarai
Join Date: Nov 2011
Location: Daejeon, South Korea
Posts: 56
Rep Power: 3
nikesh is an unknown quantity at this point
Hii Foamers,
I am working on a new turbulence model which utilizes the basic Governing Equations of LaunderSharmaKE model. I need to modify the expression for nut. While doing so, I make use of a new term, k2e (it is a name i have given to this new variable, where k2e = sqr(k_)/epsilonTilda_ ) and in one part of the code it requires me to solve for div(phi_,k2e). I could implement all the equations and expressions in the new source code and I could also compile it successfully.
But when I try to run a case using that scheme, I get an error message::
--> FOAM FATAL IO ERROR:
[4] [8] keyword div(phi,(sqr(k)|epsilon)) is undefined in dictionary "/home/users/nikesh/Work/mvg/2-3Dflatplate-test/processor8/../system/fvSchemes::divSchemes"

I get the idea that this error is asking me to define the div(phi,k2e) term in the system/fvScheme file. I did that too.
Under the
divSchemes
I included
div(phi,k2e) Gauss upwind

And I still get the same error!
Any help is highly appreciated.
Thanks!!
nikesh
nikesh is offline   Reply With Quote

Old   January 24, 2013, 11:25
Default
  #2
Member
 
Join Date: Jun 2011
Posts: 39
Rep Power: 5
blacksquirrel is on a distinguished road
Hi Nikesh,
Include the exact keyword in your fvSchemes, so:

div(phi,(sqr(k)|epsilon)) Gauss upwind;

That should do it.
blacksquirrel is offline   Reply With Quote

Old   January 24, 2013, 20:35
Default
  #3
Member
 
Nikesh Bhattarai
Join Date: Nov 2011
Location: Daejeon, South Korea
Posts: 56
Rep Power: 3
nikesh is an unknown quantity at this point
Thnx blacksquirrel!
I had tried that option too but still wouldn't work. However good news that I managed to sort it out in another way.
I constructed and defined the function k2e_ in the source code.C file as::

k2e_
(
IOobject
(
"k2e",
runtime_.timeName(),
mesh_,
IOobject::MUST_READ,
IOobject::AUTO_WRITE
),
sqr(k_)/epsilonTilda_
),

I also declared it in the header (source_code.H) file as::

volScalarField k2e_;

The expressions were then implemented and used in the part where viscosity is calculated.

And hence in the system/fvSchemes file, I could use::

divSchemes
div(phi,k2e) Gauss upwind;

I appreciate your reply though!!
Cheers!!
nikesh is offline   Reply With Quote

Reply

Thread Tools
Display Modes

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 On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
multiphaseInterFoam for RAS turbulence model chiven OpenFOAM Bugs 7 August 23, 2011 02:52
Problem with turbulence model akonduri OpenFOAM 2 September 17, 2010 00:49
Turbulence model for mixing problem??? nileshjrane Main CFD Forum 7 September 14, 2010 04:57
Centrifugal Pump and Turbulence Model Michiel CFX 12 January 25, 2010 03:20
Fan heater model: what turbulence source to use? andy20 Main CFD Forum 0 March 2, 2008 12:46


All times are GMT -4. The time now is 18:22.