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

interpreted fluent parse error

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   July 7, 2015, 23:22
Default interpreted fluent parse error
  #1
New Member
 
hallow rocks
Join Date: Apr 2014
Posts: 9
Rep Power: 12
unihit4392 is on a distinguished road
i am trying to use following UDF which includes two boundary conditions.
but it shows parse error in line 19 when i try to load it in FLUENT. I dont know what the problem is


#include "udf.h"
#include "unsteady.h"
DEFINE_PROFILE(transient_velocity, thread, index)
{
face_t f;
real x[ND_ND];
real t = CURRENT_TIME;
real tc;
real v [100];
int N;
int j;
real y;
real i = N_TIME;
begin_f_loop(f, thread)
{
y = i;
N=t/0.84;
tc=(t-0.84*N)*2.741;
v [j] = -29.88+24.15*cos(tc)+44.1*sin(tc)+15.47*cos(2*tc)-24.42*sin(2*tc)10.33*cos(3*tc)-0.3837*sin(3*tc)+0.8866*cos(4*tc)+1.568*sin(4*tc);
F_CENTROID(x,f,thread);
y = x[1];
F_PROFILE(f,thread,index) = v [j]/2;
}
end_f_loop(f, thread)
}

DEFINE_PROFILE(unsteady_pressure, thread, position)
{

float t, pressure; face_t f;

/* Get real flow time from fluent using RP_Get_Real command*/

t = RP_Get_Real("flow-time");

/* Set pressure dependant on time for pulse duration */
if (t<=0.00821) { pressure = 60000*sin(3.14159*t/0.00821); } else { pressure = 0; }

/* loop over the whole boundary condition */

begin_f_loop(f, thread) {

F_PROFILE(f, thread, position) = pressure; } end_f_loop(f, thread)

}
unihit4392 is offline   Reply With Quote

Reply


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
[OpenFOAM] an error in Calculator's equation immortality ParaView 12 June 29, 2021 01:10
Errors in UDF shashank312 Fluent UDF and Scheme Programming 6 May 30, 2013 21:30
How to install CGNS under windows xp? lzgwhy Main CFD Forum 1 January 11, 2011 19:44
checking the system setup and Qt version vivek070176 OpenFOAM Installation 22 June 1, 2010 13:34
error while compiling the USER Sub routine CFD user CFX 3 November 25, 2002 16:16


All times are GMT -4. The time now is 21:39.