TAGGED: gradient, multiple-species, udf, vof
June 16, 2022 at 1:58 amshitizsehgalSubscriberHi,
I am interested in using species gradient of one of the species in a mixture. I am trying to find the 'right' and accurate way to access species gradient in ANSYS Fluent. A quick web search tells me that a common way to do that is:
1. Type (rpsetvar 'species/save-gradients? #t)
2. Write a DEFINE_ADJUST udf to access gradients. This UDF has Alloc_Storage_Vars commands that can be typically used for any scalar including Volume fraction, temperature, and species (my guess).
I have been able to access Volume fraction and Temperature gradients using DEFINE_ADJUST UDF and validate the results for a condensation problem. I used DEFINE_SOURCE UDFs to write energy and mass source terms.
Now, I am interested in a problem that considers species gradients. My question is:
1. Is DEFINE_ADJUST the only way? I tried to run a fluid flow simulation to access the gradients using DEFINE_ADJUST and was able to access them. However, saving the cas and data and running the simulaton after re-opening saved cas and data files leads to SEGMENTATION faults. To avoid this, I have unload and load the UDF with species gradients and then run my simulation.
Can someone please tell me as to how can I prevent this problem? I didn't face any issues when working with temperature and volume fraction gradients using the same UDF. Any help will be appreciated.
June 17, 2022 at 12:02 pmDrAmineAnsys EmployeeThere is no unique way but I recommend to follow the steps described in the official Anys Fluent Customization manual to access gradients in general and espcially species gradients. One you follow that you have the gradients of species without the need to allocate anything.
June 21, 2022 at 11:35 amDrAmineAnsys Employee
June 21, 2022 at 3:56 pmshitizsehgalSubscriber
I just saw your comment today because I didn't get any notification that someone had commented on the post. I will try your suggested way and comment here to update you. So, if I understand it correctly, you are suggesting that I use the method in Fluent Customization Manual and access the gradients in UDF as needed without writing the DEFINE_ADJUST UDF? Is that what you are saying?
- You must be logged in to reply to this topic.
Boost Ansys Fluent Simulations with AWS
Computational Fluid Dynamics (CFD) helps engineers design products in which the flow of fluid components is a significant challenge. These different use cases often require large complex models to solve on a traditional workstation. Click here to join this event to learn how to leverage Ansys Fluids on the cloud, thanks to Ansys Gateway powered by AWS.
Earth Rescue – An Ansys Online Series
The climate crisis is here. But so is the human ingenuity to fight it. Earth Rescue reveals what visionary companies are doing today to engineer radical new ideas in the fight against climate change. Click here to watch the first episode.
Subscribe to the Ansys Blog to get great new content about the power of simulation delivered right to your email on a weekly basis. With content from Ansys experts, partners and customers you will learn about product development advances, thought leadership and trends and tips to better use Ansys tools. Sign up here.
- Suppress Fluent to open with GUI while performing in journal file
- Floating point exception in Fluent
- What are the differences between CFX and Fluent?
- Heat transfer coefficient
- Getting graph and tabular data from result in workbench mechanical
- The solver failed with a non-zero exit code of : 2
- Difference between K-epsilon and K-omega Turbulence Model
- Time Step Size and Courant Number
- Mesh Interfaces in ANSYS FLUENT
- error in cfd post
© 2023 Copyright ANSYS, Inc. All rights reserved.