![]() |
Velocity(inlet Boundary)
Hi everyone;
I simulated 3D water tank. Changes in the Y direction is not important. when i add the Velocity.c to fluent this error appear: line 20: i: undeclared variable #include "udf.h" #define ZMIN 0.0 #define ZMAX 0.8 #define UH 0.063 #define UMEAN 0.15625 #define P 0.21 DEFINE_PROFILE(x_velocity,t,i) { real z, x[ND_ND], h; face_t f; h=ZMAX-ZMIN; begin_f_loop(f,t) { F_CENTROID(x,f,t); z=x[1]; if (z<=0.4) F_PROFILE(f,t,i)=UH*pow(z/0.1,P); else F_PROFILE(f,t,i)=UMEAN; } end_f_loop(f,t) } what is problem? |
I am pretty sure that the pow(x,y) function is a part of the math library.
Try adding #include "math.h" to the header. |
udf.h takes care of including other file header files for math functions.
try defining the profile by: Code:
begin_c_loop(c,t) |
| All times are GMT -4. The time now is 20:48. |