TAGGED: heat-source, udf-fluent, wall
-
-
February 8, 2022 at 12:23 pm
Ferrero
SubscriberHello to everybody,
I am simulating a 2D axisymmetric CFD system with volumetric power generation coming from neutronic irradiation. In my system there is no localized source, but the power distribution (negative exponential) is dependent on the distance from a specified boundary, which is non-moving but has a complex shape.
I tried to write some UDFs to compute the distance from a given boundary, but the main problem is that if I use a face loop and a cell loop in the same function I get a SIGSEGV error, because of the different natures of the pointer. Is there something that I am missing? Is there a simpler method to compute the distance from a boundary (which is different from the nearest wall distance) that I am missing?
Thank you in advance.
February 8, 2022 at 2:36 pmDrAmine
Ansys EmployeeWorkaround you change the type of the boundary to wall. In global UDM you store the value of wall distance to that wall. Then you switch back to whatever. Will that work for you (before solving Laplace Equations to have distances to boundaries calculated).
February 8, 2022 at 3:07 pmFerrero
SubscriberI have a domain where fluid flows and I have to assign power Source to cells, dependent on the cell distance from a specific face. If I use a UDM I still have to point to the face and use the F_UDMI(f,t,i) MACRO to access the stored F_CENTROID values, while also acceding to a cell (for source MACRO) and if I am not mistaken, this causes me a SIGSEGV error. Probably this is a very easy task yet I have not resolved the problem yet.
Thank you for your assistance
February 8, 2022 at 3:53 pmFerrero
SubscriberThe only MACRO I found to compute the distance between cell and faces is the BOUNDARY_FACE_GEOMETRY macro, and in the example in the User Guide (ANSYS Fluent UDF Manual) it is used coupled with the connectivity macro F_C0 (inside a begin_f_loop inside a PROFILE macro). F_C0 sees only the nearest cell to a face, and I want to access the distance for all cells. Therefore this is not a solution to my problem.
The simplest method would be: access to a cell loop in a SOURCE macro, then loop over all faces of the specified boundary and update the distance value if this one is smaller than the smallest value registered. Best if this is done just once with a DEFINE_ON_DEMAND probably. But this method tries to access both faces and cells giving me a SIGSEGV error.
I hope that this can help us to find an effective solution
Viewing 3 reply threads- You must be logged in to reply to this topic.
Ansys Innovation SpaceBoost 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.
Ansys Blog
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.
Trending discussions- 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
Top Contributors-
3930
-
2649
-
1865
-
1272
-
610
Top Rated Tags© 2023 Copyright ANSYS, Inc. All rights reserved.
Ansys does not support the usage of unauthorized Ansys software. Please visit www.ansys.com to obtain an official distribution.
-