CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   FLUENT (https://www.cfd-online.com/Forums/fluent/)
-   -   problem with writing UDF for dpm (https://www.cfd-online.com/Forums/fluent/94433-problem-writing-udf-dpm.html)

massoudepsilon November 15, 2011 22:59

problem with writing UDF for dpm
 
Hi,

is there anyone who knows that how I can understand whether a cell is host of a particle in dpm model?

thank you so much in advance
.

Amir November 16, 2011 02:48

Hi,

if (c == P_CELL(p)) ....

Bests,

massoudepsilon November 16, 2011 02:58

hi amir,

Thank you for your respond,

the problem is I do not have the "p" (pointer).

I have to compute gradient of a certain normal tension at the point that particle is. but for doing that I need to calculate this normal tension all over the domain, and this normal tension depends on particle volume fraction in each cell. then I can calculate its gradient.

So, first I have to calculate the normal tension by using the define adjust macro
which does not pass the particle pointers. do you think is there another way to find whether there is any particle in a cell?

Amir November 16, 2011 04:08

Dear Massoud,

This is not good idea to use this procedure; it's better to use a DPM macro in order to convert lagrangian data to eulerian one (something like DEFINE_DPM_SCALAR_UPDATE or ...) for this purpose you can use UDMs as an extra memory to store particle concentration; in next step, use DEFINE_ADJUST macro to evaluate new properties.

Bests,

massoudepsilon November 16, 2011 04:13

Dear amir,

Thank you again,

could you tell me how can I calculate particle concentration in each cell?

if I can do that my problem would be solved.

Cheers

Amir November 16, 2011 04:19

Quote:

Originally Posted by massoudepsilon (Post 332277)
Dear amir,

Thank you again,

could you tell me how can I calculate particle concentration in each cell?

if I can do that my problem would be solved.

Cheers

Here is the numerical procedure:
Experimental measurements and numerical simulations of particle transport and distribution in ventilated rooms; Z. Zhang, Q. Chen; Atmospheric Environment 40 (2006) 3396–3408
Use Eq.7 ....

Bests,

massoudepsilon November 16, 2011 04:21

dear amir,

I really appreciate you taking the time to answer my questions,

CHeers


All times are GMT -4. The time now is 09:48.