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

parse error , please help

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   October 21, 2012, 15:53
Default parse error , please help
  #1
New Member
 
IVI
Join Date: Oct 2012
Posts: 14
Rep Power: 14
89566008 is on a distinguished road
there are 4 error for my udf :
line 13: parse error.
line 14: parse error.
line 15: parse error.
line 16: subscripted expression is not an array or pointer: double.

here is my udf :

#include "udf.h"
#include "dpm.h"
#include "math.h"
#include "mem.h"
#define Pia 3.14
#define epsilon_0 8.85e-12
#define epsilon_r 1.000590
#define K_ion 0.00022
DEFINE_DPM_BODY_FORCE(particle_body_force,p,i)
{
real bforce=0,Qd,Q,t, t_half;
real x;
x=[ND,ND];
cell_t c = RP_CELL(&(p->cCell));
Thread *t = RP_THREAD( &(p->cCell) );
C_CENTROID(x,c,*t);

if(i==1)
{
Qd=3*Pia*epsilon_0*(epsilon_r/(epsilon_r+2))*pow(P_DIAM(p),2.0)*C_UDSI_G(c,t,1)[1];
t_half=4*epsilon_0/(C_UDSI(c,t,0)*K_ion);
Q=(3*Qd/2)-(t_half*Qd/P_TIME(p));
}
if(Q<=Qd)
{
bforce=Q*C_UDSI_G(c,t,1)[1];
}
else
{
bforce=Qd*C_UDSI_G(c,t,1)[1];
}
return (bforce/P_MASS(p));
}

what is wrong ?
89566008 is offline   Reply With Quote

Old   October 22, 2012, 12:25
Default
  #2
New Member
 
IVI
Join Date: Oct 2012
Posts: 14
Rep Power: 14
89566008 is on a distinguished road
please check my UDF , if it possible
I need help
89566008 is offline   Reply With Quote

Old   October 22, 2012, 12:59
Default
  #3
New Member
 
IVI
Join Date: Oct 2012
Posts: 14
Rep Power: 14
89566008 is on a distinguished road
please check my UDF , if it possible
I need help
89566008 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
A Problem of Fluent Interpreted UDF: parse error knight Fluent UDF and Scheme Programming 25 August 16, 2018 11:26
parse error in transient udf spring FLUENT 1 July 6, 2010 07:26
Parse Error Message While interpreting UDF in FLUENT dhimans Fluent UDF and Scheme Programming 1 July 10, 2009 07:29
PARSE ERROR Message when interpreting UDF in FLUENT dhimans FLUENT 0 May 24, 2009 12:40
Parse Error Vamsee FLUENT 0 March 16, 2009 16:03


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