CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > ANSYS > FLUENT

UDF:line 6: parse error.

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

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   June 24, 2008, 04:30
Default UDF:line 6: parse error.
  #1
Jiying Liu
Guest
 
Posts: n/a
Hi: I have tried several times,but there is error. Can anyone please help me with this program or give me some advice?

Error: D:\001\udf-k.c: line 6: parse error.

My short code is as follows: #inlude "udf.h" #define UMEAN 1.1 #define Y 500. #define DEL 0.1 #define B 0.28 DEFINE_PROFILE(k_profile, t, i) { real y; real ufree; real x[ND_ND]; face_t f; ufree=UMEAN*pow(DEL,B); begin_f_loop(f,t) { F_CENTROID(x,f,t); y=x[1]; F_PROFILE(f,t,i)=pow((0.0247-0.235*y/Y)*ufree*pow(y,B),2.)/1.08; } end_f_loop(f,t) }

  Reply With Quote

Old   June 24, 2008, 04:37
Default Re: UDF:line 6: parse error.
  #2
Jiying Liu
Guest
 
Posts: n/a
#inlude "udf.h"

#define UMEAN 1.1

#define Y 500.

#define DEL 0.1

#define B 0.28

DEFINE_PROFILE(k_profile, t, i)

{

real y;

real ufree;

real x[ND_ND];

face_t f;

ufree=UMEAN*pow(DEL,B);

begin_f_loop(f,t)

{

F_CENTROID(x,f,t);

y=x[1];

F_PROFILE(f,t,i)=pow((0.0247-0.235*y/Y)*ufree*pow(y,B),2.)/1.08;

}

end_f_loop(f,t)

}

  Reply With Quote

Old   June 25, 2008, 21:01
Default Re: UDF:line 6: parse error.
  #3
cfd_newbie
Guest
 
Posts: n/a
Just a typo mistake, instead of:

#include "udf.h"

you have

#inlude "udf.h"

Advice: use a syntax highlighting editor for writing your code (ex. on Linux gvim, Emacs ... on Windows try Programmers Notepad).

  Reply With Quote

Old   July 6, 2008, 22:23
Default Re: UDF:line 6: parse error.
  #4
Jiying Liu
Guest
 
Posts: n/a
oh,thanks a lot.
  Reply With Quote

Old   July 6, 2008, 22:24
Default Re: UDF:line 6: parse error.
  #5
Jiying Liu
Guest
 
Posts: n/a
oh,oh,thanks a lot.
  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
UDF line 1 parse error Dimitrios Fluent UDF and Scheme Programming 24 March 18, 2015 23:53
Reg. Parse error in line 3 Arun FLUENT 0 May 2, 2008 07:33
line 91 parse error brusly FLUENT 1 January 29, 2007 06:54
UDF Parse Error Line 1 Brian FLUENT 1 October 29, 2005 13:12
UDF: Parse error line 3 CJ FLUENT 2 March 1, 2005 11:12


All times are GMT -4. The time now is 07:48.