CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   FLUENT (http://www.cfd-online.com/Forums/fluent/)
-   -   UDF Interpret - Syntax Error (http://www.cfd-online.com/Forums/fluent/38336-udf-interpret-syntax-error.html)

Leonard October 22, 2005 06:23

UDF Interpret - Syntax Error
 
Hello,

I've tried to interpret a simple "DEFINE_SOURCE" udf in Fluent, but I always get the message "line 2: syntax error". I've checked my source code (below) and found no problem with it. Can anyone advice me on this? Thank you.

#include "udf.h"

DEFINE_SOURCE(mass_sink,c,t,dS,1) {

real sink;

sink=-0.4;

dS[1]=0;

return sink; }

Alec Eiffel October 22, 2005 11:06

Re: UDF Interpret - Syntax Error
 
try this:

#include "udf.h"

DEFINE_SOURCE(mass_sink,c,t,dS,eqn) {

real sink;

sink=-0.4;

dS[eqn]=0;

return sink; }


All times are GMT -4. The time now is 22:26.