|
[Sponsors] |
August 28, 2015, 15:32 |
c_udmi solver
|
#1 |
New Member
zahraorveh
Join Date: Oct 2014
Posts: 5
Rep Power: 11 |
i write this udf
#include "udf.h" #include "sg.h" #include "sg_mphase.h" #include "flow.h" #include "mem.h" #include "metric.h" #include "unsteady.h" #define K 3.65e-4 #define gama 0.146 #define sigma 4.796e-4 #define alpha 1.935e-3 #define beta 5.7848e-7 #define kx 0.27318 #define kw 0.2 DEFINE_ADJUST(adjust_for_force, domain) { Thread **pt; Thread *t; cell_t c; Domain *pDomain = DOMAIN_SUB_DOMAIN(domain,1); real x,D; real xc[ND_ND]; begin_c_loop(c,t) C_CENTROID(xc,c,t); C_UDMI(c,t,0)=500*exp(-1*(kx*(C_UDSI(c,t,0))+kw)*(0.04-xc[1])); D=alpha*beta*pow(C_UDMI(c,t,0),2)+(alpha+beta)*sig ma*C_UDMI(c,t,0)+sigma*gama; C_UDMI(c,t,1)=(sigma*gama+C_UDMI(c,t,0)*beta*sigma )/D; C_UDMI(c,t,2)=alpha*sigma*C_UDMI(c,t,0)/D; C_UDMI(c,t,3)=(alpha*beta*pow(C_UDMI(c,t,0),2))/D; C_UDMI(c,t,4)=K*gama*C_UDMI(c,t,2); end_c_loop(c,t) } it has to calculate 5 c_udmi for each cell of cfd computational cell. but it doesn't work |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Fluent Adjoint Solver? | ex10148 | FLUENT | 16 | September 28, 2018 08:11 |
thobois class engineTopoChangerMesh error | Peter_600 | OpenFOAM | 4 | August 2, 2014 09:52 |
Divergence problem | Smaras | FLUENT | 13 | February 21, 2013 05:03 |
3d vof | Smaras | FLUENT | 2 | February 19, 2013 06:58 |
why the solver reject it? Anyone with experience? | bearcat | CFX | 6 | April 28, 2008 14:08 |