CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   FLUENT (https://www.cfd-online.com/Forums/fluent/)
-   -   UDF for DEFINE_EXCHANGE_PROPERTY (https://www.cfd-online.com/Forums/fluent/30352-udf-define_exchange_property.html)

Pravesh Kumar October 2, 2002 05:28

UDF for DEFINE_EXCHANGE_PROPERTY
 
hi In writing UDF For DEFINE_EXCHANGE_PROPERTY I am having three phases.I can't increase the no. of arguments for third phase as it is fixed. Then how can i take into account the third phase.

Help needed.


lohen October 3, 2002 04:57

Re: UDF for DEFINE_EXCHANGE_PROPERTY
 
Hi, you have to declare one thread for one phase :

thread_g=THREAD_SUB_THREAD(mix_thread,f_col); thread_l=THREAD_SUB_THREAD(mix_thread,s_col);

mix_thread is the mixture thread, from what you reach the other phase. f_col and s_col represent the phase which are in the first column and in 2nd column of the table Phase/Interaction in fluent. So you can declare as much as phase as you want.

Have a look in UDF Booklet in Fluent Documentation.

Pravesh Kumar October 3, 2002 11:26

Re: UDF for DEFINE_EXCHANGE_PROPERTY
 
Hi Thanks For your suggestion. I have already gone through the UDF Booklet in Fluent Documentation.

/* find the threads for the gas (primary) and solids (secondary phases) */

thread_g = THREAD_SUB_THREAD(mix_thread, s_col);/* gas phase */ thread_s = THREAD_SUB_THREAD(mix_thread, f_col);/* solid phase*/

For the one more phase(liquid) which will be secondary as there will be only one primary phase should i write? thread_l = THREAD_SUB_THREAD(mix_thread, f_col);

Then f_col will be comon for both solid and liquid phase.Is this right approach?

Waiting for your suggestion. Thanks

lohen October 4, 2002 09:03

Re: UDF for DEFINE_EXCHANGE_PROPERTY
 
Hi, look in fluent the table, in the menu Define/Phases/Interaction to see which phase is in the fist column and in the 2nd one. if your secondary liquid is in the first column then thread_l = THREAD_SUB_THREAD(mix_thread, f_col); is correct. Anyway, I think fluent considers interaction between secondary phases and primary phases first and after interactions between secondary phases.

Ciao

Pravesh Kumar October 7, 2002 01:20

Re: UDF for DEFINE_EXCHANGE_PROPERTY
 
hi Thanks!! Hopefully it will work out. How to print the values of exchange terms from UDF to cross-check it with hand calculation to verify that they are giving correct values.

Waiting for your suggestions.



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