viscosity in UDF!
Recently i have been modelling a stir model, but the material viscosity was related strain rate and temperature, so i use UDF in fluent. i select standard K-E model, but when i start compute ,the fluent will send wrong message: "floating point error", the behaid is my program: #include "udf.h"
#define Q 183890 #define R 8.314 #define RFA 0.0108E-6 #define N 7.7563 #define AA 1.44E+14
temp = C_T( cell, thread );
e_s = C_STRAIN_RATE_MAG( cell, thread );
z_h = e_s * exp( Q / ( R * TT ) );
mm = pow( z_h/AA, 1/N ) + sqrt( pow( z_h/AA, 2/N) + 1 );
stress = log( mm );
viscosity = stress / ( 3 * e_s * RFA);
return viscosity; }
please help me! thanks
|All times are GMT -4. The time now is 13:53.|