CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
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

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


All times are GMT -4. The time now is 04:14.