|
[Sponsors] |
February 23, 2007, 17:18 |
Getting error with udf..
|
#1 |
Guest
Posts: n/a
|
Hi
I am having dynamic mesh model with VOF. I wrote a UDF for the motion of a wall. There is no error while compiling this udf. But when I start to iterate it gives me access violation error. Should I use the domain id for mixture or for the phases? # include<udf.h> int stop=0; int ZONE_ID = 12; DEFINE_CG_MOTION(moving_wall,t,vel,omega,time,dtim e) { real x; Node *node; face_t f; Domain *domain = Get_Domain(1); cell_t c0; Thread *t0,*ft; if(stop == 0) { vel[0]= 0; vel[1]= -0.01; vel[2]= 0; omega[0]= 0; omega[1]= 0; omega[2]= 0; ft = Lookup_Thread(domain, ZONE_ID); begin_f_loop(f,ft) { c0 = F_C0(f,ft); t0 = F_C0_THREAD(f, ft); if(C_VOF(c0,t0) >= 0.5) stop = 1; }end_f_loop(f,ft); } else vel[0] = 0; vel[1] = 0; vel[2] = 0; omega[0] = 0; omega[1] = 0; omega[2] = 0; } Can anyone help me with it? Thanks, Shanti |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Dynamic Mesh UDF | Qureshi | FLUENT | 7 | March 23, 2017 07:37 |
UDF parallel error: chip-exec: function not found????? | shankara.2 | Fluent UDF and Scheme Programming | 1 | January 16, 2012 22:14 |
How to add a UDF to a compiled UDF library | kim | FLUENT | 3 | October 26, 2011 21:38 |
UDF...UDF...UDF...UDF | Luc SEMINEL | FLUENT | 0 | November 25, 2002 04:03 |
UDF, UDF, UDF, UDF | Luc SEMINEL | Main CFD Forum | 0 | November 25, 2002 04:01 |