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

how to specify wall contact angle for compressibleInterFoam?

Register Blogs Community New Posts Updated Threads Search

Like Tree11Likes
  • 11 Post By phsieh2005

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   October 15, 2010, 17:25
Default how to specify wall contact angle for compressibleInterFoam?
  #1
Senior Member
 
Pei-Ying Hsieh
Join Date: Mar 2009
Posts: 334
Rep Power: 18
phsieh2005 is on a distinguished road
Hi,

I used to specify contact angle the following way:

channel
{
type constantAlphaContactAngle;
theta0 90;
uTheta 0;
thetaA 90;
thetaR 90;
value uniform 0;
}

but now in OpenFOAM-1.7.x, I am getting the following error:

Reading field alpha1



--> FOAM FATAL IO ERROR:
keyword limit is undefined in dictionary "/home/phsieh/OpenFOAM/phsieh-1.7.x/run/transducerInterfaceA/0/alpha1::boundaryField::channel"

file: /home/phsieh/OpenFOAM/phsieh-1.7.x/run/transducerInterfaceA/0/alpha1::boundaryField::channel from line 183257 to line 183259.

From function dictionary::lookupEntry(const word&, bool, bool) const
in file db/dictionary/dictionary.C at line 395.

FOAM exiting
-------------------

what does the limit do? It looks like the limit keyword is looking for :

alpha
zeroGradient
gradient
none

when to choose which one?

Thanks!

Pei
phsieh2005 is offline   Reply With Quote

Old   October 16, 2010, 09:11
Default
  #2
ata
Senior Member
 
ata's Avatar
 
ata kamyabi
Join Date: Aug 2009
Location: Kerman
Posts: 323
Rep Power: 17
ata is on a distinguished road
Hi
It seems you must use dynamicAlphaContactAngle.
Best regards

Ata
ata is offline   Reply With Quote

Old   October 16, 2010, 17:37
Default
  #3
Senior Member
 
Pei-Ying Hsieh
Join Date: Mar 2009
Posts: 334
Rep Power: 18
phsieh2005 is on a distinguished road
Hi, ata,

Thanks for the reply!

I found the answer in alphaContactAngleFvPatchScalarField.H:

Description
Abstract base class for alphaContactAngle boundary conditions.

Derived classes must implement the theta() fuction which returns the
wall contact angle field.

The essential entry "limit" controls the gradient of alpha1 on the wall:

limit none; // Calculate the gradient from the contact-angle without
// limiter

limit gradient; // Limit the wall-gradient such that alpha1 remains
// bounded on the wall

limit alpha; // Bound the calculated alpha1 on the wall

limit zeroGradient; // Set the gradient of alpha1 to 0 on the wall
// i.e. reproduce previous behaviour

Note that if any of the first three options are used the boundary condition
on p_rgh must set to guarantee that the flux is corrected to be zero at the
wall e.g.

walls
{
type fixedFluxPressure;
adjoint no;
}

If "limit zeroGradient;" is used the pressure BCs can be left as before.

SourceFiles
alphaContactAngleFvPatchScalarField.C

----------------------

Still not quite clear when to choose which one, but, for now, I added
limit none;
and still using constantAlphaContactAngle
and the case is running. Will check if the results are reasonable.

Pei
phsieh2005 is offline   Reply With Quote

Old   October 16, 2010, 22:13
Default
  #4
ata
Senior Member
 
ata's Avatar
 
ata kamyabi
Join Date: Aug 2009
Location: Kerman
Posts: 323
Rep Power: 17
ata is on a distinguished road
Hi Pei
Thanks for yur explanation
Good luck
Best regards

Ata
ata is offline   Reply With Quote

Old   December 18, 2012, 15:01
Default
  #5
Member
 
Join Date: May 2012
Posts: 55
Rep Power: 14
styleworker is on a distinguished road
Quote:
Originally Posted by phsieh2005 View Post
Hi, ata,

Thanks for the reply!

I found the answer in alphaContactAngleFvPatchScalarField.H:

Description
Abstract base class for alphaContactAngle boundary conditions.

Derived classes must implement the theta() fuction which returns the
wall contact angle field.

The essential entry "limit" controls the gradient of alpha1 on the wall:

limit none; // Calculate the gradient from the contact-angle without
// limiter

limit gradient; // Limit the wall-gradient such that alpha1 remains
// bounded on the wall

limit alpha; // Bound the calculated alpha1 on the wall

limit zeroGradient; // Set the gradient of alpha1 to 0 on the wall
// i.e. reproduce previous behaviour

Note that if any of the first three options are used the boundary condition
on p_rgh must set to guarantee that the flux is corrected to be zero at the
wall e.g.

walls
{
type fixedFluxPressure;
adjoint no;
}

If "limit zeroGradient;" is used the pressure BCs can be left as before.

SourceFiles
alphaContactAngleFvPatchScalarField.C

----------------------

Still not quite clear when to choose which one, but, for now, I added
limit none;
and still using constantAlphaContactAngle
and the case is running. Will check if the results are reasonable.

Pei

Hello Pei, thank your explanation!

Could you please explain, why the flux has to be zero at walls, if the limiter for alpha1 is non zeroGradient?

I've tested two different pressure bc for walls. The case is the standard capillary rise tutorial. It seems that the free surface is more oscillating with zeroGradient as pressure bc at walls as with fixedFluxPressure.

I've plotted the surface elevation over time:

Pressure BC zeroGradient at walls:
capillaryRise_zero.png

Pressure BC fixedFluxPressure at wall:
capillary_rise.png

EDIT:
I've just read that the pressure gradient is adjusts in a way that the flux on the boundary is that specified by the velocity boundary condition. (https://github.com/OpenFOAM/OpenFOAM...hScalarField.H)
So it does not have to be zero.

Last edited by styleworker; December 19, 2012 at 10:41.
styleworker 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
InterFoam contact angle JoaoMiranda OpenFOAM Running, Solving & CFD 7 October 20, 2016 06:27
solved: contact angle correction in interFoam rcastilla OpenFOAM Bugs 24 March 2, 2016 13:43
[Commercial meshers] tmerge utility creates unwanted interface/walls comes in the final mesh Shoonya OpenFOAM Meshing & Mesh Conversion 11 January 20, 2012 06:23
[Netgen] Import netgen mesh to OpenFOAM hsieh OpenFOAM Meshing & Mesh Conversion 32 September 13, 2011 05:50
Contact angle UDF shephali shrimali FLUENT 0 May 10, 2007 07:52


All times are GMT -4. The time now is 01:43.