How to remove "invalid type conversion: double -> pointer to char" Error??
I have written a UDF to define the Mass Source by the following equation
DEFINE_SOURCE(mass_source,c,t,dS,eqn) { real msource, b, bP, ba, kc ; b = k0 * exp(AdsH/(R*C_T(c,t)))*op_pres; bP = pow((k0/qm*exp(AdsH/(R*C_T(c,t)))*op_pres),tq); ba = pow(bP,1/tq); C_UDSI(c,t,0) = b / ba; /* C_eq ]g/g] equilibrium uptake*/ kc = 126.9889 * exp (-2757.8/C_T(c,t)); /*[s-1] corrected mass diffusion coeff by CFD simu*/ /* Computing instant uptake */ C_UDSI(c,t,1) = C_UDSI_M1(c,t,1) + kc * CURRENT_TIMESTEP * (C_UDSI(c,t,0) -C_UDSI_M1(c,t,1)); /* calculation dw/dt = ksav(Ceq - c_in);*/ C_UDSI(c,t,3) = (C_UDSI(c,t,1) - C_UDSI_M1(c,t,1)) / CURRENT_TIMESTEP ;/*dwbydt*/ /*C_UDSI(c,t,3) = ksav * (C_UDSI(c,t,0) - C_UDSI_M1(c,t,1)); /*mass source calculation*/ msource = -(1-bed_p) * dens_AC * C_UDSI(c,t,3); /*[kg/m3.s]*/ C_UDSI(c,t,4) = msource ; /*dS[eqn] = - F0 * DbyRp2 * msource ;*/ /*C_UDSI(c,t,5) = - F0 * DbyRp2 * msource;*/ return msource; } When i interpret it, It shows the following Error in Line - 5. "invalid type conversion: double -> pointer to char" Please Suggest me something how to remove this Error???? Thanks. |
All times are GMT -4. The time now is 15:34. |