CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > ANSYS > FLUENT > Fluent UDF and Scheme Programming

WenYu Define_DPM_Drag

Register Blogs Community New Posts Updated Threads Search

 
 
LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
Old   January 8, 2019, 04:28
Question WenYu Define_DPM_Drag
  #1
New Member
 
Mario B.
Join Date: Feb 2018
Posts: 11
Rep Power: 8
blerli_91 is on a distinguished road
Dear Forum,


For future projects I want to implement alternative Drag laws for the DDPM model. For getting experience in UDF programming (I am quite new to the topic) I am trying to recreate the Fluent Build-In Drag law by Wen and Yu. I have a 1D test case for comparison of the original drag law and my UDF. For comparison I am using a DPM-Sample at the Outlet for a patched Flow-Field.
According to UDF Manual the Define_DPM_Drag should return an expression equal to: \frac{18 Cd Re }{24} . First I tried to directly insert the Wen-Yu Cd given in the Theory Guide into the expression:

C_D = \frac{24}{\alpha_g Re_s} (1 + 0.15 (\alpha_g Re_s)^{0.687})


However, I was not able to recreate the results of the original Drag Law. So I guess I will need another formulation for Cd? Maybe someone has experience with that? I am not sure which kind of expression I should use for : \frac{18 C_D Re }{24} in case of Wen-Yu.
The code I was using.:

Code:
#include "udf.h" 

#include "dpm.h" 

DEFINE_DPM_DRAG(particle_drag_force,Re,tp) 

{ real drag_force, void_s,void_g; 

 cell_t cell; Thread *thread_s, *mix_thread;  

cell=P_CELL(tp); 
 
 mix_thread=P_CELL_THREAD(tp);  

thread_s = THREAD_SUB_THREAD(mix_thread,1); 

void_s = C_VOF(cell, thread_s);  void_g =1-void_s ; 
 //drag_force = 18.0 * pow(void_g,-2.65) * (1 + 0.15 * pow(void_g * Re,0.687))/void_g ;
 
drag_force = 18.0 * (1 + 0.15 * pow(void_g * Re,0.687))/void_g ; 
return (drag_force); }
Thank You and Best Regards
blerli_91 is offline   Reply With Quote

 

Tags
ddpm drag law, define_dpm_drag, udf drag law, wen-yu


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 Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
WenYu drag model code implimentation dinh OpenFOAM Programming & Development 5 May 23, 2024 02:56


All times are GMT -4. The time now is 04:49.