-
-
October 16, 2024 at 1:41 pm
psantoch
SubscriberHi there,
I have a UDF that defines particle source terms in Fluent 17 using DEFINE_DPM_SOURCE with the pressure-based solver.
I need to get the mass flow into the cell containing the particle for this calculation.
I tried using F_FLUX but I keep getting a segmentation fault error, is the mass flow not stored for faces of cells?
The relevant code that causes the crash (if I remove the "f_flow = F_FLUX(f,f_t);" line it doesn't crash):
DEFINE_DPM_SOURCE(Source, c, t, S, strength, p)
{
Thread*f_t;
face_t f;
int n;
real f_flow;
c_face_loop(c, t, n)
{
f = C_FACE(c,t,n);
f_t = C_FACE_THREAD(c,t,n);
f_flow = F_FLUX(f,f_t);
}
} -
October 16, 2024 at 2:47 pm
Rob
Forum ModeratorI'd move from R17 to 2024R2 for a start. F_FLUX is defined here https://ansyshelp.ansys.com/account/Secured?returnurl=/Views/Secured/corp/v242/en/flu_udf/flu_udf_DataAccessMacros.html
-
- You must be logged in to reply to this topic.
-
5649
-
1885
-
1404
-
1303
-
1021
© 2026 Copyright ANSYS, Inc. All rights reserved.