CFD Online Discussion Forums

CFD Online Discussion Forums (
-   FLUENT (
-   -   regarding turbulent viscosity.. (

seeta August 28, 2006 07:36

regarding turbulent viscosity..
hi, can any body help me to write UDF for turbulent eddy viscosity. i have written UDF but its not working... i am attaching my UDF here. can anyone find where is the mistake in UDF. Its very urgent.

turbulent viscosity is defined as "c-mue*f-mue*k*k/epsilon"

where f_mu is a damping function defined as follows

/*damping functions*/ real re_t(cell_t c,Thread *t) {

return C_R(c,t)*C_UDSI(c,t,TKE)/(C_MU_L(c,t)*C_UDSI(c,t,TSDR));

} real f_mu(cell_t c,Thread *t) {

return 0.09+(0.91+(1/pow(re_t(c,t),3.0)))*(1-exp(pow((-re_t(c,t)/25.0),2.75))); }


real mu_t;


return mu_t; }

cadaei August 28, 2006 17:12

Re: regarding turbulent viscosity..
i compiled the UDF with no problems provided that i specified TKE and TSDR. Can you compile the UDF?

seeta August 29, 2006 09:43

Re: regarding turbulent viscosity..
hi yah i can compile with out any errors but we are giving iterations then fatal erroe is coming in fluent interface.

Mark August 30, 2006 02:40

Re: regarding turbulent viscosity..
Did you define user defined scalars?

seeta August 30, 2006 06:33

Re: regarding turbulent viscosity..
yah i have defined for turbulent kinetic energy and specific dissipation rate

Mark August 30, 2006 09:47

Re: regarding turbulent viscosity..
Want to start at the beginning - can you compile and run other UDF's that are known to work?

seeta September 5, 2006 03:57

Re: regarding turbulent viscosity..
hi yah i compiled all other udfs which i know ..........they are all working well

Purushotham September 15, 2006 06:11

Re: regarding turbulent viscosity..
Hi seeta u seems to be more familiar with FLUENT...can u suggest me which model is the best accurate to simulate flow in ducts of varying cross section like bends, sudden expansion, sudden contraction etc..I hope u r aware of the minor loss coefficient..most the ealier workers who have worked on duct flow analysis they have given some empirical formulae to finding out the loss coefficient called "K" the question is using fluent can i get the loss coefficient values in comparision with the ealier empirical formulae...ur help in this regard is highly appreciated..thanks and regards... Purushotham

All times are GMT -4. The time now is 13:27.