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

New phaseScalarTransport function object for a single phase in interFoam

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   February 14, 2021, 11:28
Question New phaseScalarTransport function object for a single phase in interFoam
  #1
New Member
 
rasoul
Join Date: Mar 2015
Posts: 24
Rep Power: 11
rasool_soofi is on a distinguished road
Hi everyone!

As you know OpenFOAM announced a new function object for solving scalar transport in only one phase of multi-phase flow solvers especially interFoam. (https://twitter.com/cfddirect/status...167872?lang=en)
I believe here is the best place to discuss about phaseScalarTransport features, advantages and limitations. when OpenFOAM applies this part of code to the algorithm, basically solute (e.g. s.water) diffuses into the second phase but this algorithm will multiply it to the alpha.water (volume fraction in interFoam solver) and then solve the next time step.
Code:
fvScalarMatrix fieldEqn
              (
                  fvm::ddt(alpha, s_)
                + fvm::div(alphaPhi, s_, divScheme)
                - fvm::laplacian
                  (
                      fvc::interpolate(alpha)*fvc::interpolate(D),
                      s_,
                      laplacianScheme
                  )
               ==
                  fvOptions_(alpha, s_)
                - fvm::ddt(residualAlpha_, s_)
                + fvc::ddt(residualAlpha_, s_)
                );
the first question is that how can we explain the physical boundary condition of s.water over the interface? (regrading to the code)

and when I tried a simple test case: (interFoam + phaseTransportFoam)

initial conditions of alpha.water and s.water: (link below)
https://drive.google.com/file/d/1Jth...ew?usp=sharing
indeed when solute spreads to the blue phase it propagates and gives artificial diffusion https://drive.google.com/file/d/1ja9...ew?usp=sharing

so the second question is:
how can we prevent s.water to diffuse to the blue phase causing this artificial diffusion. (maybe related to the first question)

actually with multiplying s.water to alpha it reduces the whole initial amount of solute in the main phase.


any explanation or help would be highly appreciated!
Rasoul
rasool_soofi is offline   Reply With Quote

Old   March 5, 2021, 14:53
Default
  #2
Senior Member
 
Reviewer #2
Join Date: Jul 2015
Location: Knoxville, TN
Posts: 141
Rep Power: 10
randolph is on a distinguished road
Rasoul,

I think I have the answer to your questions in this post.

interFoam with scalar transport in single phase

Thanks,
Rdf
randolph is offline   Reply With Quote

Old   May 26, 2021, 07:31
Post
  #3
New Member
 
Sudarshan
Join Date: Sep 2020
Posts: 3
Rep Power: 5
Sud_fluid is on a distinguished road
Hi,


I'm also trying to simulate a case (similar to sand in water + air) however I do not understand how to implement the phaseTransportFoam (in particular could you please explain what you meant by interfoam + phaseTransportFoam).

I tried to implement this in the dambreak case. In the controlDict, file I included the following lines before the end.

phaseScalarTransport1
{
type phaseScalarTransport;
libs ("libsolverFunctionObjects.so");
field s.water;
p p_rgh;
}

phaseScalarTransport2
{
type phaseScalarTransport;
libs ("libsolverFunctionObjects.so");
field alpha.water * s.water;
p p_rgh;
}
Then I run the command "interfoam" which ends well but when I enter the command "phaseTransportFoam" it is not found. Could you please tell the steps clearly on how to implement phaseTransportFoam.


Thanks.
Sudarshan.



Quote:
Originally Posted by rasool_soofi View Post
Hi everyone!

As you know OpenFOAM announced a new function object for solving scalar transport in only one phase of multi-phase flow solvers especially interFoam. (https://twitter.com/cfddirect/status...167872?lang=en)
I believe here is the best place to discuss about phaseScalarTransport features, advantages and limitations. when OpenFOAM applies this part of code to the algorithm, basically solute (e.g. s.water) diffuses into the second phase but this algorithm will multiply it to the alpha.water (volume fraction in interFoam solver) and then solve the next time step.
Code:
fvScalarMatrix fieldEqn
              (
                  fvm::ddt(alpha, s_)
                + fvm::div(alphaPhi, s_, divScheme)
                - fvm::laplacian
                  (
                      fvc::interpolate(alpha)*fvc::interpolate(D),
                      s_,
                      laplacianScheme
                  )
               ==
                  fvOptions_(alpha, s_)
                - fvm::ddt(residualAlpha_, s_)
                + fvc::ddt(residualAlpha_, s_)
                );
the first question is that how can we explain the physical boundary condition of s.water over the interface? (regrading to the code)

and when I tried a simple test case: (interFoam + phaseTransportFoam)

initial conditions of alpha.water and s.water: (link below)
https://drive.google.com/file/d/1Jth...ew?usp=sharing
indeed when solute spreads to the blue phase it propagates and gives artificial diffusion https://drive.google.com/file/d/1ja9...ew?usp=sharing

so the second question is:
how can we prevent s.water to diffuse to the blue phase causing this artificial diffusion. (maybe related to the first question)

actually with multiplying s.water to alpha it reduces the whole initial amount of solute in the main phase.


any explanation or help would be highly appreciated!
Rasoul
Sud_fluid is offline   Reply With Quote

Reply

Tags
interfoam, only one phase, phasetransportfoam, solute transport


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
Applying strain rate function to fluid phase only pquinn OpenFOAM Post-Processing 0 March 6, 2020 20:03
[snappyHexMesh] Problem with parallel run of snappyHexMesh Lorenzo92 OpenFOAM Meshing & Mesh Conversion 5 April 15, 2016 04:12
[snappyHexMesh] How to define to right point for locationInMesh Mirage12 OpenFOAM Meshing & Mesh Conversion 7 March 13, 2016 14:07
[blockMesh] BlockMeshmergePatchPairs hjasak OpenFOAM Meshing & Mesh Conversion 11 August 15, 2008 07:36
[blockMesh] Axisymmetrical mesh Rasmus Gjesing (Gjesing) OpenFOAM Meshing & Mesh Conversion 10 April 2, 2007 14:00


All times are GMT -4. The time now is 23:47.