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

Diffusive flux in interMixingFoam

Register Blogs Community New Posts Updated Threads Search

Like Tree7Likes

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   April 6, 2018, 01:54
Default
  #21
Senior Member
 
Elham
Join Date: Oct 2009
Posts: 184
Rep Power: 16
Elham is on a distinguished road
Quote:
Originally Posted by vonboett View Post
one note though: interMixingFoam is either keeping the overall mass right but allows negative concentrations or volumetric concentrations greater than one, or you have the concentrations limited to the physical range but may loose mass...
I tried to optimize this a bit in debrisInterMixing-2.3, you can download the code with the corresponding paper if you want to do the same.
Thanks for the comprehensive reply. I am going to model evaporation of water in air. So I have two phases at first then there will be three and there are mass transfer between two of them. Based on what you described I cannot use interMixingFoam since I need to have three different continuity equations. Please correct me if I am wrong.

Regards,

Elham
Elham is offline   Reply With Quote

Old   April 7, 2018, 11:28
Default
  #22
Senior Member
 
Elham
Join Date: Oct 2009
Posts: 184
Rep Power: 16
Elham is on a distinguished road
Quote:
Originally Posted by Elham View Post
Thanks for the comprehensive reply. I am going to model evaporation of water in air. So I have two phases at first then there will be three and there are mass transfer between two of them. Based on what you described I cannot use interMixingFoam since I need to have three different continuity equations. Please correct me if I am wrong.

Regards,

Elham
Dear Albrecht

I have added source term on MULES of alpha2 and the fvScalarMatrix alpha2Eqn. The solver compiled but it crashed at the time of running.

Code:
#0  Foam::error::printStack(Foam::Ostream&) at ~/OpenFOAM/OpenFOAM-2.3.1/src/OSspecific/POSIX/printStack.C:221
#1  Foam::sigFpe::sigHandler(int) at ~/OpenFOAM/OpenFOAM-2.3.1/src/OSspecific/POSIX/signals/sigFpe.C:108
#2   in "/lib/x86_64-linux-gnu/libc.so.6"
#3  Foam::GAMGSolver::scale(Foam::Field<double>&, Foam::Field<double>&, Foam::lduMatrix const&, Foam::FieldField<Foam::Field, double> const&, Foam::UPtrList<Foam::lduInterfaceField const> const&, Foam::Field<double> const&, unsigned char) const at ~/OpenFOAM/OpenFOAM-2.3.1/src/OpenFOAM/matrices/lduMatrix/solvers/GAMG/GAMGSolverScale.C:57
#4  Foam::GAMGSolver::Vcycle(Foam::PtrList<Foam::lduMatrix::smoother> const&, Foam::Field<double>&, Foam::Field<double> const&, Foam::Field<double>&, Foam::Field<double>&, Foam::Field<double>&, Foam::Field<double>&, Foam::Field<double>&, Foam::PtrList<Foam::Field<double> >&, Foam::PtrList<Foam::Field<double> >&, unsigned char) const at ~/OpenFOAM/OpenFOAM-2.3.1/src/OpenFOAM/matrices/lduMatrix/solvers/GAMG/GAMGSolverSolve.C:370 (discriminator 1)
#5  Foam::GAMGSolver::solve(Foam::Field<double>&, Foam::Field<double> const&, unsigned char) const at ~/OpenFOAM/OpenFOAM-2.3.1/src/OpenFOAM/matrices/lduMatrix/solvers/GAMG/GAMGSolverSolve.C:119
#6  Foam::fvMatrix<double>::solveSegregated(Foam::dictionary const&) at ~/OpenFOAM/OpenFOAM-2.3.1/src/finiteVolume/fvMatrices/fvScalarMatrix/fvScalarMatrix.C:169 (discriminator 1)
#7  Foam::fvMatrix<double>::solve(Foam::dictionary const&) at ~/OpenFOAM/OpenFOAM-2.3.1/src/finiteVolume/lnInclude/fvMatrixSolve.C:82
#8  
 at ~/OpenFOAM/elham-2.3.1/applications/solvers/multiphase/interFoam/interMixingHeatFoam/pEqn.H:58 (discriminator 5)
#9  __libc_start_main in "/lib/x86_64-linux-gnu/libc.so.6"
#10  
 at ??:?
Floating point exception (core dumped)
elham@elham-Precision-T7610:~/OpenFOAM/elham-2.3.1/tutorials/multiphase/interMixingHeatFoam/droplet$
Do you think the problem is in the code? Should I change the fluxes as well?

Regards,

Elham
Elham is offline   Reply With Quote

Old   April 11, 2018, 04:55
Default
  #23
Senior Member
 
Albrecht vBoetticher
Join Date: Aug 2010
Location: Zürich, Swizerland
Posts: 237
Rep Power: 16
vonboett is on a distinguished road
have you tried interPhaseChangeFoam?
vonboett is offline   Reply With Quote

Old   April 11, 2018, 09:40
Default
  #24
Senior Member
 
