CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   FLUENT (http://www.cfd-online.com/Forums/fluent/)
-   -   ######### Error when Interpreted UDF ############ (http://www.cfd-online.com/Forums/fluent/41369-error-when-interpreted-udf.html)

Tang Kuei June 13, 2006 06:04

######### Error when Interpreted UDF ############
 
When I interpreting my UDF, one error message comes out. "function returning void returning float". What can I do for this?

The main error of my UDF code as follow:

DEFINE_PROFILE(inlet_x_velocity, thread, index) { real eof_ux; real eps = 78.0; real vis = 0.911; real zeta = -0.055; real Ek = 5000.0;

eof_ux = -(eps*epsilon0*zeta*Ek/vis);

return eof_ux; }

Fabrice June 13, 2006 18:56

Re: ######### Error when Interpreted UDF #########
 
Hi guy,

Your UDF is wrong ("return eof_ux;"... is not allowed). You can check several examples in the UDF manual about the macro DEFINE_PROFILE (section 12 "sample problems", 12.1 "boundary conditions"). It's not difficult.

Regards,

Fabrice.

Tang Kuei June 13, 2006 19:09

Thanks
 
Thanks for your information. I think that my code make a big mistake.

Regards


All times are GMT -4. The time now is 09:10.