|
[Sponsors] |
June 26, 2012, 18:22 |
parse error udf
|
#1 |
New Member
Ch_Flame
Join Date: Apr 2012
Location: Iran
Posts: 13
Rep Power: 13 |
HI
When i interpret my UDF file, it says parse error in line 33, #include "udf.h" #include "sg_mem.h" #include "outlet.h" DEFINE_INIT(my_uds0, domain) { cell_t c; Thread *t; /* loop over all cell threads in the domain */ thread_loop_c (t,domain) { /* loop over all cells */ begin_c_loop_all (c,t) { if (C_FMEAN(c,t)>0.06) C_UDSI(c,t,0) = 1.0; else C_UDSI(c,t,0) = 0.0; } end_c_loop_all (c,t) } } DEFINE_DIFFUSIVITY(diffu,c,t,i) { return (C_MU_T(c,t)) / 0.9; } DEFINE_PROFILE(scaler_outlet,t,i) {/*________ scaler outlet (ds/dn =0)(n:Boundary normal vector) _______*/} real s; face_t f; begin_f_loop(f,t) { s=C_UDSI(F_C0(f,t),THREAD_T0(t),0); F_PROFILE(f,t,i) = s; } end_f_loop(f,t) } Someone knows the problem? plz help meeeeeeee! |
|
June 29, 2012, 03:56 |
|
#2 |
New Member
Majid Mostafazadeh
Join Date: Nov 2011
Posts: 15
Rep Power: 14 |
Hi
Try this one, it works. #include "udf.h" #include "sg_mem.h" #include "outlet.h" DEFINE_INIT(my_uds0, domain) { cell_t c; Thread *t; /* loop over all cell threads in the domain */ thread_loop_c (t,domain) { /* loop over all cells */ begin_c_loop_all (c,t) { if (C_FMEAN(c,t)>0.06) C_UDSI(c,t,0) = 1.0; else C_UDSI(c,t,0) = 0.0; } end_c_loop_all (c,t) } } DEFINE_DIFFUSIVITY(diffu,c,t,i) { return (C_MU_T(c,t)) / 0.9; } DEFINE_PROFILE(scaler_outlet,t,i) { real s; face_t f; begin_f_loop(f,t) { s=C_UDSI(F_C0(f,t),THREAD_T0(t),0); F_PROFILE(f,t,i) = s; } end_f_loop(f,t) } |
|
June 29, 2012, 05:33 |
|
#3 | |
New Member
Ch_Flame
Join Date: Apr 2012
Location: Iran
Posts: 13
Rep Power: 13 |
Quote:
Thanks in advance ... |
||
June 29, 2012, 06:18 |
|
#4 |
New Member
Majid Mostafazadeh
Join Date: Nov 2011
Posts: 15
Rep Power: 14 |
Close FLUENT and run it again to eliminate the error...
good luck |
|
June 29, 2012, 06:21 |
|
#5 |
New Member
Ch_Flame
Join Date: Apr 2012
Location: Iran
Posts: 13
Rep Power: 13 |
||
June 29, 2012, 06:24 |
|
#6 |
New Member
Majid Mostafazadeh
Join Date: Nov 2011
Posts: 15
Rep Power: 14 |
save your case in another name and try it again...
|
|
June 29, 2012, 06:30 |
|
#7 |
New Member
Ch_Flame
Join Date: Apr 2012
Location: Iran
Posts: 13
Rep Power: 13 |
||
June 29, 2012, 06:37 |
|
#8 |
New Member
Majid Mostafazadeh
Join Date: Nov 2011
Posts: 15
Rep Power: 14 |
I tested your UDF in a case and it worked...
Set your problem from beginning: Read the mesh file and first of all, interpret the UDF. Then set the boundary conditions. Let me know if it works. |
|
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
parse error in transient udf | spring | FLUENT | 1 | July 6, 2010 07:26 |
parse error with udf | sofie1 | Fluent UDF and Scheme Programming | 1 | April 9, 2010 12:34 |
Parse Error Message While interpreting UDF in FLUENT | dhimans | Fluent UDF and Scheme Programming | 1 | July 10, 2009 07:29 |
PARSE ERROR Message when interpreting UDF in FLUENT | dhimans | FLUENT | 0 | May 24, 2009 12:40 |
UDF parse error on line 1 ..... (Unusual) | Amit Maha | FLUENT | 4 | June 30, 2006 13:15 |