Profile of fixed value in a fluid zone using a DEFINE_PROFILE function

It is possible to implement an analytical profile of fixed values to the fluid zone. But the DEFINE_PROFILE function has to be modified a little bit to fit the loop over all the cells. The F_PROFILE will work for cells too as it has been defined in that manner. One such udf is documented below. It uses a simple spatial profile. The profile is the same as the pressure profile documented in the DEFINE_PROFILE documentation.
Other functions could be used too. The same udf could be used for implementing profiles of porosity, viscous resistance and inertial resistance for porous zone condition.
#include "udf.h"

DEFINE_PROFILE(porous_resistance, t,i)
real x[ND_ND],y;
cell_t c;

begin_c_loop(c, t)
F_PROFILE(c, t, i) = 1.1e5 - y*y/(.0745*.0745)*0.1e5;
end_c_loop(c, t)

Show Form
No comments yet. Be the first to add a comment!