求高手解决fluent问题? 5
#include"udf.h"#include"mem.h"#include"math.h"#defineC03.6#defineBEIT1.5#defineDM0.06...
#include "udf.h"
#include "mem.h"
#include "math.h"
#define C03.6
#define BEIT1.5
#define DM0.064
/* first UDF */
DEFINE_PROFILE(porous_profile, thread, position) /* defining porosity of porous media */
{
real r[ND_ND];
real x,y,m;
face_t f;
begin_f_loop(f, thread)
{
F_CENTROID(r,f,thread);
x=r[2];
y=r[1];
if(y<100)
m=1.15+0.35*exp(-0.37*x*(1-exp(-0.6244*y)));
else
m=1.15+0.35*exp(-0.37*x*(1-exp(-0.6244*(197-y))));
F_PROFILE(f, thread, position)=1-1/m;
}
end_f_loop(f, thread)
}
/* second UDF */
DEFINE_PROFILE(inertia_resistance, thread, position) /* defining inertia resistance of porous media */
{
real r[ND_ND];
real x,y,n,BEIT,DM,C0;
face_t f;
begin_f_loop(f, thread)
{
F_CENTROID(r,f,thread);
x=r[2];
y=r[1];
if(y<100)
n=1-1/(1.15+0.35*exp(-0.37*x*(1-exp(-0.6244*y))));
else
n=1-1/(1.15+0.35*exp(-0.37*x*(1-exp(-0.6244*(197-y)))));
F_PROFILE(f, thread, position)=2*BEIT*DM*pow(1-n,2)/(pow(n,4)*C0);
}
end_f_loop(f, thread)
}
出现F:\example\moni3\myudf.c:3: math.h: No such file or directory怎么回事? 展开
#include "mem.h"
#include "math.h"
#define C03.6
#define BEIT1.5
#define DM0.064
/* first UDF */
DEFINE_PROFILE(porous_profile, thread, position) /* defining porosity of porous media */
{
real r[ND_ND];
real x,y,m;
face_t f;
begin_f_loop(f, thread)
{
F_CENTROID(r,f,thread);
x=r[2];
y=r[1];
if(y<100)
m=1.15+0.35*exp(-0.37*x*(1-exp(-0.6244*y)));
else
m=1.15+0.35*exp(-0.37*x*(1-exp(-0.6244*(197-y))));
F_PROFILE(f, thread, position)=1-1/m;
}
end_f_loop(f, thread)
}
/* second UDF */
DEFINE_PROFILE(inertia_resistance, thread, position) /* defining inertia resistance of porous media */
{
real r[ND_ND];
real x,y,n,BEIT,DM,C0;
face_t f;
begin_f_loop(f, thread)
{
F_CENTROID(r,f,thread);
x=r[2];
y=r[1];
if(y<100)
n=1-1/(1.15+0.35*exp(-0.37*x*(1-exp(-0.6244*y))));
else
n=1-1/(1.15+0.35*exp(-0.37*x*(1-exp(-0.6244*(197-y)))));
F_PROFILE(f, thread, position)=2*BEIT*DM*pow(1-n,2)/(pow(n,4)*C0);
}
end_f_loop(f, thread)
}
出现F:\example\moni3\myudf.c:3: math.h: No such file or directory怎么回事? 展开
1个回答
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询