|
[Sponsors] |
[swak4Foam] get the value of a field in the neighbour cell of a patch face |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
October 1, 2011, 18:29 |
get the value of a field in the neighbour cell of a patch face
|
#1 |
Member
Miles
Join Date: Sep 2011
Posts: 48
Rep Power: 14 |
Hi,
I am using groovyBC from swak4foam with OF 2.0.1. I am working a lot with TwophaseEulerfoam solver. I want to set a value for a field (Ua Ub and alpha o be more specific) at a patch boundary. To evaluate the expression of my groocyBC, I need for a given face of a patch to use the value caculated in the neighbouring cell. I have seen in the swak4foam wiki page this expression atmosphere { type groovyBC; valueExpression "-(gamma+internalField(gamma))*0.5*normal()"; value uniform (0 0 0); } I am under the impression that "internalField(gamma) " stands for the internal value for the field gamma given at the beginning of the gamma dictionary. Am I right ? If yes does anyone know the expression I can use with groovyBC to have the value of a field in the cell connected to a face patch. Is there a particular syntax for Ua Ub or alpha. Thanks a lot for your help. Regards, Miles |
|
October 3, 2011, 17:26 |
|
#2 | |
Assistant Moderator
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51 |
Quote:
Bernhard |
||
October 3, 2011, 18:45 |
|
#3 | |
Member
Miles
Join Date: Sep 2011
Posts: 48
Rep Power: 14 |
Quote:
Hi, Thanks for your answer. Sorry if my question seems silly but I am new to OF and sometimes I miss correspondence between entities or method. Hence some confusion. It's a lot to learn. If I have well understood, this time, internalfield is the function I was looking for: it does return the value taken in the internaflied next to the patch, hence in the neighboring cell for a given face. When I try to apply this to the following expression, I am missing something: Code:
atmosphere { type groovyBC; valueExpression "-(gamma+internalField(gamma))*0.5*normal()"; value uniform (0 0 0); } - does it mean that the BC here is calculated by combining the actual face value of gamma (“gamma”) and the internalfield value of gamma (“internafield(gamma)”) . - if yes, is it some kind of under-relaxation for the calculation of the boundary? (I use under-relaxation but maybe the world is not appropriate here. Sorry for the shortcut). Thanks again. Have a nice evening, Miles. |
||
October 4, 2011, 07:52 |
|
#4 | |
Assistant Moderator
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51 |
Quote:
|
||
October 4, 2011, 08:27 |
|
#5 |
Member
Miles
Join Date: Sep 2011
Posts: 48
Rep Power: 14 |
Ok
This is clear to me now. Thanks again for your anwsers. Miles P.S.: the "wmake all" command executed to install swake4foam is not listed in the userguide as a common wmake argument (page U-75). I did not get what the "all" stands for exactly? Does this mean all the libs in a given folder? |
|
October 4, 2011, 14:26 |
|
#6 | |
Assistant Moderator
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51 |
Quote:
|
||
October 5, 2011, 11:32 |
|
#7 |
Member
Miles
Join Date: Sep 2011
Posts: 48
Rep Power: 14 |
Thanks for the answer.
BTW I have found the link to the presentation of PyFoam on the swak4foam page. It's realy a pity that it is not highlighted in big! It is very usefull. I was wondering is pyFoam working on OF2.0.1? regards, Miles |
|
October 5, 2011, 11:57 |
|
#8 |
Assistant Moderator
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51 |
pyFoam only controls OpenFOAM from the outside. Thus as long as the fileformats and the outputs of OF do not change radically (and they did not with 2.0) it works with every OF-version known to mankind
|
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
[blockMesh] FATAL ERROR: face 6 in patch 2 does not have neighbour cell face: 4(8 9 21 20) | robingilbert | OpenFOAM Meshing & Mesh Conversion | 28 | November 23, 2023 06:32 |
y+ and u+ values with low-Re RANS turbulence models: utility + testcase | florian_krause | OpenFOAM | 114 | August 23, 2023 05:37 |
snappyhexmesh remove blockmesh geometry | philipp1 | OpenFOAM Running, Solving & CFD | 2 | December 12, 2014 10:58 |
[Gmsh] Import problem | ARC | OpenFOAM Meshing & Mesh Conversion | 0 | February 27, 2010 10:56 |
[Gmsh] Import gmsh msh to Foam | adorean | OpenFOAM Meshing & Mesh Conversion | 24 | April 27, 2005 08:19 |