CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   FLUENT (https://www.cfd-online.com/Forums/fluent/)
-   -   Mass from Mass fraction (https://www.cfd-online.com/Forums/fluent/43683-mass-mass-fraction.html)

PK February 9, 2007 06:50

Mass from Mass fraction
 
Hi ,

How to get the mass of a species from C_YI( , , ) ; let's I have a mixture of 3 species : how to get the mass of a species i in a cell from just C_YI(cell,thread,i) ?

Thanks PK

Dmitriy February 9, 2007 08:10

Re: Mass from Mass fraction
 
Hi PK,

Just multiply C_YI(c,t,i) by mass in the cell, which is (Density in the cell)*(Volume of the cell). You can do it using Custom Field Function and inspect it using Display/Countour. Alternatively, calculate it in UDF and store in a separate memory array (e.g., C_UDMI(c,t,mass_i)), i.e.

C_UDMI(c,t,mass_i)=C_YI(c,t,i)*C_R(c,t)*C_VOLUME(c ,t)

Something like this.

Regards,

Dmitriy

PK February 12, 2007 11:38

Re: Mass from Mass fraction
 
Thanks a lot , It is working .

One more question ; About the value that should be given back by DEFINE_SOURCE in a UDF when removing species.

According to guide , it is value in kg/m3/s ; Does it make sense if with a surface (2D simulation) which is going to remove a quantity of species in M_remove (kg) a DEFINE_SOURCE udf gives back M_remove(kg)/area(of surface in m2) ? ->to have a "density of mass removed" .

Does FLUENT would multiply internally this value by the volume of the cell (C_VOLUME)?

Thanks


All times are GMT -4. The time now is 14:05.