CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Fluent UDF and Scheme Programming

UDF errors

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

Reply
 
LinkBack Thread Tools Display Modes
Old   November 18, 2015, 11:22
Default UDF errors
  #1
Member
 
Martin Nolan
Join Date: Dec 2014
Posts: 33
Rep Power: 3
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:

#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!
mnolan93 is offline   Reply With Quote

Reply

Thread Tools
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 On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
AMI interDyMFoam for mixer nu problem danny123 OpenFOAM Programming & Development 8 September 6, 2013 02:34
AMI speed performance danny123 OpenFOAM 19 October 24, 2012 07:44
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 01: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 20:17.