CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   FLUENT (https://www.cfd-online.com/Forums/fluent/)
-   -   Location of cells (https://www.cfd-online.com/Forums/fluent/37297-location-cells.html)

Short July 17, 2005 07:15

Location of cells
 
Hi all,

I have a simple 2d space and am using this to resolve the energy equation only.

I now want to look at internal distribution of heat flux by writing a udf based on the temp distributions as predicted by fluent.

I have no probelms in resolving the heat flux calculation but I do not know how I can relate the temp to the nodal locations. i.e. I will need to calc the temp gradient and also the spatial difference from the mesh infromation.But I dont know the nodal naming convention so as to write a gradient calc.

Clelary I need to find the nodal temps and also calc a diffence in temp which then gets related to nodal positions.

And so my questions.

How can I 'read' temp[x,y]?

How do I know the location of temp[x,y]

BTW I am thinking of writing a central difference calc for the heat flux, and so this is not possible for the boundaries.

Is it also possible to 'know' when I am at the boundaries so as to apply a 'one-sided' heat flux scheme. In a simple 2d case I guess I use the notion at X=0 or i=1 to indicate I am at a boundary etc. but what about the X=L location. Does fluent have a naming convention for that location?

Thnxs

dirk July 18, 2005 08:43

Re: Location of cells
 
You don't need to calculate the temperature gradients. They can be accessed with C_T_G(c,t)[i]. You just have to activate the storage of these gradients during calculation via TUI with "solve set expert" and then turn on the option "keep temporary solver memory from being freed"

Maybe this helps you, Dirk

Short July 19, 2005 10:38

Re: Location of cells
 
Thankyou. I will explore these macro's.



All times are GMT -4. The time now is 07:12.