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

UDF, Looping through threads or faces

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

Reply
 
LinkBack Thread Tools Display Modes
Old   June 20, 2005, 13:35
Default UDF, Looping through threads or faces
  #1
Zhang
Guest
 
Posts: n/a
Suppose I saved a UDM (User Defined Memory) variable in each face. Then I loop over the threads and faces to find the minimal of that variable: thread_loop_f(t, domain) {

begin_f_loop(f, t)

{

/* find and record the thread and face where the minimal exists */

tt = t;

ff = f;

}

end_f_loop(f,t) }

Here tt and ff are the same type as t and f, respectively. I am trying to use tt and ff to record the interested face and want to use them out of the loop. But it did not work. Is it because that "Thread *" and "face_t" are not like Integer of Real and they can not be assigned to another variable directly? Anybody has done similar thing and any suggestion? Thanks,

Zhang
  Reply With Quote

Old   June 21, 2005, 01:24
Default Re: UDF, Looping through threads or faces
  #2
Joey
Guest
 
Posts: n/a
Can you do what you want within the loop using the "if........else"? I have not faced such problems. Can user define a global variables in UDF or just a UDF "global" variables.? I'm interesting in it. Could you email to me and tell me something detail?

Joey

  Reply With Quote

Reply

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
snappyHexMesh won't work - zeros everywhere! sc298 OpenFOAM Native Meshers: snappyHexMesh and Others 2 March 27, 2011 21:11
Dynamic Mesh UDF Qureshi FLUENT 1 December 2, 2009 01:27
BlockMeshmergePatchPairs hjasak OpenFOAM Native Meshers: blockMesh 11 August 15, 2008 07:36
DEFINE_DPM_OUTPUT macro UDF HELP Puneet FLUENT 3 November 28, 2003 11:55
Loop over the faces of a cell in UDF Anthony Wachs FLUENT 4 October 16, 2001 10:55


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