| 查看: 661 | 回复: 2 | ||
[求助]
FLUENT 6.3帮助文档 ADJUST宏例2的疑惑 已有1人参与
|
|
大家一定对这个例子不陌生 The following UDF, namedadjustfcn, species a user-dened scalar as a function of the gradient of another user-dened scalar, using DEFINE_ADJUST. The function is called once every iteration. It is executed as a compiled UDF inFLUENT. /******************************************************************** UDF for defining user-defined scalars and their gradients *********************************************************************/ #include "udf.h" DEFINE_ADJUST(adjust_fcn,d) { Thread *t; cell_t c; real K_EL = 1.0; /* Do nothing if gradient isn't allocated yet. */ if (! Data_Valid_P()) return; thread_loop_c(t,d) { if (FLUID_THREAD_P(t)) { begin_c_loop_all(c,t) { C_UDSI(c,t,1) += K_EL*NV_MAG2(C_UDSI_G(c,t,0))*C_VOLUME(c,t); } end_c_loop_all(c,t) } } } 我的疑问是,这样定义出来的UDS(i=1)有什么实际的作用吗,还有C_UDSI(c,t,1)值已经确定的话,那UDS(i=1)的方程难道不用求解了? |
» 猜你喜欢
遇见不省心的家人很难过
已经有16人回复
退学或坚持读
已经有25人回复
博士延得我,科研能力直往上蹿
已经有4人回复
免疫学博士有名额,速联系
已经有14人回复
面上基金申报没有其他的参与者成吗
已经有4人回复
多组分精馏求助
已经有6人回复

2楼2014-03-04 08:59:05
|
本帖内容被屏蔽 |
3楼2015-12-09 19:33:24













回复此楼