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

Dependency of diffusivity from temperature

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

Reply
 
LinkBack Thread Tools Display Modes
Old   May 30, 2012, 03:33
Default Dependency of diffusivity from temperature
  #1
New Member
 
Join Date: May 2012
Posts: 1
Rep Power: 0
zhc_ykt is on a distinguished road
Hi,

I try to modify laplacianFoam solver and make depency of DT from temperature. Something like this:

if T>0 then DT=0.56 else DT=2.21.

Taking a temperature from previous time layer is ok. But i don't understand how to make OpenFoam fill each value of dimensionedScalar from respective value of calculated T.
zhc_ykt is offline   Reply With Quote

Old   May 30, 2012, 03:53
Default
  #2
Senior Member
 
Nima Sam
Join Date: Sep 2009
Location: Tehran, Iran
Posts: 1,123
Blog Entries: 1
Rep Power: 14
nimasam is on a distinguished road
Send a message via Yahoo to nimasam
some thing like this:

Code:
forAll (T, celli)
{
if (T[celli] > 0)
{
DT[celli] =0.56;
}
else
{
DT[celli] =2.21; 
}

}
P.S
you should change diffusivity definition from dimensionedScalar into VolScalarField
nimasam 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
swak4foam building problem GGerber OpenFOAM Installation 54 April 24, 2015 16:02
Calculation of the Governing Equations Mihail CFX 7 September 7, 2014 06:27
friction forces icoFoam ofslcm OpenFOAM 3 April 7, 2012 10:57
OpenFOAM on MinGW crosscompiler hosted on Linux allenzhao OpenFOAM Installation 127 January 30, 2009 20:08
DecomposePar links against liblamso0 with OpenMPI jens_klostermann OpenFOAM Bugs 11 June 28, 2007 17:51


All times are GMT -4. The time now is 16:25.