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

how to calculate the interface normal between mulitphase

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   October 20, 2018, 00:31
Question how to calculate the interface normal between mulitphase
  #1
New Member
 
Lei Zhou
Join Date: Sep 2018
Posts: 2
Rep Power: 0
joe1949 is on a distinguished road
Hello everyone:
I feel confused about the calculation of interface normal between mulitphase.
It's the source code in line 1150-1171 at https://www.openfoam.com/documentati...8C_source.html
/************************************************** *******************/
Foam::tmp<Foam::surfaceVectorField> Foam:haseSystem::nHatfv
(
const volScalarField& alpha1,
const volScalarField& alpha2
) const
{

surfaceVectorField gradAlphaf
(
fvc::interpolate(alpha2)*fvc::interpolate(fvc::gra d(alpha1))
- fvc::interpolate(alpha1)*fvc::interpolate(fvc::gra d(alpha2))
);

const dimensionedScalar deltaN
(
"deltaN",
1e-8/pow(average(mesh_.V()), 1.0/3.0)
);

// Face unit interface normal
return gradAlphaf/(mag(gradAlphaf) + deltaN);
}
/************************************************** **/
What's the meaning behind the code?
My understanding is that the grad(alpha1) and -grad(alpha2) both are approximation of interface normal from phase1 to phase2. Then, the linear combination of grad(alpha1) and -grad(alpha2) is still a approximation of interface normal from phase1 to phase2. So the premultiply factors( alpha2, alpha1) are weighted factor.
Is my understanding right?
Is there any other explanation?

Last edited by joe1949; October 20, 2018 at 11:21.
joe1949 is offline   Reply With Quote

Old   December 9, 2018, 09:13
Red face
  #2
New Member
 
Lei Zhou
Join Date: Sep 2018
Posts: 2
Rep Power: 0
joe1949 is on a distinguished road
Self answering :

Both grad(alpha1)/alpha1 and -grad(alpha2)/alpha2 are the normal from alpha1 to alpha2. Then their sum grad(alpha1)/alpha1 + ( -grad(alpha2)/alpha2 ) are the interface normal.
considering that the division operation is time-comsuming. So we can use alpha1*alpha2 to times ( grad(alpha1)/alpha1 + ( -grad(alpha2)/alpha2 ) ) to eliminate the denominator, because the magnitude of the normal can be uniformization. The result is alpha2*fvc::grad(alpha1) - alpha1*fvc::grad(alpha2)
joe1949 is offline   Reply With Quote

Old   October 29, 2021, 06:09
Default
  #3
New Member
 
JungHoon Lee
Join Date: Apr 2019
Posts: 8
Rep Power: 7
ssitank is on a distinguished road
Quote:
Originally Posted by joe1949 View Post
Self answering :

Both grad(alpha1)/alpha1 and -grad(alpha2)/alpha2 are the normal from alpha1 to alpha2. Then their sum grad(alpha1)/alpha1 + ( -grad(alpha2)/alpha2 ) are the interface normal.
considering that the division operation is time-comsuming. So we can use alpha1*alpha2 to times ( grad(alpha1)/alpha1 + ( -grad(alpha2)/alpha2 ) ) to eliminate the denominator, because the magnitude of the normal can be uniformization. The result is alpha2*fvc::grad(alpha1) - alpha1*fvc::grad(alpha2)



Dear Lei Zhou,


thank you so much for great information. I know this post seem quite old but I would like to ask you wehre did you get this equation? Could you please refer a literature for this?


Thanks so much in advance!
JungHoon
ssitank is offline   Reply With Quote

Reply

Tags
openfoam 1806, program development


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
My radial inflow turbine Abo Anas CFX 27 May 11, 2018 02:44
Access the area and normal of the interface in VOF dongshancfd Fluent Multiphase 0 March 6, 2018 04:56
How do we calculate the normal Reynolds stresses? (Linear eddy viscosity models) userid42 Main CFD Forum 8 August 28, 2017 14:11
Calculate a custom flux through the interface of a two phase flow arsalan.dryi OpenFOAM Post-Processing 5 October 24, 2016 15:31
Error - Solar absorber - Solar Thermal Radiation MichaelK CFX 12 September 1, 2016 06:15


All times are GMT -4. The time now is 18:52.