It's really strange, I have compiled the udf and the compiler tells me this :
udf_final_velocity_check.c: In function ‘some_func’: udf_final_velocity_check.c:6: warning: excess elements in array initializer udf_final_velocity_check.c:6: warning: (near initialization for ‘r0’) udf_final_velocity_check.c:7: warning: excess elements in array initializer udf_final_velocity_check.c:7: warning: (near initialization for ‘v0’) udf_final_velocity_check.c:5: warning: unused variable ‘vel’ udf_final_velocity_check.c: In function ‘inlet_axial_velocity’: udf_final_velocity_check.c:23: warning: unused variable ‘v’ # Linking libudf.so because of makefile user.udf udf_names.c udf_names.o udf_final_velocity_check.o ld -shared -lm udf_names.o udf_final_velocity_check.o -o libudf.so make[3]: warning: Clock skew detected. Your build may be incomplete. make[3]: Leaving directory `/home/cdiakodi/Desktop/Fluent_fran_fran/maillage_pr_fluent/new_2/lnamd64/3d' make[2]: warning: Clock skew detected. Your build may be incomplete. make[2]: Leaving directory `/home/cdiakodi/Desktop/Fluent_fran_fran/maillage_pr_fluent/new_2/lnamd64/3d' make[1]: warning: Clock skew detected. Your build may be incomplete. make[1]: Leaving directory `/home/cdiakodi/Desktop/Fluent_fran_fran/maillage_pr_fluent/new_2/lnamd64/3d' an idea ? |
It happens if you the array initializer has more elements than the array declared
Code:
int r0[3] = {0, 1, 2, 3}; Code:
int r0[] = {0, 1, 2, 3}; |
You were right, the UDF works now.
Thank you! |
Just one last question: how can I change the UDF that we have created to add a velocity profile of particles (using DPM)?
|
All times are GMT -4. The time now is 21:36. |