August 10, 2022 at 7:46 americ1234598765Subscriber
This is the problem about acessing cell value, such as C_U , C_T ,and so on , between two cells divided by an interface or interior.
Picture below is a simple 2D mesh, the way I acess the cell centroid is providing a "Face thread" to UDF, which could be obtained from interface/interior ID. The problem is , which cell value did I actually get? Is the above one adjacent to the fluid zone, or the one adjacent to the porous zone?
P.S: There's only F_C0 and F_C1 in UDF Manual, which is not the cell value. Interstingly, I got the null value of F_C1 when I replaced F_U(c0,t0) with F_U(c1,t1).
Please help me to clarify which cell is chosen by UDF when the boundary is interface and interior, respectively.
Thanks a lot!
August 10, 2022 at 10:23 amRobAnsys Employee
Remember "interface" and "interior" are different. For the former, it's an external boundary so only c0 exists, for an interior c0 and c1 are available.
Example 3, https://ansyshelp.ansys.com/account/Secured?returnurl=/Views/Secured/corp/v221/en/flu_udf/flu_udf_sec_define_dpm_bc.html shows it in use.
August 10, 2022 at 1:39 pmeric1234598765Subscriber
Thanls for the reply, I am clear on interface now.
However, I'm still not get it that which centroid Fluent would choose when using the cell macro , since there are two cells sharing one face only.
Altough the values of both cell centroid are nearly the same when they are small enough, it is better to make myself more clear about what ansys is doing.
August 10, 2022 at 2:03 pmeric1234598765Subscriber
Ah..., Hi everyone,
I've checked the "c1" thread's ID by usnig THREAD_ID(t1) , which returns the cell zone value of porous, wheret1 = THREAD_T1(t);and t is the thread of the face boundary. This indicates that "c0' and "c1" in the above picture is upside down, and Fluent take cell adjacent to fluid zone as "c0" in this case.
The other question about c1 is there is no value in "c1" cell when I called cell or face macro,which ends to SIGSEGV, altough THREAD_ID(t1) do return value.
Looking forward any help
August 10, 2022 at 2:36 pmRobAnsys Employee
I think you'll need to look at some of the True/False options, that way if c1 isn't present the solver ought to skip any maths.
This might help too, https://ansyshelp.ansys.com/account/Secured?returnurl=/Views/Secured/corp/v221/en/flu_udf/x1-5160004.5.html
- You must be logged in to reply to this topic.
Simulation World 2022
Check out more than 70 different sessions now available on demand. Get inspired as you hear from visionary companies, leading researchers and educators from around the globe on a variety of topics from life-saving improvements in healthcare, to bold new realities of space travel. Take a leap of certainty and check out a session today here.
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
- Heat transfer coefficient
- What are the differences between CFX and Fluent?
- Floating point exception in Fluent
- Time Step Size and Courant Number
- Difference between K-epsilon and K-omega Turbulence Model
- Floating point exception
- The solver failed with a non-zero exit code of : 2
- How to model free convection warming of liquid in a plastic bag