CFD Online Logo CFD Online URL
Home > Forums > Software User Forums > ANSYS > FLUENT > Fluent UDF and Scheme Programming

UDF errors

Register Blogs Members List Search Today's Posts Mark Forums Read

LinkBack Thread Tools Search this Thread Display Modes
Old   November 18, 2015, 10:22
Default UDF errors
Martin Nolan
Join Date: Dec 2014
Posts: 33
Rep Power: 8
mnolan93 is on a distinguished road
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:

#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 */
F_PROFILE(f, thread, position)=TAUxx;
end_f_loop(f, thread)

Thanks for any help in advance!
mnolan93 is offline   Reply With Quote


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
AMI speed performance danny123 OpenFOAM 21 October 24, 2020 04:13
AMI interDyMFoam for mixer nu problem danny123 OpenFOAM Programming & Development 8 September 6, 2013 02:34
Building OpenFOAM1.7.0 from source ata OpenFOAM Installation 42 May 14, 2012 20:48
Errors when Compiling UDF: error C2040/error C2099 Julian K. FLUENT 1 December 21, 2008 00:23
errors in interpreted udf for two macro Asghari FLUENT 0 August 7, 2006 02:29

All times are GMT -4. The time now is 18:46.