CFD Online Logo CFD Online URL
Home > Forums > Fluent UDF and Scheme Programming

Calculate averaged value (mass- or area-weighted) on type:interior boundary conditio

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

LinkBack Thread Tools Display Modes
Old   June 25, 2012, 09:36
Default Calculate averaged value (mass- or area-weighted) on type:interior boundary conditio
New Member
George B.
Join Date: Nov 2011
Location: United Kingdom
Posts: 2
Rep Power: 0
jorbuiga is on a distinguished road
I would like to calculate the averaged value for some properties (temperature, pressure, viscosity, x-velocity, velocity magnitude, etc) for the boundary condition type:interior (for mass-flow inlet or pressure-outlet works fine). I was trying to get the values for the cell (e.g. the temperature of the cell) but it is not available by using my code :

#include "udf.h"

// firstly I intend to calculate the sum of the temperature values
real sum_temp=0;

Domain *d;
cell_t c;
face_t f;
Thread *t;
int ID_int = 27; //here I know the ID for the type:interior = 27
d = Get_Domain(1);
t = Lookup_Thread(d,ID_face_int);


printf( "\n Tsum in type:interior %d is [in K]: %f \n",ID_int,sum_temp);


Thanks a lot in advance.
jorbuiga is offline   Reply With Quote


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
mass & area average henry CFX 8 September 30, 2016 03:26
Area weighted or mass weighted average SAM Main CFD Forum 24 July 8, 2015 06:15
How to calculate the mass fraction of species in Fluent? llrr FLUENT 0 May 21, 2010 04:41
Facet, Area and Mass Average in Fluent Tushar Main CFD Forum 0 February 4, 2009 05:37
Can Tecplot calculate isosurface area alon axis x? leaf Tecplot 0 May 21, 2007 12:20

All times are GMT -4. The time now is 00:53.