|April 23, 2009, 19:09||
Logarithmic velocity profile
Join Date: Apr 2009
Posts: 14Rep Power: 8
Hello, I have a problem with the definition of a boundary condition with UDF to simulation of the wind in a terrain. I have to define a velocity inlet in a 3d domain; this condition is a logarithmic velocity profile. I can define the logarithmic velocity profile with UDF, like this:
z = x;
F_PROFILE(f,thread,index) = 3*log(z/0.01)/log(10/0.01);
My domain is this:
I have to impose the logarithmic profile in the front face that is shown in figure.
My question is how I define in the UDF so that the velocity in bottom of the face is equal 0.
My problem is the coordinates that I use in UDF are absolute and I donít know how to define relative coordinates, in order to the z in the equation that defines the velocity profile, is the height relatively to the bottom of the face and not the absolute height.
I tried to use the C_WALL_DIST(c,thread) macro to resolve this issue (this macro estimate the distance from any cell to the nearest WALL, which is the terrain), like this:
z = C_WALL_DIST(c,thread);
But when i selected the udf in velocity inlet in boundary condition, fluent gave me this message:
FLUENT received fatal signal (ACCESS_VIOLATION)
1. Note exact events leading to error.
2. Save case/data under new name.
3. Exit program and restart to continue.
4. Report error to your distributor.
Error Object: ()
I think the problem is that the boundary condition that I set is to a face and I use a macro for cells in the udf.
I donít know how to use this macro for my situation. Can anyone help me with this issue ?
I would appreciate any suggestions.
PS: Sorry for repeat the thread of fluent forum but only now I noticed that there is a sub-forum dedicated to udf
Last edited by cfdworker; April 23, 2009 at 20:38.
|Thread||Thread Starter||Forum||Replies||Last Post|
|3D UDF Paraboilc Velocity Profile (Can't Maintain)||Sing||FLUENT||10||October 14, 2015 20:24|
|[UDF] Relative coordinates in logarithmic velocity profile||cfdworker||Fluent UDF and Scheme Programming||24||February 23, 2015 05:33|
|[boundary condition] logarithmic velocity profile||cfdworker||FLUENT||2||April 17, 2009 23:36|
|maintaining a logarithmic velocity distribution||Morten Andersen||CFX||1||January 8, 2007 12:37|
|Variables Definition in CFX Solver 5.6||R P||CFX||2||October 26, 2004 02:13|