| 查看: 3608 | 回复: 7 | ||
[求助]
有关fluent中求specific heat 的UDF编写
|
|
在fluent中模拟流化床,想要用UDF编写相变颗粒Cp随温度变化,因为在这个里面涉及温度变化,所以是cp根据固相的温度变化,固相的id是3,我也不太清楚如何引用固相的温度,我写的代码如下 DEFINE_SPECIFIC_HEAT(specific_heat,cell,thread) { real cp; real temp=C_T(cell, thread); if (temp<318.3) cp = 1457.28; else if(temp>324.6) cp = 1668.7; else cp=1458.3+210.4*(temp-318.3)/6.3; return cp; } 在插入时总是在报错,能否有人能指导一下,或者有这方面的的经验 Error: E:/ansys with heat/Nouveau dossier 1/geometrique_files/dp0/FFF/Fluent/conduct2.c: line 56: parse error. Error: E:/ansys with heat/Nouveau dossier 1/geometrique_files/dp0/FFF/Fluent/conduct2.c: line 59: parse error. Error: E:/ansys with heat/Nouveau dossier 1/geometrique_files/dp0/FFF/Fluent/conduct2.c: line 60: temp: undeclared variable |
» 猜你喜欢
基础研究怎么拉横向,学校到款任务越来越多,难以完成 拉横向,都有哪些途径啊
已经有10人回复
2027年申博
已经有3人回复
一个有机合成实验室都需要哪些设备?
已经有7人回复
2026年国自然面上资助率
已经有20人回复
面上再次挂了,太难了,躺也躺不了,倦也卷不过,小学校之殇!
已经有22人回复
微信指数没变化,科研之友没阅读
已经有18人回复
HXDI做水性聚氨酯乳液,是不是特别容易出渣
已经有3人回复
系统今天又提示维护了,估计离放榜不远了
已经有15人回复
你们的时间戳变了吗
已经有4人回复
产物和副产物价值比较
已经有5人回复
2楼2018-01-20 08:53:05
cheersend
至尊木虫 (著名写手)
- 应助: 74 (初中生)
- 金币: 14567.7
- 红花: 20
- 帖子: 1518
- 在线: 559.5小时
- 虫号: 1496027
- 注册: 2011-11-17
- 专业: 传热传质学
3楼2018-01-20 18:54:35
4楼2018-01-20 19:21:04
5楼2018-01-20 19:22:10

6楼2021-08-23 20:48:07

7楼2021-08-23 20:48:25
Marma_lade
银虫 (小有名气)
- 应助: 1 (幼儿园)
- 金币: 329.9
- 散金: 20
- 沙发: 1
- 帖子: 162
- 在线: 37.2小时
- 虫号: 26958648
- 注册: 2021-08-07
- 性别: MM
- 专业: 燃烧学
|
Tref是指“reference temperature for the enthalpy calculation”, 即计算焓值时的参考温度 yi是指“pointer to array of mass fractions of gas phase species”,即气相组分质量分数的指针 显焓不需要写成积分形式 下面是UDF的例子 /****************************************************************** UDF that computes specific heat and sets the sensible enthalpy to the referenced value * * * * ************************************************************** #include "udf.h" DEFINE SPECIFIC HEAT(my_user_cp, T, Tref, h, yi) { real cp=2000; *h=cp*(T-Tref); return cp; } |
8楼2022-06-16 11:07:38










回复此楼