CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   Phoenics (https://www.cfd-online.com/Forums/phoenics/)
-   -   how to set the density (https://www.cfd-online.com/Forums/phoenics/51548-how-set-density.html)

xqy January 11, 2003 04:01

how to set the density
 
Hi all

how to set the flow density when it comes to the energy equation, because in my problem, the density of the energy equation is different from density in the momentum equation of the convertive term.

so when comes to solve the energy equation, it need change the flow density to suitable one.

can anybody tell me how to set it in PHOENICS.

thanks in advance

cham January 14, 2003 12:09

Re: how to set the density
 
Set UCONV=T to access and modify the convection terms directly for the energy equation in Group 8 of GROUND. If you are solving for energy in terms of H1, then you will probably need to set UDIFF=T as well so as to access and modify the diffusion terms for H1 in Group 8 of GROUND.

xqy January 16, 2003 01:53

Re: how to set the density
 
Can you provide me an example about how to set it? I didn't know how to set it in ground yet.

if possible, please mail me at xingqiuyuan@yahoo.com.cn thanks in advance.

cham January 20, 2003 06:06

Re: how to set the density
 
In the Q1 file set UCONV=T.

In Group 8 Section 8 of GROUND you will need to introduce logic along the lines:

if(indvar.eq.h1) then

if(ndirec.eq.6) then c... modify low convection coefficients for h1 c... which are defined by the index LD2

else if(ndirec.eq.5) then c... modify high convection coefficients for h1 c... which are defined by the index LD2

else if(ndirec.eq.3) then c... modify east/west convection coefficients for h1 c which are defined by the indices LD11 (east) c and LD12 (west)

else if(ndirec.eq.1) then c... modify north/south convection coefficients for h1 c which are defined by the indices LD11 (north) c and LD12 (south)

endif endif

In each of the above sections you will need to scale the prevailing convection coefficients (stored in LD11, etc) with the appropriate density ratio and then then set the modified coefficients in LD11, etc. For an example of such coding, look at the file c:\phoenics\d_earth\d_core\gxconvec.for.



All times are GMT -4. The time now is 20:26.