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

Parabolic Inlet velocity UDF parse error

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

Reply
 
LinkBack Thread Tools Display Modes
Old   August 28, 2012, 01:50
Default Parabolic Inlet velocity UDF parse error
  #1
Member
 
Musango Lungu
Join Date: Dec 2011
Location: China
Posts: 73
Rep Power: 5
Musa is on a distinguished road
I am trying to create a udf for an inlet parabolic velocity profile however I am receving a parse error message in line 3. However I cannot see my mistake. Kindly help me.Line 3 is the bold line.

# include “udf.h”

DEFINE_PROFILE( y_velocity, thread, nv)
{
float x[3]; /* array for the coordinates */
float y;
face_t f; /* f is a thread face index */

begin_f_loop(f,thread)
{
F_CENTROID (x, f,thread);
x = y[1] ;
F_PROFILE ( f,thread nv)
= .88*(1.-y*y/(.15*.15) );
}
end_f_loop (f,thread)
}
Musa is offline   Reply With Quote

Old   August 29, 2012, 01:37
Default
  #2
New Member
 
Sama
Join Date: Sep 2011
Posts: 6
Rep Power: 5
Sama is on a distinguished road
It sometimes gives error in wrong line so I believe the problem is this line F_PROFILE ( f,thread nv) you should add a comma "," between thread and nv.
Sama 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
Compile problem ivanyao OpenFOAM Running, Solving & CFD 1 October 12, 2012 09:31
Saving ParaFoam views and case sail OpenFOAM Paraview & paraFoam 9 November 25, 2011 16:46
CGNS lib and Fortran compiler manaliac Main CFD Forum 2 November 29, 2010 07:25
OpenFOAM on MinGW crosscompiler hosted on Linux allenzhao OpenFOAM Installation 127 January 30, 2009 20:08
user subroutine error CFDUSER CFX 2 December 9, 2006 07:31


All times are GMT -4. The time now is 11:55.