| 2 | 1/1 | 返回列表 |
| 查看: 1077 | 回復: 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); } |
|
本帖內(nèi)容被屏蔽 |
| 2 | 1/1 | 返回列表 |
| 最具人氣熱帖推薦 [查看全部] | 作者 | 回/看 | 最后發(fā)表 | |
|---|---|---|---|---|
|
[考研] 297求調(diào)劑 +10 | 田洪有 2026-03-26 | 10/500 |
|
|---|---|---|---|---|
|
[考研] 327求調(diào)劑 +4 | 汲亦昊 2026-03-29 | 4/200 |
|
|
[考研] 一志愿北京理工大學本科211材料工程294求調(diào)劑 +7 | mikasa的圍巾 2026-03-28 | 7/350 |
|
|
[考研] 085600,專業(yè)課化工原理,321分求調(diào)劑 +5 | 大饞小子 2026-03-28 | 5/250 |
|
|
[考研] 求調(diào)劑 +7 | 爭取九點睡 2026-03-28 | 8/400 |
|
|
[考研] 083000學碩274求調(diào)劑 +8 | Li李魚 2026-03-26 | 8/400 |
|
|
[考研] 283求調(diào)劑 +3 | A child 2026-03-28 | 3/150 |
|
|
[考研] 化學0703 調(diào)劑 306分 一志愿211 +4 | 26要上岸 2026-03-28 | 4/200 |
|
|
[考研] 材料277求調(diào)劑 +7 | min3 2026-03-24 | 7/350 |
|
|
[考研] 315分求調(diào)劑 +7 | 26考研上岸版26 2026-03-26 | 7/350 |
|
|
[考研] 305求調(diào)劑 +5 | 哇盧卡庫 2026-03-26 | 5/250 |
|
|
[考研] 一志愿陜師大生物學071000,298分,求調(diào)劑 +5 | SYA! 2026-03-23 | 5/250 |
|
|
[考研] 325求調(diào)劑 +3 | Aoyijiang 2026-03-23 | 3/150 |
|
|
[考研] 材料與化工304求B區(qū)調(diào)劑 +3 | 邱gl 2026-03-26 | 6/300 |
|
|
[考研] 材料科學與工程 317求調(diào)劑 +4 | JKSOIID 2026-03-26 | 4/200 |
|
|
[考研] 303求調(diào)劑 +6 | 藍山月 2026-03-25 | 6/300 |
|
|
[考研] 機械學碩總分317求調(diào)劑。。。 +4 | Acaciad 2026-03-25 | 4/200 |
|
|
[考研] 284求調(diào)劑 +15 | Zhao anqi 2026-03-22 | 15/750 |
|
|
[考研] 材料專碩找調(diào)劑 +5 | 哈哈哈吼吼吼哈 2026-03-23 | 5/250 |
|
|
[考研] 材料專碩331求調(diào)劑 +4 | 鮮當牛 2026-03-24 | 4/200 |
|