|
[Sponsors] |
November 18, 2015, 11:22 |
UDF errors
|
#1 |
Member
Martin Nolan
Join Date: Dec 2014
Posts: 33
Rep Power: 12 |
Hi all,
I am very new to coding and have never done this before. I have made a UDF for specified shear in the x direction, tangential shear. I have the following errors: line 12: undeclared variable line 12: f_loop_last: undeclared variable no idea why! any help? here is the code: #include"udf.h" #define Tauxx /* wall shear stress, wall x direction, tangential shear */ DEFINE_PROFILE(wall_shear_x, thread, position) { face_t f; Thread *t0; cell_t c0; real TAUxx; real dudy,dvdx,mu begin_f_loop(f, thread) { t0 = THREAD_T0(thread); /* adjacent cell thread to f */ c0 = F_C0(f, thread); dudy = C_DUDY(c0,t0); /* derivative tangential velocity wrt normal coordinate */ dvdx = C_DVDX(c0,t0); /* derivative normal velocity wrt tangential coordinate */ mu = C_MU_L(c0,t0); /* viscosity */ TAUxx=mu*(dudy+dvdx); F_PROFILE(f, thread, position)=TAUxx; } end_f_loop(f, thread) } Thanks for any help in advance! |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Building OpenFOAM1.7.0 from source | ata | OpenFOAM Installation | 46 | March 6, 2022 14:21 |
AMI speed performance | danny123 | OpenFOAM | 21 | October 24, 2020 05:13 |
AMI interDyMFoam for mixer nu problem | danny123 | OpenFOAM Programming & Development | 8 | September 6, 2013 03:34 |
Errors when Compiling UDF: error C2040/error C2099 | Julian K. | FLUENT | 1 | December 21, 2008 01:23 |
errors in interpreted udf for two macro | Asghari | FLUENT | 0 | August 7, 2006 03:29 |