CFX Expression Language – Part 2: Augmenting Material Property Assignments in ANSYS CFX

Categories:

In a previous entry we introduced CFX Expression Language, CEL.  You can view that post here

Before we get started, there are some key things to remember:

  1. Expressions can be easily created by right-clicking in the Expressions tab after double clicking on Expressions in the CFX Pre object tree.
  2. Expressions and their contents are case sensitive.

In this next part of the series, we’ll show how to use CEL to augment your material property definitions in CFX. If material properties are constants then their input is straightforward. However, if the properties are defined as equations, we can use CEL to input those equations in CFX.

For example, if viscosity is defined as a function of shear strain rate, we need to define viscosity using an equation that captures that relationship, such as

m = K * gn-1

Below are shown two ways in which that equation can be captured using CFX Expression Language, visc1 and visc2. The second equation, visc2, is more flexible in that we have defined the constant terms as expressions themselves.

clip_image002

It’s always a good idea to verify the input. Most expressions can be easily plotted by clicking on the Plot tab in the Details view. Here is a plot of the viscosity vs. shear strain rates between 0 and 1, as calculated by expression visc2:

clip_image004

Similarly, the Evaluate tab can be used to evaluate the expression for desired values of the inputs.

So, we have defined an expression for a material property, viscosity in this case. How do we get CFX to use that expression? In the material property input, we click on the expression icon to the right of the particular material property we are defining, then enter the name of the expression, as shown here for expression visc2:

clip_image006

Summing it up, we can use CFX Expression Language to define material property equations for non-constant material values. In the next installment we will look at how to use CEL to define changing boundary conditions, such as a ramped load.

Get Your Ansys Products & Support from the Engineers who Contribute to this Blog.

Technical Expertise to Enable your Additive Manufacturing Success.

Share this post:

Upcoming Events

Jun 18
, 2026
Best Practices for Running Ansys Fluent on GPUs - Webinar
Jun 18
, 2026
E-Mobility and Clean Energy Summit
Jun 22
- Jun 25
, 2026
Automate 2026
Jun 30
, 2026
Ansys 2026 R1: Aeroacoustic Modeling with the Fluent GPU Solver - Webinar
Jun 30
, 2026
UAS Additive Strategies
Jul 15
, 2026
Arizona Aerospace Summit
Aug 10
- Aug 11
, 2026
2026 CEO Leadership Retreat + Golf Tournament
Aug 23
- Aug 26
, 2026
Small Satellite Conference 2026
Aug 24
- Aug 27
, 2026
Nuclear Energy Conference & Expo - 2026
Aug 31
- Sep 03
, 2026
Turbine Engine Technology Symposium - 2026
Sep 14
- Sep 19
, 2026
IMTS 2026
Oct 21
, 2026
2026 Southern Arizona Tech + Business Expo
Nov 18
, 2026
2026 Governor’s Celebration of Innovation

Contact Us

Most of our customers receive their support over the phone or via email. Customers who are close by can also set up a face-to-face appointment with one of our engineers.

For most locations, simply contact us: