In many cases, the UDF source code that you will write for a single-phase flow will be the
same as for a multiphase flow. For example, there will be no differences between the C or C++
code for a single-phase boundary profile (defined using DEFINE_PROFILE)
and the code for a multiphase profile, assuming that the function is accessing data
only from the phase-level domain to which it is hooked in the graphical
user interface. If your UDF is not explicitly passed a pointer to the thread
or domain structure that it requires, you will need to use a special multiphase-specific macro
(for example, THREAD_SUB_THREAD) to retrieve it. This is discussed in
Additional Macros for Writing UDFs.
See Appendix B: DEFINE Macro Definitions for a complete list
of general-purpose DEFINE macros and multiphase-specific DEFINE macros that can be used to define UDFs for multiphase
model cases.