CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > FLUENT

Warmia and Mazury Uniwersity

Register Blogs Members List Search Today's Posts Mark Forums Read

Reply
 
LinkBack Thread Tools Display Modes
Old   October 17, 2008, 11:59
Default Warmia and Mazury Uniwersity
  #1
wojciech
Guest
 
Posts: n/a
Hello,

I try to write a UDF for Forchheimer law in porous media. Unfortunately, in this way calculated resistance is to small. When I use the original model (from GUI) the result is very good and is suitable with experiment. My UDF is bellow. Could anybody help me - what is wrong?

------------ #include "udf.h" DEFINE_SOURCE(forchheimer_z,cell,thread,dS,eqn) {

real k; real two_beta; real x[ND_ND]; real Uz; real linear; real nonlinear; real source;

/* cell geometry: */ C_CENTROID(x, cell, thread);

/* k and two_beta: */ k = 4.90987500E+08; two_beta = 36430.72;

/* z-Velocity: */ Uz = C_W(cell,thread);

/* linear: */ linear = (C_MU_L(cell,thread)/k)*0.9;

/* nonlinear: */ nonlinear = two_beta * 0.5 * C_R(cell,thread)*0.9;

/* total resistance: */ source = -(linear * Uz + nonlinear * fabs(Uz) * Uz);

/* d(total resistance): */ dS[eqn] = -(linear + 2.0 * nonlinear * fabs(Uz));

return source; }

---------

Thanks,

wojciech
  Reply With Quote

Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
UNIVERSITY OF WARMIA AND MAZURY IN OLSZTYN wojciech FLUENT 0 October 2, 2008 07:53


All times are GMT -4. The time now is 07:02.