CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Running, Solving & CFD

reactingTwoPhaseEulerFoam mass transfer

Register Blogs Community New Posts Updated Threads Search

Like Tree2Likes
  • 1 Post By S.Colucci
  • 1 Post By S.Colucci

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   May 30, 2016, 12:57
Default reactingTwoPhaseEulerFoam mass transfer
  #1
New Member
 
Simone Colucci
Join Date: Mar 2016
Location: Pisa (Italy)
Posts: 23
Rep Power: 10
S.Colucci is on a distinguished road
Hi all,
I'm looking into the last release of the solver reactingEulerFoam 3.0.x. Mass transfer term (dmdt) associataed with a change of phase is implemented in function massTransfer() in InterfaceCompositionPhaseChangePhaseSystem.C:
Code:
dmdtExplicit += dmdtSign*phase.rho()*KD*Yf;
dmdt -= dmdtSign*phase.rho()*KD*eqns[name]->psi();
where dmdt is initialized with dmdtExplicit, thus

dmdt = dmdtSign*rho*KD*( Yf - Yi ),

where Yf is the equilibrium concentration of component i in the phase (given, for example by the Henry's law) and Yi the effective transported concentration of component i in the phase. dmdtSign is "+" for phase 1 and "-" for phase 2, thus for phase 1

dmdt = dmdtSign*rho*KD*( Yf - Yi ),

and for phase 2

dmdt = dmdtSign*rho*KD*( Yi - Yf ).

It means that for phase 1, as well as for phase 2, a mass transfer from 2 to 1 is positive and a mass transfer from 1 to 2 is negative.

In reactingTwoPhaseEulerFoam/pUf/UEqns.H
Code:
    const volScalarField dmdt12(posPart(fluid.dmdt()));
    const volScalarField dmdt21(negPart(fluid.dmdt()));
and in U1Eqn
Code:
+ fvm::Sp(dmdt12, U1) + dmdt21*U2,
while in U2Eqn
Code:
- fvm::Sp(dmdt21, U2) - dmdt12*U1.
I think it should be the opposite:
Code:
    const volScalarField dmdt12(negPart(fluid.dmdt()));
    const volScalarField dmdt21(posPart(fluid.dmdt()));
because the velocity associated to a mass transfer from phase 1 to phase 2 is U1 and viceversa.

Looking into HeatAndMassTransferPhaseSystem.C, where the momentum transfer term is added to the UEqns for the case when faceMomentum is off, these terms seem to be implemented in the right way. Finally, to verify this, I run a simulation where liquid water is oversaturated in dissolved air in a closed column and I printed on the screen at runtime the value of dmdt. As you can see in the figure, the dissolved air start to exsolve and I it moves from the liquid (phase2 in this case) to the gas phase. I checked that the dmdt, printed on the screen, and associated to a mass transfer from 2 to 1 is positive (it goes in dmdt12, according to the actual implementation).

Should I report this as a bug in the OpenFOAM bug Reporting?

Simone
Attached Images
File Type: png column_oversaturated.png (31.4 KB, 78 views)
rarnaunot likes this.
S.Colucci is offline   Reply With Quote

Old   May 31, 2016, 10:41
Default
  #2
New Member
 
Simone Colucci
Join Date: Mar 2016
Location: Pisa (Italy)
Posts: 23
Rep Power: 10
S.Colucci is on a distinguished road
Sorry, there was a mistake in the correction that I was proposing , the right is
Code:
    const volScalarField dmdt12(-negPart(fluid.dmdt()));
    const volScalarField dmdt21(-posPart(fluid.dmdt()));
in this way the sign of the mass transfer term in the UEqn is right.
S.Colucci is offline   Reply With Quote

Old   July 6, 2016, 09:44
Default
  #3
New Member
 
Simone Colucci
Join Date: Mar 2016
Location: Pisa (Italy)
Posts: 23
Rep Power: 10
S.Colucci is on a distinguished road
Recently, a new version of OpenFOAM has been released (OpenFOAMv1606+). In this new version the mass transfer terms in pUf/UEqns.H have been modified. Now it reads:

Quote:
const volScalarField dmdt12(posPart(fluid.dmdt()));
const volScalarField dmdt21(negPart(fluid.dmdt()));

{
U1Eqn =
(
fvm::div(alphaRhoPhi1, U1) - fvm::Sp(fvc::div(alphaRhoPhi1), U1)
+ fvm::Sp(dmdt12, U1) - dmdt12*U2
+ MRF.DDt(alpha1*rho1, U1)
+ phase1.turbulence().divDevRhoReff(U1)
+ Vm*(UgradU1 - (UgradU2 & U2))
);
U1Eqn.relax();
fvOptions.constrain(U1Eqn);
U1.correctBoundaryConditions();
fvOptions.correct(U1);
}
The momentum transfer term, dmdt, now is in agreement with the implementation for the case when faceMomentum is off (see HeatAndMassTransferPhaseSystem.C).
But there is still something that I do not understand:

1) in pUf/UEqns.H I read
Quote:
+ fvm::Sp(dmdt12, U1) - dmdt12*U2
but I expected
Quote:
- fvm::Sp(dmdt21, U1) - dmdt12*U2
is there some other dmdt added somewhere in the code? Where is it?

2) in the U1Eqn above, as well as in U2Eqn, where are temporal derivatives, other momentum transfer terms and continuity errors?

Any idea?


Simone
rarnaunot likes this.
S.Colucci is offline   Reply With Quote

Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
mass transfer coefficient ArturTU FLUENT 1 October 27, 2015 10:04
Question about heat transfer coefficient setting for CFX Anna Tian CFX 1 June 16, 2013 06:28
About phase change heat and mass transfer Michael FLUENT 2 February 13, 2011 01:49
How to calculate Volumetric Mass transfer coefficient using CFX? tuks_123 CFX 2 July 22, 2010 01:15
Vof, udf and mass transfer panel Jay FLUENT 1 March 15, 2005 00:29


All times are GMT -4. The time now is 08:33.