CFD Online Logo CFD Online URL
Home > Forums > FLUENT

How to access Zone ID using dynamic thread

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

LinkBack Thread Tools Display Modes
Old   November 13, 2008, 03:17
Default How to access Zone ID using dynamic thread
Posts: n/a
Hi I want to get zone ID of a moving boundary in a DEFINE_CG_MOTION macro. I used DT_THREAD and THREAD_ID in my udf but when I printed my results, I got wrong values for zone id. please tell me what is the problem? (note: vel[1] and vel[0] are calculated in previous stages of udf.)

DEFINE_CG_MOTION(motion, dt, cg_vel, cg_omega, time, dtime) {

Thread *t;

int zone;



Message ("ZONE_ID : %g\n",zone);

NV_S(cg_vel, =, 0.0);

NV_S(cg_omega, =, 0.0);

if (zone == 20) /* 20 is a zone ID for a specific

boundary */


cg_vel[0] = vel[1];




cg_vel[0] = vel[0];

} }
  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
UDF- how to look up a dynamic thread (urgent help) itoa Fluent UDF and Scheme Programming 2 February 12, 2016 13:51
problem on dynamic mesh zone erkan FLUENT 2 January 8, 2009 17:01
Zone threads pointing to a certain cell thread Michele FLUENT 0 November 14, 2008 10:44
Zone access - Scheme language cfd_newbie FLUENT 0 April 2, 2008 20:13
Macro to get Thread/Zone Name Abhijeet FLUENT 4 March 31, 2006 11:15

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