CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   Fluent UDF and Scheme Programming (https://www.cfd-online.com/Forums/fluent-udf/)
-   -   UDF for mass transfer between phases in two phase ice-slurry pipe flow (https://www.cfd-online.com/Forums/fluent-udf/179991-udf-mass-transfer-between-phases-two-phase-ice-slurry-pipe-flow.html)

devshi November 14, 2016 07:25

UDF for mass transfer between phases in two phase ice-slurry pipe flow
 
I have wrote a UDF for melting of ice-particles in two-phase ice-slurry pipe flow

The code is as follows:

#include "udf.h"
/* UDF to define a simple mass transfer*/

DEFINE_MASS_TRANSFER(UFD, cell, thread, from_index, from_species_index, to_index, to_species_index)

{real mass;

real hsl = 1;
real pr=1;
real C_YI(c,t,1);
real ds = 0.0001;
read latent_heat = 21000
real alphas = 0.1;
real ds = 0.0001;
real v = 1.25;
real lambdal = 0.5034;
real mus=1.72*10^-5;
real mul=0.70354;
real rhos=917;
real cpl=4260;
real latent_heat=332400;

Res= rhos*|C_U(c,t,2)-C_U(c,t,3)|*ds/mus;

Pr=mul*Cpl/lambdal

hsl= (lambdal/ds)*(7+(10*alphas)+(5*alphas^2))*(1+0.7*(Res^0.2)* (Pr^1.3))

hv=6*alphas*hsl/ds;

mass= hv*((C_T(c,t,2)-C_T(c,t,3))/latent_heat);

return mass;
}


I am keep getting error that :

Error: The UDF library you are trying to load (C:\Users\Devshi\Downloads\pipe\pipe2_files\dp0\FF F\Fluent\libudf) is not compiled for 3d on the current platform (win64).

The system cannot find the file specified.


Kindly help

Boh November 14, 2016 08:04

is it the first time that you compile an UDF?

devshi November 14, 2016 11:18

Yes, this is my first time. Kindly advice

Boh November 14, 2016 12:13

ok...then I had the same problem, for me it worked to disintall all visual c programs and install the Microsoft Visual Studio Express 2015 and then to add the path where "fluent.exe" and "runwb2.exe" to the "path" enviroment variable....then I rebooted the system and it worked...
https://www.researchgate.net/post/Ho..._ANSYS_Fluent2 (Here it's explained better)

devshi November 14, 2016 14:26

Thank you for your kind help. I'll let you know about the progress soon.

Thanks again!

`e` November 14, 2016 19:27

Also ensure you're correctly unloading and compiling the new UDF by following my compiling process for Fluent UDFs with an existing library loaded.


All times are GMT -4. The time now is 05:01.