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

solved: contact angle correction in interFoam

Register Blogs Community New Posts Updated Threads Search

 
 
LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
Old   June 25, 2010, 04:14
Default solved: contact angle correction in interFoam
  #1
Senior Member
 
Robert Castilla
Join Date: Apr 2009
Location: Spain
Posts: 109
Rep Power: 17
rcastilla is on a distinguished road
I have been working on capillary flows simulation with interFoam. When I make a simple simulation of the flow between two parallel vertical plates (2D), I got very strange results, due to an inadequate calculation of the contact angle correction (see the thread http://www.cfd-online.com/Forums/ope...tml#post264062 )

In the interfaceProperties library the contact angle correction is performed by modifying the direction of the unitary alpha gradient in the patch. It doesn't modify the alpha distribution itself, but only the vector that describes its gradient direction.

Then, in the interFoam solver, in the pEqn.H file, the contribution of the surface tension force is calculated as

fvc::interpolate(interface.sigmaK())*fvc::snGrad(a lpha1)*mesh.magSf()

The value of sigmaK is correct (it has been corrected by the interface object), but it is pointing in the wrong direction in the boundary cells, since it is calculated with fvc:snGrad(alpha1), which has not been corrected. The effect of that is huge when the flow is dominated by wall adhesion.

I suggest the following expression:

fvc::interpolate(interface.sigmaK()*mag(fvc::grad( alpha1)))*interface.nHatf()

It uses the gradient of alpha for the calculation of the force, but the direction is given by the surfaceScalarField nHatf, which has been corrected in the boundaries by the interface object.

I am testing it, and it seems to work. Simulations are very slow...

Perhaps there is a more elegant way of doing that.

Hope it will be useful.

Robert
rcastilla is offline   Reply With Quote

 


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
Dynamic contact angle rmousavibt Fluent UDF and Scheme Programming 12 October 31, 2021 22:38
Slug Flow, interFoam, problems with Contact Angle PrzemekPL OpenFOAM Running, Solving & CFD 13 February 18, 2014 22:10
[Netgen] Import netgen mesh to OpenFOAM hsieh OpenFOAM Meshing & Mesh Conversion 32 September 13, 2011 05:50
Implemening Slip bc and Dynamic contact angle in interFoam asaha OpenFOAM Running, Solving & CFD 2 July 29, 2010 15:49
Theoretical background of formula for dynamic contact angle in interfoam sebastian_vogl OpenFOAM Running, Solving & CFD 3 June 22, 2009 12:25


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