Ansys Assistant will be unavailable on the Learning Forum starting January 30. An upgraded version is coming soon. We apologize for any inconvenience and appreciate your patience. Stay tuned for updates.

Ansys Learning Forum Forums Discuss Simulation Fluids Fluid velocity in dpm_drag Reply To: Fluid velocity in dpm_drag

christoph.graf
Subscriber

So I think I got it working now. Apparently TP_CELL_THREAD returns the mixture thread, not the particle thread. I don't understand why that is the case and in my opinion the UDF guide says otherwise (Table 3.29), but it doesn't crash and gives me plausible values.

My code is now (declarations as above):

mixthread = TP_CELL_THREAD(tp);
gthread = THREAD_SUB_THREAD(mixthread,0);

c = TP_CELL(tp);

urel = C_U(c,gthread);

[bingo_chatbox]