CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > ANSYS > FLUENT

How to use UDF about adjacent cell ?

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   January 31, 2018, 03:38
Cool How to use UDF about adjacent cell ?
  #1
New Member
 
JuBong
Join Date: Jan 2018
Posts: 16
Rep Power: 8
JuBong is on a distinguished road
In a square module with one cell of 0.001 m2, if the temperature T1 at the inlet is a function of T2 (the temperature of the next cell in the direction of exit), how to use UDF code to express T1 (y) = T2 (y) + 100 ?


example

#include "udf.h"
DEFINE_PROFILE(temperature, thread, position)
{
real x[ND_ND];
real y;
face_t f;
C_T(c,t);

begin_f_loop(f, thread)
{
F_CENTROID(x,f,thread);
y = x[1];
F_PROFILE(f, thread, position) = C_T(c,t) + 100;
}
end_f_loop(f, thread)
}
JuBong is offline   Reply With Quote

Reply

Tags
udf code, udf temperature


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


Similar Threads
Thread Thread Starter Forum Replies Last Post
[Other] refineWallLayer Error Yuby OpenFOAM Meshing & Mesh Conversion 2 November 11, 2021 12:04
cell wall distance using C_WALL_DIST(c,t) or other udf zhixin Fluent UDF and Scheme Programming 11 April 18, 2016 11:17
Using UDF in fuel cell addon module qwe2077 FLUENT 5 February 12, 2015 04:25
how to find the index of the adjacent cell of one cell? jing113cn Fluent UDF and Scheme Programming 2 July 8, 2010 04:26
Adjacent cell number Jing Siemens 5 October 21, 2002 07:29


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