24小时热门版块排行榜    

查看: 678  |  回复: 2

凯仂

铜虫 (小有名气)


[交流] FLUENT DUF DEFINE_INIT 导入不能初始化

fluent模拟流化床传热传质,编程设定初始的颗粒湿度,并计算求得空气的相对湿度,但是一导进去一点初始化就出现错误,DEFINE_INIT去掉以后可以初始化,求高手帮忙解决这个问题...
#include "udf.h"
/* Heat and moisture transfer in bulks of grains */
/* Graham Thorpe */
/* Victoria University, Melbourne, Australia */
/* Chung-Pfost constants */
#define ACP 921.69
#define BCP 18.077
#define CCP 112.35
#define RHOB 639.2
#define PATM 101325
/* Define ambient temperature conditions */
#define TMEAN 288.15
/* Define a global variable that acts as a comparitor in DEFINE_ADJUST */
int last_ts = -1;
DEFINE_INIT(moisure_init,d)
/* The initial solids moisture content, W, is set */
/* and the corresponding humidity, w, of the  intergranular air is calculated */
{
cell_t c;
Thread *t;
real W,Tabs,TC,r,psat,p,w;
/* Loop over all of the cell threads in the bulk of grain */
thread_loop_c(t,d)
{
begin_c_loop(c,t)
{
C_UDMI(c,t,0) = 0.1364;
W = C_UDMI(c,t,0);
Tabs = C_T(c,t);
TC = Tabs-273.15;
/* Calculate relative humidity of intergranular air */
r = exp(-ACP/(TC+CCP)*exp(-BCP*W));
/* Ensure the air does not become supersaturated */
if (r>0.99)
{r = 0.99;}
psat = 6.0e25/pow(Tabs,5) *exp(-6800/Tabs);
p = r*psat;
w = 0.622*p/(PATM-p); /* Eqn 12 */
C_UDSI(c,t,0) = w;
}
end_c_loop(c,t);
}
}
FLUENT DUF DEFINE_INIT 导入不能初始化
_ISCN{O85`GZ`[81Y69R~}M.jpg
回复此楼

» 猜你喜欢

» 本主题相关价值贴推荐,对您同样有帮助:

» 抢金币啦!回帖就可以得到:

查看全部散金贴

已阅   回复此楼   关注TA 给TA发消息 送TA红花 TA的回帖

gyctju

金虫 (著名写手)


★ ★
凯仂(金币+1): 谢谢参与
xiegangmai: 金币+1, 谢谢参与! 2013-06-02 10:41:38
定义udm了吗?
2楼2013-05-29 14:31:21
已阅   回复此楼   关注TA 给TA发消息 送TA红花 TA的回帖

凯仂

铜虫 (小有名气)


引用回帖:
2楼: Originally posted by gyctju at 2013-05-29 14:31:21
定义udm了吗?

umd 是define/uers-define/memory里边设置的UDM数目吗?是的话就是定义了...
3楼2013-05-29 14:40:48
已阅   回复此楼   关注TA 给TA发消息 送TA红花 TA的回帖
相关版块跳转 我要订阅楼主 凯仂 的主题更新
普通表情 高级回复 (可上传附件)
最具人气热帖推荐 [查看全部] 作者 回/看 最后发表
[基金申请] 欢迎发来filecode的Mz6后的代码验证其规律 +31 医学老男孩 2026-08-13 69/3450 2026-08-16 00:16 by mo_mo_mo_mo
[基金申请] 有时候,自然基金真的不能太认真 (我的申报经验) +9 majunge000 2026-08-11 11/550 2026-08-15 23:20 by botar
[基金申请] 时间戳又变了8-15 +12 archvillain 2026-08-15 23/1150 2026-08-15 20:47 by foyo404
[基金申请] filecode +8 cratir 2026-08-14 12/600 2026-08-15 18:08 by zyfgau
[基金申请] 小木虫上这么多卖论文的,真有人买论文么?感觉没必要啊 +12 Tide man 2026-08-10 13/650 2026-08-15 16:34 by 氺木
[基金申请] 哪位老哥知道今年的国自然具体哪一天放榜? +7 Ldrop2023 2026-08-13 7/350 2026-08-15 15:57 by mzhh2000
[基金申请] 各位道友,我要去昆明玩几天,回来见。 +7 Tide man 2026-08-14 8/400 2026-08-15 01:11 by arzu_hma
[基金申请] 咱们一起用铁证分析2026国家社科基金中标与否 +7 启萌科技 2026-08-12 22/1100 2026-08-14 23:45 by Noways
[硕博家园] 请教兼职经验 +3 是阿文鸭 2026-08-09 3/150 2026-08-14 12:07 by HER12025
[硕博家园] 读博的好处 +4 lnee 2026-08-11 4/200 2026-08-14 10:20 by ahsoarli
[基金申请] filecode +15 documentary 2026-08-10 17/850 2026-08-14 10:08 by kissu88
[基金申请] 重要来源:本周末出结果 +10 瞬息宇宙 2026-08-12 10/500 2026-08-13 15:46 by likettle
[基金申请] 不应该看fileCode +7 且听虎啸 2026-08-12 9/450 2026-08-13 14:27 by flydreamws
[基金申请] 分享一下我之前已中青C的计划书的filecode +4 布布和一二 2026-08-11 5/250 2026-08-13 12:56 by cratir
[基金申请] 综述论文作为代表作会不会影响评审专家的印象分? +11 yufeiwaner 2026-08-09 13/650 2026-08-12 08:17 by yufeiwaner
[基金申请] 帮忙看看fileCode +7 wwncly 2026-08-10 13/650 2026-08-11 19:36 by 冰心玉壶晴
[基金申请] 为什么网上很多人说本周 12号出结果 +6 瞬息宇宙 2026-08-10 7/350 2026-08-11 19:25 by Tide man
[基金申请] 什么时候出结果,有咨询渠道??? +3 Tide man 2026-08-11 3/150 2026-08-11 17:54 by kudofaye
[基金申请] 确定了,国自然21号放榜 +6 布布和一二 2026-08-10 7/350 2026-08-10 19:15 by 2000zf36392
[基金申请] 据悉今年马上要出结果了 +7 瞬息宇宙 2026-08-10 8/400 2026-08-10 12:42 by Vivilian
信息提示
请填处理意见