UDF Cavitation problems: Error: chip-exec: function "mass_source_init::libudf" not fo
I try to implement UDF:
DEFINE_CAVITATION_RATE The udf: /************************************************** ********************* UDF that is an example of a cavitation model different from default. Can be interpreted or compiled. ************************************************** **********************/ #include "udf.h" #define c_evap 1.0 #define c_con 0.1 DEFINE_CAVITATION_RATE(c_rate,c,t,p,rhoV,rhoL,mafV ,p_v,cigma,f_gas, m_dot) { real p_vapor = *p_v; real dp, dp0, source; p_vapor += MIN(0.195*C_R(c,t)*C_K(c,t), 5.0*p_vapor); dp = p_vapor - ABS_P(p[c], op_pres); dp0 = MAX(0.1, ABS(dp)); source = sqrt(2.0/3.0*rhoL[c])*dp0; if(dp > 0.0) *m_dot = c_evap*rhoV[c]*source; else *m_dot = -c_con*rhoL[c]*source; } After compilation I see announcement: Creating user_nt.udf file for 3d ... (system "copy "C:\PROGRA~1\ANSYSI~1\v145\fluent"\fluent14.5.0\sr c\makefile_nt.udf "libudf\ntx86\3d\makefile" ") Liczba skopiowanych plik˘w: 1. (chdir "libudf")() (chdir "ntx86\3d")() # Generating ud_io1.h c_rate1.c # Generating udf_names.c because of makefile c_rate1.obj udf_names.c # Linking libudf.dll because of makefile user_nt.udf udf_names.obj c_rate1.obj Microsoft (R) Incremental Linker Version 9.00.30729.01 Copyright (C) Microsoft Corporation. All rights reserved. Creating library libudf.lib and object libudf.exp Done. During calculation: Error: chip-exec: function "mass_source_init::libudf" not found. Error: chip-exec: function "singhal_fluent::libudf" not found. iter continuity x-velocity y-velocity z-velocity k epsilon vf-water-vap time/iter Error: chip-exec: function "mass_source_adjust::libudf" not found. Error: chip-exec: function "singhal_fluent::libudf" not found. Where is the problem? |
I have no problem with your compiled udf.
Turn on the Singhal et al cavitation model (in fluent command window, solve-->set-->expert), retain all defaults and change to yes to use the Singhal model. Then compile the udf and hook the udf in function hooks in cavitation mass rate. Daniele |
Thank you very much, now it's working, but I don't have the results, that I expected. Nothing has happend, there is no vapour in my model and I don't know why. I compared with the Zwart model, which is in Fluent and in this solutions I see vapour.
|
All times are GMT -4. The time now is 20:08. |