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

Question about UDF

Register Blogs Community New Posts Updated Threads Search

 
 
LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
Old   July 17, 2006, 15:49
Default Question about UDF
  #1
summer
Guest
 
Posts: n/a
Hello, everyone. Now I am writing a UDF to define the source term in UDS. I have the unsteady term defined as follows: DEFINE_UDS_UNSTEADY(uns_time,c,mix_thread,i,apu,su ) { cell_t c; Thread *mix_thread; real physical_dt; int i=0;

/*find the threads for the gas-bubble(secondary phase)*/ thread_g=THREAD_SUB_THREAD(mix_thread,s_col); /*secondary phase*/

void_g=C_VOF(c,thread_g); /*gas volume fraction*/

physical_dt=RP_Get_Real("physical-time-step");

*apu=-1/3*void_g/physical_dt; /*implicit part*/ phi_old=C_STORAGE_R(c,thread_g,SV_VOF_M1(i)); *su=1/3*phi_old/physical_dt; /*explicit part*/ } And then I want to use it in another macro called DEFINE_SOURCE in the same c file. Could I use apu and su directly? Need I use the User-defined Memory to store them first? Thanks in advance.
  Reply With Quote

 


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
A simple UDF question Pirooz Darabi FLUENT 0 October 31, 2007 15:22
Yet another UDF question. Bee FLUENT 0 October 9, 2006 03:46
Basic question: UDF for wall heat flux Carl FLUENT 1 August 5, 2006 19:01
UDF question Ryan FLUENT 2 July 5, 2006 14:54
A question about the dynamic mesh UDF Tango FLUENT 1 November 27, 2003 02:56


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