CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   FLUENT (https://www.cfd-online.com/Forums/fluent/)
-   -   Odd units on UDS for Isotropic Diffusion (https://www.cfd-online.com/Forums/fluent/83931-odd-units-uds-isotropic-diffusion.html)

bluemonkee January 15, 2011 18:59

Odd units on UDS for Isotropic Diffusion
 
In the ANSYS FLUENT user's guide http://my.fit.edu/itresources/manual...ug/node348.htm , the units for diffusivity are kg/(m*s) as opposed to the conventional units for diffusivity (m^2/s). Can anyone help me to understand this?

Thanks!

KristianEtienne January 17, 2011 05:31

Hi,

The UDS equation is actually solving \rho\varphi, \rho being the fluid density and \varphi being your scalar.

Multiplying your "expected" units for diffusivity with density gives the units shown in the user guide.

Density is included "explicitly" in the transient and convective terms, and all other terms (i.e. diffusion and source terms) must have units kg/(m^3 s).

Cheers!

bluemonkee January 17, 2011 07:35

Thanks!
 
Thanks for your help!

neilduffy1024 January 28, 2011 09:04

Hi,

My question is quite similar. I am solving a number of UDS's, mainly for solid mass and solid temp in a single phase simulation (the multiphase options do not allow me to select the solid in the porous media as the second phase). For the temperature UDS, the diffusivity is the thermal diffusivity and is related to the solid density. My concern is that this is not the case because all UDS diffusivities are hooked into the mixture materials. The manuals are not very clear either. Can anyone shed some light on this?

Thanks,

Neil

MASOUD July 11, 2011 13:11

question about UDS diff
 
Quote:

Originally Posted by KristianEtienne (Post 290713)
Hi,

The UDS equation is actually solving \rho\varphi, \rho being the fluid density and \varphi being your scalar.

Multiplying your "expected" units for diffusivity with density gives the units shown in the user guide.

Density is included "explicitly" in the transient and convective terms, and all other terms (i.e. diffusion and source terms) must have units kg/(m^3 s).

Cheers!

Hi Kristian,

How about if the scalar something other than 'mass fraction'? Precisely, if the scalar is electronic conductivity (1/ohm.meter), should it be multiplied by fluid density?

Thanks

KristianEtienne July 11, 2011 13:37

Hi Masoud,

I assume from your question that you are interested in modelling an electrical potential? The electrical potential is then your "scalar", while the electrical conductivity is the "diffusivity". Anyway, ss long as you solve for UDS without modifying this, it is on the form posted previously, i.e. density weighted.

As long as all your values (i.e. fields, conductivity and source-terms) are consistent, this should be ok. However, for clarity, I would take the time to re-write the UDS equations (thorugh the DEFINE_UDS_UNSTEADY and DEFINE_UDS_FLUX) so that you can specify the electrical conductivity directly. This is especially crucial in a multiphase setting, where your density varies, but not necessarily the conductivity.

Good luck!

-KE

MASOUD July 11, 2011 14:26

2 Attachment(s)
Quote:

Originally Posted by KristianEtienne (Post 315719)
Hi Masoud,

I assume from your question that you are interested in modelling an electrical potential? The electrical potential is then your "scalar", while the electrical conductivity is the "diffusivity". Anyway, ss long as you solve for UDS without modifying this, it is on the form posted previously, i.e. density weighted.

As long as all your values (i.e. fields, conductivity and source-terms) are consistent, this should be ok. However, for clarity, I would take the time to re-write the UDS equations (thorugh the DEFINE_UDS_UNSTEADY and DEFINE_UDS_FLUX) so that you can specify the electrical conductivity directly. This is especially crucial in a multiphase setting, where your density varies, but not necessarily the conductivity.

Good luck!

-KE

Thanks for the prompt reply.

That's right. It's a single phase fuel cell model with two UDSs for the 'electronic potential' and 'ionic potential'. The scalars unit is (Volt) and the diffusivity is (1/(ohm.m)). Also, I am going to model species transport using 5 UDS for the 5 existing species, instead of Fluent species model.

I tried to contact Ansys customer support but didn't get any clear answer for these questions:

1. In the material properties panel, Fluent asks for the diffusivity in terms of (Kg/m.s). Is this applicable to all scalars?

2. If the answer is yes, then have a look at the Eq. 9.1.1 of the user guide please. By ignoring the transient and convective terms (that's the case in my simulation), I'll have just diffusive and source terms. The source term unit is (Amp/m3). To be consistent, diffusivity must be (1/(ohm.m)) which is the realistic unit. Then why should I multiply the UDS diffusivity by the fluid density which makes the equation inconsistent?

3. And for the species transport modeling through UDS, again, should I multiply it by density?

I appreciate your time answering these questions in advance.

Masoud

KristianEtienne July 13, 2011 03:08

Hello again,

Your attached equation (9.1-1) is the generic UDS equation solved by FLUENT, if no modifications are made. Hence, by dimensional analysis, the diffusivity is the mass-diffusivity with dimensions kg/m.s. So, as long as you do not make use of the DEFINE_UDS_UNSTEADY and DEFINE_UDS_FLUX-macros, this will apply to all scalars. This means that you will be solving an equation for \rho \phi, where \phi is the electrical potential.

Consequently, for an unmodified UDS, the source term sould have units kg*(scalar unit)/m3.s.

However, if you disable the unsteady and convection term, you can specify the electrical conductivity directly as the diffusivity (ignore the units given in the materials panel in this case). The source term for electrical potential should then be in its expected units, i.e. Volt/ohm.m3.

To be sure that there isn't any "hidden" weighting within FLUENT, I would recommend that you run two (simple) simulations with different densities, and check that your electrical potential doesn't change.

When modelling species transport with an equation of the form of 7.1-1, assuming that Fick's law is applicable to your system, the diffusive mass flux should be \vec{J_i} = D_i \nabla Y_i, where D_i is the mass-diffusivity, with dimensions kg/m.s.

Good luck!

MASOUD July 14, 2011 00:48

Quote:

Originally Posted by KristianEtienne (Post 315927)
Hello again,

Your attached equation (9.1-1) is the generic UDS equation solved by FLUENT, if no modifications are made. Hence, by dimensional analysis, the diffusivity is the mass-diffusivity with dimensions kg/m.s. So, as long as you do not make use of the DEFINE_UDS_UNSTEADY and DEFINE_UDS_FLUX-macros, this will apply to all scalars. This means that you will be solving an equation for \rho \phi, where \phi is the electrical potential.

Consequently, for an unmodified UDS, the source term sould have units kg*(scalar unit)/m3.s.

However, if you disable the unsteady and convection term, you can specify the electrical conductivity directly as the diffusivity (ignore the units given in the materials panel in this case). The source term for electrical potential should then be in its expected units, i.e. Volt/ohm.m3.

To be sure that there isn't any "hidden" weighting within FLUENT, I would recommend that you run two (simple) simulations with different densities, and check that your electrical potential doesn't change.

When modelling species transport with an equation of the form of 7.1-1, assuming that Fick's law is applicable to your system, the diffusive mass flux should be \vec{J_i} = D_i \nabla Y_i, where D_i is the mass-diffusivity, with dimensions kg/m.s.

Good luck!

Great! I'm now more confident about what I'm doing.

Just a quick question; this is NOT about UDS, it's species model! I need to impose a convective mass transfer B.C. to an external boundary. As you may know, Fluent doesn't allow to specify species mass flux on WALL/MASS FLOW INLET/VELOCITY INLET. We have to either use zero-flux or specified mass fraction for each species, which is not what I need. How would you deal with this? Here is the B.C.:

-D\nablaY=h*(Y0-Y)

I know the other option is to use UDS instead of species model and then specify UDS flux but it's a big headache!

KristianEtienne July 14, 2011 04:44

Glad I could help! :)

Regarding the implementation for a species mass-flux at your boundaries, I believe that this is challenging. Could you maybe use Gauss-theorem to re-write your diffusive flux as a volumetric source/sink term present only in the cells adjacent to the wall in question?

As far as I can see (from dimensional considerations), the source term should then take the form

S_i = h(Y_0-Y_i) \frac{A_{cell}}{V_{cell}}

where A_{cell} is the area of the cell through which the flux occurs. In your UDF for the source you will need to check that your cell is adjacent to the boundary in question and activate the source term only in this region.

Note that this just is an idea, I am not certain that it will work as expected, but it might be worth trying out?

MASOUD July 14, 2011 17:05

Quote:

Originally Posted by KristianEtienne (Post 316079)
Glad I could help! :)

Regarding the implementation for a species mass-flux at your boundaries, I believe that this is challenging. Could you maybe use Gauss-theorem to re-write your diffusive flux as a volumetric source/sink term present only in the cells adjacent to the wall in question?

As far as I can see (from dimensional considerations), the source term should then take the form

S_i = h(Y_0-Y_i) \frac{A_{cell}}{V_{cell}}

where A_{cell} is the area of the cell through which the flux occurs. In your UDF for the source you will need to check that your cell is adjacent to the boundary in question and activate the source term only in this region.

Note that this just is an idea, I am not certain that it will work as expected, but it might be worth trying out?

Yes, you are right and I've been working on this during the past couple weeks. I've used UDMs to mark the cells adjacent to the Wall in a ADJUST macro and then imposed the sink/source terms to these cells through SOURCE macro. As usual, divergence issue exists! I'll update you again as I'm going to make some changes.

Meanwhile, isn't (Cell_Area)/(Cell_Volume)=1 in 2D case?

Also, is there any other setting I should care about or we're all set just with imposing the sink/sources to the adjacent cells? Maybe setting a velocity profile?

Thanks.

rarnaunot March 29, 2017 07:16

Quote:

Originally Posted by KristianEtienne (Post 315927)

(...)

Consequently, for an unmodified UDS, the source term sould have units kg*(scalar unit)/m3.s.
(...)

Hello,

How can I set the units of my UDS??

I need kmol/m3 as UDS units to get a Source term with kmol/m3 s.... Should i express my UDS as kmol/kg (dividing kmol/m3 by the density)??:confused:

Thanks

elnaz. October 8, 2017 04:47

Quote:

Originally Posted by rarnaunot (Post 642847)
Hello,

How can I set the units of my UDS??

I need kmol/m3 as UDS units to get a Source term with kmol/m3 s.... Should i express my UDS as kmol/kg (dividing kmol/m3 by the density)??:confused:

Thanks

hello. I have the same question.
I appreciate your time answering these questions in advance.
thanks.


All times are GMT -4. The time now is 10:16.