|
|
马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。
您需要 登录 才可以下载或查看,没有账号?注册
x
/*********************************************************************/
/* UDF for specifying a viscous resistance property */
/*********************************************************************/
#include "udf.h"
#define Dp1 0.0014
DEFINE_PROPERTY(cell_viscous, c, t) /*defining viscous resistance of porous media*/
{
real x[ND_ND];
real y;
real p;
real vr;
C_CENTROID(x,c,t);
y=x[0];
if (y<=100)
p=0.00001*y*y-0.002*y+0.3;
else
p=0.2;
vr=150*(1-p)*(1-p)/(Dp1*Dp1*p*p*p);
return vr; //returning viscous resistance distribution
}
/*********************************************************************/
/* UDF for specifying a inertial resistance property */
/*********************************************************************/
/*#include "udf.h"
/*
/*#define Dp1 0.0014
DEFINE_PROPERTY(cell_inertial, c, t) /*defining inertial resistance of porous media*/
{
real x[ND_ND];
real y;
real p;
real ir;
C_CENTROID(x,c,t);
y=x[0];
if (y<=100)
p=0.00001*y*y-0.002*y+0.3;
else
p=0.2;
ir=3.5*(1-p)/(Dp1*p*p*p);
return ir; //returning inertial resistance distribution
}
/*********************************************************************/
/* UDF for specifying a porosity property */
/*********************************************************************/
/*#include "udf.h"
DEFINE_PROPERTY(cell_porosity, c, t) /*defining porosity of porous media*/
{
real x[ND_ND];
real y;
real p;
C_CENTROID(x,c,t);
y=x[0];
if (y<=100)
p=0.00001*y*y-0.002*y+0.3;
else
p=0.2;
return p; //returning porosity distribution
}
注:不注释掉第二个和第三个前面的“#include "udf.h"”也通不编译。 |
|