| 查看: 1074 | 回复: 1 | ||
[求助]
关于udf 变量梯度的问题 已有1人参与
|
|
请问 { Alloc_Storage_Vars(pDomain,SV_VOF_RG,SV_VOF_G,SV_NULL); Scalar_Reconstruction(pDomain, SV_VOF,-1,SV_VOF_RG,NULL); Scalar_Derivatives(pDomain,SV_VOF,-1,SV_VOF_G,SV_VOF_RG,Vof_Deriv_Accumulate); } { Alloc_Storage_Vars(domain, SV_T_RG, SV_T_G, SV_NULL); T_derivatives(domain); 这里面的变量什么意思 该如何修改 /**************************************************************/ /* UDF for specifying an interfacail area density */ /**************************************************************/ DEFINE_ADJUST(area_density, domain) { Thread *t; Thread **pt; cell_t c; Domain *pDomain = DOMAIN_SUB_DOMAIN(domain,P_PHASE); real voidx, voidy, voidz=0; { Alloc_Storage_Vars(pDomain,SV_VOF_RG,SV_VOF_G,SV_NULL); Scalar_Reconstruction(pDomain, SV_VOF,-1,SV_VOF_RG,NULL); Scalar_Derivatives(pDomain,SV_VOF,-1,SV_VOF_G,SV_VOF_RG,Vof_Deriv_Accumulate); } { Alloc_Storage_Vars(domain, SV_T_RG, SV_T_G, SV_NULL); T_derivatives(domain); Free_Storage_Vars(domain, SV_T_RG, SV_NULL); } mp_thread_loop_c (t,domain,pt) if (FLUID_THREAD_P(t)) { Thread *tp = pt[P_PHASE]; begin_c_loop (c,t) { #if RP_3D C_UDMI(c,t,0) = (C_VOF_G(c,tp)[0]*C_T_G(c,t)[0]+C_VOF_G(c,tp)[1]*C_T_G(c,t)[1]+C_VOF_G(c,tp)[2]*C_T_G(c,t)[2]); #endif #if RP_2D C_UDMI(c,t,0) = (C_VOF_G(c,tp)[0]*C_T_G(c,t)[0]+C_VOF_G(c,tp)[1]*C_T_G(c,t)[1]); #endif } end_c_loop (c,t) } Free_Storage_Vars(pDomain,SV_VOF_RG,SV_VOF_G,SV_NULL); Free_Storage_Vars(domain, SV_T_G, SV_NULL); } |
» 猜你喜欢
材料调剂
已经有4人回复
面上模板改不了页边距吧?
已经有6人回复
307求调剂
已经有6人回复
304求调剂
已经有5人回复
317一志愿华南理工电气工程求调剂
已经有8人回复
272求调剂
已经有3人回复
化工专硕348,一志愿985求调剂
已经有6人回复
292求调剂
已经有3人回复
290求调剂
已经有6人回复
295求调剂
已经有5人回复
感谢参与,应助指数 +1
月只蓝: 应助指数-2, 屏蔽内容, 刷应助指数,无意义应助! 2017-03-24 11:11:32
月只蓝: 应助指数-2, 屏蔽内容, 刷应助指数,无意义应助! 2017-03-24 11:11:32
|
本帖内容被屏蔽 |
2楼2016-08-04 08:43:02













回复此楼