|
|
马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。
您需要 登录 才可以下载或查看,没有账号?注册
x
fluent做Axisymmetric Swirl模拟流体流动,自己编写UFD初始温度场。。在载入的时候老是提示错误,新手,不知道哪里有问题。。
#include "udf.h"
DEFINE_INIT(initial_temp_field,domain)
{ cell_t c;
Thread *t;
domain=Get_Domain(1);
real xc[ND_ND];
/*loop over all cell threads in the domain*/
thread_loop_c (t,domain)
{
begin_c_loop_all(c,t)
{
C_CENTROID(xc,c,t);
if (xc[0]<=25.5)
C_T(c,t)=2.81*xc[0]+211;
else
if (25.5<xc[0]<61)
C_T(c,t)=5.668*xc[0]+210;
else
if (61<=xc[0]<=96.5)
C_T(c,t)=-5.09*xc[0]+217;
else
C_T(c,t)=-12.367*xc[0]+224;
}
end_c_loop_all(c,t);
}
}
提示line9:parse error.
line 17:xc:undeclared variable
怎么回事。。 |
|