|
[Sponsors] |
Heat generation is depend on x value and time. |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
September 5, 2010, 14:17 |
Heat generation is depend on x value and time.
|
#1 |
New Member
Omur
Join Date: Mar 2010
Posts: 4
Rep Power: 16 |
Hi,
Heat generation is depend on x value and time in my simulation. How to add x variation below code? #include "udf.h" DEFINE_SOURCE(heat_gen_time,cell,thread,dS,eqn) { real source; real time; time = CURRENT_TIME; source = 86.44*pow(time,-.3); dS[eqn] = -25.932*pow(time,-1.3); return source; } |
|
September 20, 2010, 08:08 |
how i can solve this error in fluent heat vulometric source
|
#2 |
New Member
behzad
Join Date: Sep 2010
Posts: 3
Rep Power: 16 |
#include "udf.h"
#include "defines.h" #define Q 20000000 #define H 5// flame hight above floor #define D .5//cell size #define DX D #define DY D #define DZ D DEFINE_SOURCE(heat_source, c, t, dS, eqn) { real x[ND_ND]; real V=DX*DY*DZ; C_CENTROID(x,c,t); if (fabs(x[0])<DX/2 && fabs(x[2])<DZ/2 && fabs(x[1]+DY)<H){ return Q/V; } else { return 0.0; } } ************************************************** ** ************************************************* error how i can solve this error ************************************************** ******* chip-exec: heat_source: wrong return type: void udf function expected Error: 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: () |
|
October 26, 2010, 16:46 |
|
#3 |
New Member
Omur
Join Date: Mar 2010
Posts: 4
Rep Power: 16 |
Hi,
Heat generation is depend on x value in my simulation. What is problem in my udf? #include "udf.h" #define pi 3.141592653589793238462643383279502884197169399375 10 DEFINE_SOURCE(heat_gen_x,cell,thread,dS,eqn) { real source; real x [ND_ND]; real a; face_t f; begin_f_loop(f,thread) { F_CENTROID(x, f, thread); a=x[0]; source = 6500000*1.2*cos(pi*(1.0267*((2*(a-1.189)/0.793)-1))); } end_f_loop(f,thread) } |
|
|
|