|
[Sponsors] |
udf-Surface Reaction Rate-parse error in line 34 |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
November 6, 2014, 03:44 |
udf-Surface Reaction Rate-parse error in line 34
|
#1 |
New Member
hena
Join Date: Aug 2014
Posts: 1
Rep Power: 0 |
hello all,
i m new to c. i m trying to write Udf for surface reaction rate, which is showing parse error in line 34. can any buddy help to correct this. #include "udf.h" /* ARRHENIUS CONSTANTS */ #define PRE_EXP 1e+19 #define ACTIVE 2.22e+05 #define BETA 0.0 real arrhenius_rate(real temp) { return PRE_EXP*pow(temp,BETA)*exp(-ACTIVE/(UNIVERSAL_GAS_CONSTANT*temp)); } /* Species numbers. Must match order in Fluent panel */ #define h2o 0 #define n2 1 #define co 3.5 #define c7h5n3o6 1 #define c 3.5 #define NUM_SPECS 5 /* Reaction Exponents */ #define h2o_EXP 0 #define n2_EXP 0 #define co_EXP 0 #define c7h5n3o6_EXP 1 #define c_EXP 0 #define MW_c7h5n3o6 227.13 #define STOIC_c7h5n3o6 1.0 /* Reaction Rate Routine */ real reaction_rate(cell_t c,Thread *cthread,real mw[],real yi[]) { real concenc7h5n3o6 = C_R(c,cthread)*(yi[c7h5n3o6]/mw[c7h5n3o6]); return arrhenius_rate(C_T(c,cthread))*pow(real concenc7h5n3o6,c7h5n3o6_EXP); } |
|
November 10, 2014, 02:48 |
|
#2 |
New Member
hana
Join Date: May 2014
Posts: 23
Rep Power: 12 |
First of all,
there is no type of UDF function you upload real reaction_rate(cell_t c,Thread *cthread,real mw[],real yi[]) UDF function name is like this Section 2.3.1: DEFINE CHEM STEP Section 2.3.2: DEFINE CPHI Section 2.3.3: DEFINE DIFFUSIVITY Section 2.3.4: DEFINE DOM DIFFUSE REFLECTIVITY Section 2.3.5: DEFINE DOM SOURCE Section 2.3.6: DEFINE DOM SPECULAR REFLECTIVITY Section 2.3.7: DEFINE GRAY BAND ABS COEFF Section 2.3.8: DEFINE HEAT FLUX Section 2.3.9: DEFINE NET REACTION RATE Section 2.3.10: DEFINE NOX RATE Section 2.3.11: DEFINE PR RATE Section 2.3.12: DEFINE PRANDTL UDFs Section 2.3.13: DEFINE PROFILE Section 2.3.14: DEFINE PROPERTY UDFs Section 2.3.15: DEFINE SCAT PHASE FUNC Section 2.3.16: DEFINE SOLAR INTENSITY Section 2.3.17: DEFINE SOURCE Section 2.3.18: DEFINE SOX RATE Section 2.3.19: DEFINE SR RATE Section 2.3.20: DEFINE TURB PREMIX SOURCE Section 2.3.21: DEFINE TURBULENT VISCOSITY Section 2.3.22: DEFINE VR RATE Section 2.3.23: DEFINE WALL FUNCTIONS |
|
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Defining reaction rate with multiple surface reaction | Fred Marias | FLUENT | 1 | September 12, 2013 04:56 |
1.7.x Environment Variables on Linux 10.04 | rasma | OpenFOAM Installation | 9 | July 30, 2010 04:43 |
Problems of Duns Codes! | Martin J | Main CFD Forum | 8 | August 14, 2003 23:19 |
error while compiling the USER Sub routine | CFD user | CFX | 3 | November 25, 2002 15:16 |
CFX4.3 -build analysis form | Chie Min | CFX | 5 | July 12, 2001 23:19 |