| 查看: 2161 | 回复: 16 | |||
| 当前只显示满足指定条件的回帖,点击这里查看本话题的所有回帖 | |||
[求助]
新手求教UDF问题~
|
|||
|
能解释,但一添加到边界或初始化就报错。 Error: FLUENT received fatal signal (ACCESS_VIOLATION) 1. Note exact events leading to error. 2. Save case/data under new name. 3. Exit program and restart to continue. 4. Report error to your distributor. Error Object: () 我的UDF如下,二维模型,简单的固体传热问题,想在模拟过程的同时累加整个固体区域的所有得热量,达到一定值后改变热流边界值。由于刚接触UDF不久,不知道问题出在何处。请指教!d= Get_Domain(1);这个语句有问题吗? #include "udf.h" real Q_tot=0; DEFINE_PROFILE (unsteady_heatflux, thread, position) { Domain *d; real cp=880; real density=2180; real tempn, templ, volume, Q; Thread *t; cell_t c; d= Get_Domain(1); /*Get the domain using Fluent utility *//*Loop over all cell threads in the domain*/ thread_loop_c(t,d) /*Compute Q */ /*Loop over all cells */ begin_c_loop(c,t) { real time= RP_Get_Real("flow-time" ; real b=(int)(time/3600)+1; int i=(int)((b-1)/24); real Heat[3]={278.5, 280.7, 278.5}; volume=C_VOLUME(c,t); /* get cell volume */ templ=C_T_M1(c,t); /*Get cell tempertuare of previous step*/ tempn=C_T(c,t); /*Get cell tempertuare*/ Q=cp*density*volume*(tempn-templ); Q_tot +=Q; if (Q_tot<= Heat ) F_PROFILE(c,t,position)=60; else F_PROFILE(c,t,position)=0; } end_c_loop(c,t) } |
» 本帖@通知
» 猜你喜欢
各位大神,目前国内有哪些比较好用的逆合成软件?
已经有14人回复
国社科系统bug了,是不是要放榜了?
已经有10人回复
现代”学阀”该如何界定
已经有9人回复
课题组招2027级博士 上海工程技术大学 激光智能制造方向
已经有4人回复
上海工程技术大学 激光智能制造课题组 2027级博士研究生招生
已经有3人回复
上海工程技术大学激光智能制造课题组|2027级博士研究生招生公告
已经有11人回复
上海工程技术大学激光智能制造课题组-博士研究生
已经有10人回复
申博发邮件
已经有11人回复
我的奶奶
已经有3人回复
16楼2012-01-09 19:16:54
wuming524
专家顾问 (著名写手)
石化蛀虫
-

专家经验: +136 - 应助: 147 (高中生)
- 贵宾: 0.016
- 金币: 37295.8
- 红花: 42
- 沙发: 1
- 帖子: 1316
- 在线: 802.6小时
- 虫号: 556258
- 注册: 2008-05-10
- 性别: GG
- 专业: 能源化工
- 管辖: 仿真模拟
2楼2012-01-04 22:06:19
3楼2012-01-04 22:06:24
4楼2012-01-04 22:15:32










;
回复此楼