CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   OpenFOAM Programming & Development (http://www.cfd-online.com/Forums/openfoam-programming-development/)
-   -   vectorField Uwall(Up.patchInternalField() - Up) (http://www.cfd-online.com/Forums/openfoam-programming-development/112308-vectorfield-uwall-up-patchinternalfield-up.html)

boeleman January 25, 2013 13:23

vectorField Uwall(Up.patchInternalField() - Up)
 
Dear Foamers,

I am trying to understand the calculation of the dynamic contact angle in dynamicAlphaContactAngleFvPatchScalarField.C and I am having trouble to understand the line:

vectorField Uwall(Up.patchInternalField() - Up);

I know Up is U_.boundaryField()[patchi], but why subtract the velocities on patchi from their values next to patchi ("Up.patchInternalField()")?

Thanks,

Arnout

Lieven January 25, 2013 17:48

It seems to me that Uwall is the relative velocity with respect to the wall.
I expect that Up = 0 for fixed walls and nonzero for moving walls.

You can easily verify this by adding
Info << Up << endl;
to the code

Cheers,

L

boeleman January 27, 2013 18:15

I had not thought of the possibility of moving walls. Now it makes sense. Thanks for your reply!

vigneshTG July 10, 2014 08:42

Boeleman !!

I am also trying to understand the dynamic contact angle model implemented in the openfoam. I want to know whether "patch().nf()" refers to face unit normals or something else? Also, whats the difference between nf and nhat ?

Regards
Vignesh

boeleman July 17, 2014 15:36

nf(), does indeed refer to the face unit normal, so Uwall -= (nf & Uwall)*nf;calculates the velocity parallel to the wall, by subtracting the normal component from the complete velocity vector. nhat() is the normal to the interface of the two phases.

Anjishnu Choudhury August 15, 2014 15:11

Hey,
I am really not getting the physical meaning of the term vectorField Uwall(Up.patchInternalField() - Up);

Uwall seems to be of type vectorField, but what does the term in brackets mean ?

Thanks in advance!

vigneshTG August 15, 2014 18:02

Quote:

Originally Posted by Anjishnu Choudhury (Post 506177)
Hey,
I am really not getting the physical meaning of the term vectorField Uwall(Up.patchInternalField() - Up);

Uwall seems to be of type vectorField, but what does the term in brackets mean ?

Thanks in advance!

Up contains the values of U in the boundary and Up.patchInternalField is the values of U in the cells next to the boundary. Their difference gives the relative velocity !!

Hope this helps :D


All times are GMT -4. The time now is 04:24.