2.3.11.  DEFINE_EDC_SCALES

2.3.11.1. Description

In ANSYS Fluent, the Eddy Dissipation Concept (EDC) model closes the species transport equations according to the terms given in The Eddy-Dissipation-Concept (EDC) Model in the Fluent Theory Guide. This UDF allows your to modify the coefficients (Equation 7–28) and (Equation 7–29) and the term (Equation 7–29).

2.3.11.2. Usage

DEFINE_EDC_SCALES (name, c, t, c1, c2, calc_tau, tau)


Important:
  • Note that all the arguments of a DEFINE macro need to be placed on the same line in your source code. Splitting the DEFINE statement into several lines will result in a compilation error.

  • DEFINE_EDC_SCALES functions can be executed only as compiled UDFs.


Argument Type

Description

symbol name

UDF name.

cell_t c

Cell or face index.

Thread *t

Pointer to the cell or face thread.

real *c1

Pointer to coefficient .

real *c2

Pointer to coefficient .

int calc_tau

Integer that indicates whether tau will be calculated (tau will be computed if calc_tau is set to a non-zero value).

real *tau

Pointer to value.

Function returns

void

There are seven arguments to DEFINE_EDC_SCALES: name, c, t, c1, c2, calc_tau, and tau. You supply name, the name of the UDF. The variables c, t, c1, c2, calc_tau, and tau are passed by the ANSYS Fluent solver to your UDF. The values of c1, c2 and tau passed by the ANSYS Fluent solver are those used by the solver unless they are reset by this routine. The routine may reset any or all of these values.

The calc_tau indicator is provided for efficiency purposes as DEFINE_EDC_SCALES will be called several times by the solver but will not always use the tau value. Enclosing the tau calculation with if (calc_tau) {}, as in Example, will thus maximize the efficiency of this routine.

2.3.11.3. Example

The following example is a source code template where the DEFINE_EDC_SCALES function is used to set the EDC model scales.

/*******************************************************************
 Example UDF that demonstrates the use of DEFINE_EDC_SCALES to set the 
EDC model scales.
 ********************************************************************/
 #include <udf.h>
 
 DEFINE_EDC_SCALES(edc_scales, c, t, c1, c2, calc_tau, tau)
 {
   real ted = MAX(C_D(c,t), 1.0e-03);

   *c1 = 2.1337;
   *c2 = 0.4082;

   if (calc_tau)
     tau = (*c2)*sqrt(C_MUL(c,t)/(ted*C_R(c,t)));
 } 

2.3.11.4. Hooking a DEFINE_EDC_SCALES UDF to ANSYS Fluent

After you have compiled and loaded (Compiling UDFs) the DEFINE_EDC_SCALES UDF and enabled the Eddy Dissipation Concept model, the name of the argument that you supplied as the first DEFINE macro argument will become visible and selectable in the Options group box of the Species Model dialog box in ANSYS Fluent. See Hooking DEFINE_FLAMELET_PARAMETERS UDFs for details.


Release 18.2 - © ANSYS, Inc. All rights reserved.