Error when compiling UDF
hello everyone,
I faced problem to compile my udf as shown below, I dont know what caused the problem in my udf codes until fluent unable to compile it. I also try to compiled other udf and it goes smooth without any error.I think this is not the problem with compiler or fluent as I already setup the VS2012 and Fluent 16 according to system required. It maybe something wrong in my udf codes,but I dont know to track at which line caused the error. Can anybody help me to solve this problem. #include "udf.h" #include "dynamesh_tools.h" static real v_prev = 0.0; DEFINE_CG_MOTION(osc, dt, vel, omega, time, dtime) { Thread *t; Domain *d = Get_Domain(1); real x_cg[3], force[3], moment[3]; real accl, dv; real mass = 0.2; real wn = 12.0; real k = mass * wn*wn; real c = 2 * mass*wn*0.00; int i; NV_S(vel, = , 0.0); NV_S(omega, = , 0.0); /*t = DT_THREAD(dt);*/ t = DT_THREAD((Dynamic_Thread *)dt); for (i = 0; i<3; i++) x_cg[i] = DT_CG(dt)[i]; Compute_Force_And_Moment(d, t, x_cg, force, moment, TRUE); force[1] += -k*x_cg[1] - c*vel[1]; accl = force[1] / mass; dv = accl*dtime; v_prev += dv; vel[1] = v_prev; printf("Computed force: %g \n", force[1]); printf("Velocity: %g\n", vel[1]); } DEFINE_CG_MOTION(osc_inert, dt, vel, omega, time, dtime) { vel[0] = 0.0; vel[1] = v_prev; } |
What is the error message that Fluent gives when you try to compile?
|
All times are GMT -4. The time now is 21:23. |