| 5 | 1/1 | 返回列表 |
| 查看: 4263 | 回復: 14 | |||
| 當前只顯示滿足指定條件的回帖,點擊這里查看本話題的所有回帖 | |||
clytze9064銅蟲 (初入文壇)
|
[求助]
Ansys Fluent 編譯UDF及加載UDF出現(xiàn)錯誤 已有1人參與
|
||
|
用UDF編寫模型邊界條件,編譯時,出現(xiàn)以下錯誤: Copied E:\XY\ev_thermal_conditions2.c to E:\XY\QIU_files\dp0\FFF\Fluent\libudf\src udf_names.c and user_nt.udf files in 3d are upto date. (system "copy "D:\ANSYSI~1\v150\fluent"\fluent15.0.0\src\makefile_nt.udf "E:\XY\QIU_files\dp0\FFF\Fluent\libudf\ntx86\3d\makefile" " ![]() 已復制 1 個文件。 (chdir "E:\XY\QIU_files\dp0\FFF\Fluent\libudf" (chdir "ntx86\3d" # Generating ud_io1.hev_thermal_conditions2.c C:\Program Files\Microsoft Visual Studio 10.0\VC\INCLUDE\crtdefs.h(402) : error C2371: “size_t”: 重定義;不同的基類型 ..\..\src\ev_thermal_conditions2.c : 參見“size_t”的聲明 ..\..\src\ev_thermal_conditions2.c(280) : error C2440: “函數(shù)”: 無法從“real (*)(real)”轉換為“double” ..\..\src\ev_thermal_conditions2.c(280) : warning C4024: “pow”: 形參和實參 1 的類型不同 Done. 強行加載時,出現(xiàn)以下錯誤: Opening library "E:\XY\QIU_files\dp0\FFF\Fluent\E:\XY\QIU_files\dp0\FFF\Fluent\libudf"... Error: The UDF library you are trying to load (E:\XY\QIU_files\dp0\FFF\Fluent\libudf) is not compiled for 3d on the current platform (ntx86). 系統(tǒng)找不到指定的文件。 E:\XY\QIU_files\dp0\FFF\Fluent\E:\XY\QIU_files\dp0\FFF\Fluent\libudf\\ntx86\3d\libudf.dll Error: The UDF library you are trying to load (E:\XY\QIU_files\dp0\FFF\Fluent\libudf) is not compiled for 3d on the current platform (ntx86). 系統(tǒng)找不到指定的文件。 E:\XY\QIU_files\dp0\FFF\Fluent\E:\XY\QIU_files\dp0\FFF\Fluent\libudf\ntx86\3d\libudf.dll Error Object: #f 環(huán)境變量已經(jīng)設置好,輸入cl.exe,已經(jīng)沒問題,還是出現(xiàn)以上錯誤,糾結了好幾天了,求大神相助。謝謝。。。。! |
專家顧問 (著名寫手)
![]() |
專家經(jīng)驗: +60 |
專家顧問 (著名寫手)
![]() |
專家經(jīng)驗: +60 |
銅蟲 (初入文壇)
|
謝謝!源程序太長,以下是編譯時出現(xiàn)第二個錯誤(error C2240)的地方,第一個error應該不是程序的問題,但也不知道為什么頭文件會出問題,程序中也沒有size_t這個變量。 DEFINE_PROFILE(heat_transfer_coef,t,i) { real A[ND_ND]; /* this will hold the normal vector */ real h, Tw, total_AT, total_area, area; face_t f; total_AT = 0.0; /* sum of A*T */ total_area = 0.0; /* sum of area */ #if !RP_HOST begin_f_loop(f,t) { F_AREA(A,f,t); area = NV_MAG(A); total_area += area; total_AT += area * F_T(f,t); } end_f_loop(f,t) #if RP_NODE total_AT = PRF_GRSUM1(total_AT); total_area = PRF_GRSUM1(total_area); #endif Tw = total_AT / total_area; h = pow(pow(h_fc,3) + pow(htc_nc(Tw),3), 0.333); #endif Message("Tw = %lf, h = %lf\n", Tw, h); begin_f_loop(f,t) { F_PROFILE(f,t,i) = h; } end_f_loop(f,t) } |
專家顧問 (著名寫手)
![]() |
專家經(jīng)驗: +60 |
| 最具人氣熱帖推薦 [查看全部] | 作者 | 回/看 | 最后發(fā)表 | |
|---|---|---|---|---|
|
[考研] 275求調(diào)劑 +15 | Micky11223 2026-03-25 | 20/1000 |
|
|---|---|---|---|---|
|
[考研] 343求調(diào)劑085601 +3 | 要努力學習x 2026-03-29 | 3/150 |
|
|
[考研] 08工科求調(diào)劑286 +3 | tgs_001 2026-03-28 | 3/150 |
|
|
[考研] 329求調(diào)劑,一志愿西北工業(yè)大學,材料工程(085601) +4 | 小小機靈蟲 2026-03-29 | 10/500 |
|
|
[考研] 本科雙非材料,跨考一志愿華電085801電氣,283求調(diào)劑,任何專業(yè)都可以 +6 | 芝士雪baoo 2026-03-28 | 8/400 |
|
|
[考研] 356求調(diào)劑 +3 | gysy?s?a 2026-03-28 | 3/150 |
|
|
[考研] 322求調(diào)劑 +7 | 宋明欣 2026-03-27 | 7/350 |
|
|
[考研] 求調(diào)劑 +7 | 爭取九點睡 2026-03-28 | 8/400 |
|
|
[考研] 材料與化工(0856)304求B區(qū)調(diào)劑 +8 | 邱gl 2026-03-27 | 8/400 |
|
|
[考研] 283求調(diào)劑 +7 | A child 2026-03-28 | 7/350 |
|
|
[考研] 085404求調(diào)劑,總分309,本科經(jīng)歷較為豐富 +4 | 來財aa 2026-03-25 | 4/200 |
|
|
[考研] 265求調(diào)劑11408 +3 | 劉小鹿lu 2026-03-27 | 3/150 |
|
|
[考研] 復試調(diào)劑,一志愿南農(nóng)083200食品科學與工程 +5 | XQTJZ 2026-03-26 | 5/250 |
|
|
[考研] 化學308分求調(diào)劑 +8 | 你好明天你好 2026-03-23 | 9/450 |
|
|
[考研]
|
鐘llll 2026-03-26 | 4/200 |
|
|
[考研] 317求調(diào)劑 +7 | 蛋黃咸肉粽 2026-03-26 | 7/350 |
|
|
[考研] 機械學碩310分,數(shù)一英一,一志愿211本科雙非找調(diào)劑信息 +3 | @357 2026-03-25 | 3/150 |
|
|
[考研] 0854人工智能方向招收調(diào)劑 +4 | 章小魚567 2026-03-24 | 4/200 |
|
|
[考研]
|
13659058978 2026-03-24 | 4/200 |
|
|
[考研] 269求調(diào)劑 +4 | 我想讀研11 2026-03-23 | 4/200 |
|