Elham
Join Date: Oct 2009
Posts: 184
Rep Power: 16
Elham is on a distinguished road
Quote:
Originally Posted by vonboett View Post
have you tried interPhaseChangeFoam?
I could fix it. Since I have three phases I cannot use interPhaseChangeFoam. Now I am running three phases with source term. Thanks for the alphaEqns.H file that you provided.

Regards,

Elham
Elham is offline   Reply With Quote

Old   April 27, 2018, 04:01
Default
  #25
Senior Member
 
Elham
Join Date: Oct 2009
Posts: 184
Rep Power: 16
Elham is on a distinguished road
Quote:
Originally Posted by vonboett View Post
one note though: interMixingFoam is either keeping the overall mass right but allows negative concentrations or volumetric concentrations greater than one, or you have the concentrations limited to the physical range but may loose mass...
I tried to optimize this a bit in debrisInterMixing-2.3, you can download the code with the corresponding paper if you want to do the same.
Dear Albrecht,

In interMixingFoam there are diffusion terms in alpha equations,eg,
Code:
- fvm::laplacian(Dc23 + Dc32 + alphatab*turbulence->nut() , alpha3)
for alpha3, but they do not exist in the MULES equations. Would you please explain the reason? I tried to add diffusion term in the MULES but I got the error that there is not any off-diagonal term in the matrix.

Regards,

Elham
Elham is offline   Reply With Quote

Old   April 29, 2018, 05:31
Default
  #26
Senior Member
 
Albrecht vBoetticher
Join Date: Aug 2010
Location: Zürich, Swizerland
Posts: 237
Rep Power: 16
vonboett is on a distinguished road
Hi,

Interesting version you found there, where I experimented with eddy diffusivity... However, the code I ment is in the supplement of
https://www.geosci-model-dev.net/10/3963/2017/
and it is ment as "inspiration" and can't be taken as 1:1 copy to interMixingFoam because it has implemented other stuff to deal with debris flows. Phase1 stays separate, phase 2 and 3 can mix, but do not have momentum transfer.
A H Gazi likes this.
vonboett is offline   Reply With Quote

Old   May 21, 2018, 02:03
Default
  #27
Senior Member
 
Elham
Join Date: Oct 2009
Posts: 184
Rep Power: 16
Elham is on a distinguished road
Quote:
Originally Posted by vonboett View Post
Hi,

Interesting version you found there, where I experimented with eddy diffusivity... However, the code I ment is in the supplement of
https://www.geosci-model-dev.net/10/3963/2017/
and it is ment as "inspiration" and can't be taken as 1:1 copy to interMixingFoam because it has implemented other stuff to deal with debris flows. Phase1 stays separate, phase 2 and 3 can mix, but do not have momentum transfer.

Dear Albrecht,

I have checked your code. In the debrisInterMixingFoam.C you have added a resetting velocity and pressure feature in the PISO loop after outerCorrection loop to prevent melting or freezing of the material. It was a problem that I encountered and is really helpful. But I am after the origin of the error and is there any resource to give more insight?

Cheers,

Elham
Elham is offline   Reply With Quote

Old   August 14, 2018, 17:46
Default
  #28
New Member
 
Aaron
Join Date: Aug 2018
Location: BC Canada
Posts: 1
Rep Power: 0
astroda is on a distinguished road
Quote:
Originally Posted by Elham View Post
Thanks for the comprehensive reply. I am going to model evaporation of water in air. So I have two phases at first then there will be three and there are mass transfer between two of them. Based on what you described I cannot use interMixingFoam since I need to have three different continuity equations. Please correct me if I am wrong.

Regards,

Elham
Hi Elham,

How is this going, I am interested in what became of it! I am looking to model the distillation process, so from a miscible mixture to a pure vapour phase change.

Is there a working (or non working) version of your solver?

Kindly,
astroda is offline   Reply With Quote

Old   August 14, 2018, 23:05
Default
  #29
Senior Member
 
Elham
Join Date: Oct 2009
Posts: 184
Rep Power: 16
Elham is on a distinguished road
Quote:
Originally Posted by astroda View Post
Hi Elham,

How is this going, I am interested in what became of it! I am looking to model the distillation process, so from a miscible mixture to a pure vapour phase change.

Is there a working (or non working) version of your solver?

Kindly,
Dear Aaron,

My model based on interMixingFoam is working now, although not published yet. What else do you need to know now?
A H Gazi likes this.
Elham 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
Problem setting with chtmultiregionFoam Antonin OpenFOAM 10 April 24, 2012 09:50
Zero Diffusive flux Subramani Sockalingam FLUENT 1 May 27, 2009 10:36
Zero Diffusive flux Subramani Sockalingam Main CFD Forum 0 January 19, 2008 13:02
Help: diffusive flux BC at wall Quarkz Main CFD Forum 7 July 17, 2005 11:24
Replace periodic by inlet-outlet pair lego CFX 3 November 5, 2002 20:09


All times are GMT -4. The time now is 02:50.