### 14.5.2. Profile Data and CEL Functions

Profile data can be used to define a boundary condition based on a distribution of appropriate values.

#### 14.5.2.1. Types of Discrete Profiles

- 1D profile uses one spatial coordinate to define the data position; for example, x, y, z, or a cylindrical value. This could be used to describe the axisymmetric flow down a cylindrical pipe (that is, the data values for a value of ‘r’).

- 2D profile uses two spatial coordinates (Cartesian or polar); for example, (x, y), (x, z), (r, t), (a, t), and so on. If you are importing the data from a 2D code on a planar boundary, you may want to use this as a boundary condition in a 3D case in CFX.

- 3D profile uses three spatial coordinates; for example, (x, y, z) or (r, t, a). Among various uses of 3D Profile Data are boundary conditions, spatially varying fluid properties, Additional Variables, or equation sources.

#### 14.5.2.2. Profile Data Format

A profile data file is formatted as follows:

    # Comment line
    # The following section (beginning with [Name] and ending with
    # [Data]) represents one profile, which can be repeated
    # to define multiple profiles.
    [Name]
    My Boundary
    [Spatial Fields]
    r, theta, z
    .
    .
    .
    [Data]
    X [ m ], Y [ m ], Z [ m ], Area [ m^2 ], Density [ kg m^-3 ]
    -1.773e-02, -5.382e-02, 6.000e-02, 7.121e-06, 1.231e+00
    -1.773e-02, -5.796e-02, 5.999e-02, 5.063e-06, 1.231e+00
    .
    .
    .
    # -------- end of first profile 'My Boundary'----------
    [Name]
    Plane 2
    .
    .
    .

Notes about the profile data format:

- The name of each locator is listed under the `[Name]` heading.

- The names of the fields are case-insensitive (that is, `[data]` and `[Data]` are acceptable).

- The names of variables used in the data fields are case sensitive.

  For example, `u [m]` is a valid x velocity component, whereas `U [m]` is an unrecognized field name. You have to map this unrecognized field name with a valid variable name when loading into CFX-Pre. This is consistent with the use of CEL elsewhere.

- Comments in the file are preceded by `#` (or `##` for the CFX polyline format) and can appear anywhere in the file.

- Commas must separate all fields in the profile. Any trailing commas at the end of a line are ignored. Any additional commas within a line of data will be a syntax error.

- Blank lines are ignored and can appear anywhere in the file (except between the `[<data>]` and first data line, where `<data>` is one of the key words in square brackets shown in the data format).

- If any lines with text are included above the keyword `[Name]`, a syntax error will occur. Such lines should be preceded by `#` character to convert them into comments.

- Multiple data sets are permitted within the same file by repeating the sequence of profiles; each profile begins with keyword `[Name]`.

- Point coordinates and the corresponding variable values are stored in the `[Data]` section.

- `[Spatial Fields]` can contain 1, 2, or 3 values, corresponding to 1D, 2D, or 3D data.

- Within the `[Data]` section, the Spatial Fields must be the first entries in each row of data, before the other variables.

- The data file has a `.csv` extension for compatibility with other software packages.

  When this data file is read in, it is checked for any format violations; physics errors are shown for such situations.

Note: A file exported from CFD-Post in a user-specified coordinate system contains a coordinate frame (`[CoordFrame]`) section. The coordinate frame definition is written to the profile file; CFX-Pre defines the coordinate frame when you initialize the data.

Additional information on profile data is available:

- Physics Message Window

- RULES and VARIABLES Files in the CFX-Solver Manager User's Guide

- Profile Boundary Conditions in the CFX-Solver Modeling Guide

#### 14.5.2.3. Multiphase Boundary Condition Example

The syntax for using profile data in CEL expressions is described in Defining User Functions from Profile Data or Interpolation (From File) Functions.

Consider a multiphase boundary condition set up using the following:

- The profile data file has a profile named `myProfile`

- One of the data fields is `Temperature [K]`

CFX-Pre enables a function such as `myProfile.water.Temperature(x,y,z)` to refer to a data field stored in the profile. This derived value can be assigned to a parameter, such as `Fixed Temperature`.

The expressions that are automatically generated in CFX-Pre for profile boundaries are simply the expressions in terms of interpolation functions. Modify them in the same way as a normal CEL expression.

For example, the expression `myProfile.Temperature(x,y,z)` could be modified to `2*myProfile.Temperature(2x,y,z)`. For details, see Profile Boundary Conditions in the CFX-Solver Modeling Guide.

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