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

UDF: wick-vapor interface

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   June 13, 2020, 04:36
Default UDF: wick-vapor interface
  #1
Senior Member
 
Arun raj.S
Join Date: Jul 2011
Posts: 207
Rep Power: 16
arunraj is on a distinguished road
Can such a UDF help me to apply source term only on the interior face ? I really believe someone can provide some idea. Thank you.

#include "udf.h"

DEFINE_SOURCE(mass_flux,c,t,dS,eqn)
{
real x[ND_ND];
real source = 0.;

C_CENTROID(x,c,t);
dS[eqn] = 0.; // derivative of source term

{
if (x[O] >= 0 && x[1] <= 0.6 && x[1] = 0.00865) // evaporation section: only if this cell belongs in the domain where 0 < x > 0.6 m and y = 0.00865
{
source = -0.13305902;
}
elseif ((0.69 < x[1] && x[1] < 0.89) && (x[1] = 0.00865)) // condenseor section: only if this cell belongs in the domain where 0 < x > 0.6 m and y = 0.00865
{
source = 0.13305902;
}
else
{
source = 0;
}
}
}
arunraj is offline   Reply With Quote

Reply


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
udf for one dimensional linear motion based on force maccheese Fluent UDF and Scheme Programming 2 September 1, 2019 03:18
Save output of udf in another udf! JuanJoMex FLUENT 0 February 8, 2018 13:43
UDF Compilation Error - Loading Library - COMMON Problem! Help! robtheslob Fluent UDF and Scheme Programming 8 July 24, 2015 01:53
UDF parallel error: chip-exec: function not found????? shankara.2 Fluent UDF and Scheme Programming 1 January 16, 2012 23:14
UDF, UDF, UDF, UDF Luc SEMINEL Main CFD Forum 0 November 25, 2002 05:01


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