CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   FLUENT (https://www.cfd-online.com/Forums/fluent/)
-   -   VISCOSITY UDF (https://www.cfd-online.com/Forums/fluent/41079-viscosity-udf.html)

AdN May 23, 2006 05:33

VISCOSITY UDF
 
Hello everyone!

I have again (and again) a question about UDF! This time, I try to modify viscosity in a region of my domain. When I interpret my function and initialise my pb, I can see (with display contour/molecular viscosity) that my initial viscosity is set correctly. But when i launch iterations (I'm in unsteady), everything goes wrong! I notice that my function is called twice per iteration! Can somebody tell me why?

P.S. In my function, i put conditions in that way the function will be called only on the first iteration of every time step. But as DEFINE_PROPERTY is called at every iteration, when we are at an other iteration than the first of a time step, there is no return statement in my function (in fact, the return is inside an "if" condition).



All times are GMT -4. The time now is 08:51.