|
[Sponsors] |
UDF for Syamlal obrein symmetric grag model (solid-solid) |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
October 23, 2018, 13:47 |
UDF for Syamlal obrein symmetric grag model (solid-solid)
|
#1 |
Member
Muhammad Ali Uzair
Join Date: Sep 2017
Posts: 44
Rep Power: 9 |
Hi,
Has anyone here written a udf for syamlal obrein symmetric model for solid solid interaction? Need help urgently. I dont know how to include radial distribution function into that model. Please do reply |
|
October 23, 2018, 15:07 |
explanation
|
#2 |
Member
Muhammad Ali Uzair
Join Date: Sep 2017
Posts: 44
Rep Power: 9 |
I am simulating a three phase flow, and i want to write a udf for solid solid interaction.(SYAMLAL OBREIN SYMMETRIC DRAG MODEL)
I am facing two problems. 1) when i interpret udf, it shows me undeclared variable line 19: l_col: undeclared variable AND `DEFINE_EXCHANGE_PROPERTY' used with too many (6) args 2) I dont know how to include radial distribution function in the udf Can someone please point out the flaws and how to fix them UDF is as follows #include "udf.h" #define diam2 0.0005 #define diam3 0.005 #define PI 3.141592654 DEFINE_EXCHANGE_PROPERTY(custom_drag,cell,mix_thre ad,g_col,s_col,l_col) { Thread *thread_g, *thread_l, *thread_s; real x_vel_l, x_vel_s, y_vel_l, y_vel_s, abs_v, slip_x, slip_y,rho_l, rho_s; real void_g,void_l,void_s,k_l_s; /* find the threads for the gas phase */ /* and biomass (solid phase one) */ /* and sand (solid phase two) */ thread_g = THREAD_SUB_THREAD(mix_thread, g_col);/* gas phase */ thread_l = THREAD_SUB_THREAD(mix_thread, l_col);/* solid phase one */ thread_s = THREAD_SUB_THREAD(mix_thread, s_col);/* solid phase two*/ /* find phase velocities and properties*/ x_vel_l = C_U(cell, thread_l); y_vel_l = C_V(cell, thread_l); x_vel_s = C_U(cell, thread_s); y_vel_s = C_V(cell, thread_s); slip_x = x_vel_l - x_vel_s; slip_y = y_vel_l - y_vel_s; rho_l = C_R(cell, thread_l); rho_s = C_R(cell, thread_l); /*compute slip*/ abs_v = sqrt(fabs(slip_x*slip_x + slip_y*slip_y)); void_g = C_VOF(cell, thread_g);/* gas phase vol frac*/ void_s=1.-void_g-void_l; void_l=1.-void_g-void_s; k_l_s=(3*(1+0.9)*(PI*0.5)*void_s*rho_s*void_l*rho_ l*pow(diam2+diam3,2)*abs_v)/(2*PI*((rho_l*pow(diam2,3))+(rho_s*pow(diam3,3)))) ; return k_l_s; } |
|
October 25, 2018, 00:56 |
|
#3 |
Senior Member
Alexander
Join Date: Apr 2013
Posts: 2,363
Rep Power: 34 |
where did you get this macro?
from Ansys Fluent customization manual: Code:
DEFINE_EXCHANGE_PROPERTY (name, c, mixture_thread,second_column_phase_index,first_column_phase_index) best regards |
|
October 25, 2018, 05:59 |
|
#4 | |
Member
Muhammad Ali Uzair
Join Date: Sep 2017
Posts: 44
Rep Power: 9 |
Quote:
P.S just a beginner :-) I got it from this forum, shared by someone. |
||
Tags |
drag, eulerian multiphase model, fluent, multiphase flow, udf |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Thermal non-equilibrium porous media model with conjugate heat transfer | Hexahedron | FLUENT | 9 | February 22, 2023 03:55 |
Can we write UDF for secondary phase droplet/bubble diameter in Eulerain model? | Navier Stoke | Fluent UDF and Scheme Programming | 1 | September 7, 2017 16:02 |
What viscosity to use for solid phase in VOF model | redwanamit034 | FLUENT | 0 | June 14, 2017 18:09 |
How model radiation of both solid wall and fluid£¿ | Harry Qiu | FLUENT | 2 | February 4, 2013 00:04 |
Convective Heat Transfer - Heat Exchanger | Mark | CFX | 6 | November 15, 2004 16:55 |