Creating a Field Function for the Grid Velocity
A radial velocity is to be set at the cylinder wall using a field function based on the axial position.

The equation for this profile is:
where is the radial velocity in m/s and is the z (or axial) coordinate of the face centroid in m.
The field function for this profile is implemented as follows:
- Right-click the node and select .
- Rename the Cylinder Radial Velocity. node to
-
Select the
Cylinder Radial Velocity node and set the following properties:
Property Setting Function Name CylinderRadialVelocity Dimensions Velocity Definition [(($$Position("Cylindrical 1")[2] < 2) ? -0.125*$$Position("Cylindrical 1")[2] : -0.125*(4-$$Position("Cylindrical 1")[2])), 0, 0]
Note: the function $$Position("Cylindrical 1") returns a cartesian vector of the position coordinates in local coordinate system ; the subscript operator [] is appended to access a single component of the position vector (with an index of [0], [1], or [2]).