Property Macro, UDF, Viscosity Relation CFD Simulation
$100.00 Student Discount
- The problem numerically simulates the water viscosity exchange based on temperature using ANSYS Fluent software.
- We design the 3-D model with the Design Modeler software.
- We mesh the model with ANSYS Meshing software.
- The mesh is Structured, and the element number equals 133,400.
- We use the User-Defined Function (UDF) to define a viscosity relation.
- We use the Property Macro for UDF.
If you decide to use PayPal to pay, you will get a 5% discount on your order.
To Order Your Project or benefit from a CFD consultation, contact our experts via email ([email protected]), online support tab, or WhatsApp at +44 7443 197273.
There are some Free Products to check our service quality.
If you want the training video in another language instead of English, ask it via [email protected] after you buy the product.
In this project, we performed a numerical simulation using ANSYS Fluent software’s User-Defined Function (UDF). For this CFD product, we used Property Macro to write UDF programming.
This product is the 10th chapter of the User-Defined Function (UDF) Training Course.
We considered a simple pipe with water fluid flowing inside. The water flow enters the pipe at a low speed and is affected by the thermal boundary condition of the pipe wall.
Water enters the pipe with a temperature of 280 K, and the wall has a constant temperature of 300 K. So the temperature of the water flow inside the pipe changes. Usually, an increase in temperature in fluids causes a decrease in viscosity. So, we must define a relation according to which the viscosity varies with temperature. For this purpose, we use a function describing the viscosity regarding temperature.
We simulated the current model based on the CFD method by ANSYS Fluent software, modeling the geometry in 3D with Design Modeler software.134,400 Structured cells are created by ANSYS Meshing software
In this project, we need to define a function of viscosity variations in terms of temperature. Since the water viscosity value inside the pipe is not constant, we need to define a User-Defined Function (UDF) to define the viscosity relations. We must use the Property Macro (DEFINE_PROPERTY macro) for this UDF. The Property Macro has many applications in simulations. This macro defines the value of material properties like density, thermal conductivity, viscosity, etc., in terms of some variables.
The viscosity relations we use are defined as follows. According to these relations, viscosity is considered in three different temperature ranges. If the temperature is less than 285 K, the viscosity equals a constant value of 0.001 kg/m.s. If the temperature exceeds 290 K, the viscosity equals a constant value of 0.0015 0.0015 kg/m.s.But if the temperature is between 285 and 290 K, the following equation must be used to define the viscosity value in terms of temperature.
After completing the calculation, we will review the results. To analyze the results, we obtain some contours and some plots. We obtain the dynamic viscosity contour at several passing planes of the model domain. Then, we obtained the plot of dynamic viscosity changes in terms of the temperature at a central plane of the model domain.
The results correctly showed that the changes in viscosity correspond to temperature. The temperature was higher near the pipe walls, and the viscosity decreased. While in the central parts of the pipe, the temperature was lower, and then the viscosity increased.
We conclude that we performed the current numerical simulation correctly, and our UDF worked correctly.