CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Meshing & Mesh Conversion (https://www.cfd-online.com/Forums/openfoam-meshing/)
-   -   [Other] Problem with the dictionary file (https://www.cfd-online.com/Forums/openfoam-meshing/111792-problem-dictionary-file.html)

sfigato January 15, 2013 12:04

Problem with the dictionary file
 
Hi Foamers,

I got this error when I run block Mesh;

--> FOAM FATAL ERROR:
face 0 in patch 1 does not have neighbour cell face: 4(5 6 10 11)

My blockMeshDict is:


convertToMeters 0.0001; //coordinates are written in mm

vertices
(
(0 0 0) //point 0
(2.5 0 0) //point 1
(2.5 0.1 0) //point 2
(0 0.1 0) //point 3
(0 0 4) //point 4
(2.5 0 4) //point 5
(2.5 0.1 4) //point 6
(0 0.1 4) //point 7
(0 0 7) //point 8
(0 0.1 7) //point 9
(2.5 0.1 7) //point 10
(2.5 0 7) //point 11
);


blocks
(
hex (0 1 2 3 4 5 6 7 ) (20 20 1) simpleGrading (1 1 1)
hex (4 5 6 7 8 9 10 11 ) (20 20 1) simpleGrading (1 1 1)
);

edges
(
);

boundary
(
iceWall
{
type wall;
faces
(
(1 2 6 5)
);
}

airWall
{
type wall;
faces
(
(5 6 10 11)
(8 11 10 9)
);
}

sym1
{
type symmetryPlane;
faces
(
(4 8 9 7)
(0 4 7 3)
);
}

bottom
{
type wall;
faces
(
(0 3 2 1)
);
}

frontAndBack
{
type empty;
faces
(
(0 1 5 4)
(4 5 11 8)
(3 7 6 5)
(7 9 10 6)
(4 7 6 5)
(4 5 6 7)
);
}
);



Can anyone help me please?

Linse January 16, 2013 04:57

Hi Marco,
1) Please change the title of your thread to something containing "blockMeshDict" instead of only "Dict". There are many different "Dict"-files within OpenFOAM and this way you can make it easier for other users to see what the thread is about without having to open it.
2) The problem is that (5 6 10 11) is not a normal side of your two-block-design but built of corners on completely different sides of the second cube.
I suggest making a small sketch where all the points are in space. Then you will have no problems setting the different faces and patches. It takes two minutes for this case and saves several hours of waiting time (given the time you had to wait for my answer). ;-)

nebrot_w January 16, 2013 05:11

Hi Bernhard,

sorry for the title but I do know how I can change it? Any hints?
Regarding the blockMeshDict! I need to simulate a plate that have two different boundary conditions on one side. That is why I have a face in the middle between top and bottom patches.

The question is can I specify two blocks and merge it or there is some other way?

Linse January 16, 2013 06:32

Having two blocks is completely okay, blockMesh even automagically makes an internal face of the connecting face.
What I meant: If I have read correctly your blockMeshDict, (5 6 10 11) are not within one plane, and I doubt you wanted to use some strangebolic face like that would be the case.
If you make a sketch of the points you defined you should see that points 5, 6, 10 and 11 are not within one plane. One can do that, but that face will be distorted. And of course it will need neighbouring faces.
I can only guess, but did you mean face (7 6 10 11) ?

Changing the title: I am not sure, but it might work via editing the title of your initial post.

sfigato January 16, 2013 11:47

Dear Bernhard,

I solved the problem and I got my mesh..now I would like to run the case with laplacianFoam. After I defined the dictionary T in '0' folder I got this error:

--> FOAM FATAL IO ERROR:
keyword sym is undefined in dictionary "/home/ifas/OpenFOAM/ifas-2.1.1/praktikum/Chpt2/Steelbar/0/T::boundaryField"

file: /home/ifas/OpenFOAM/ifas-2.1.1/praktikum/Chpt2/Steelbar/0/T::boundaryField from line 25 to line 48.

From function dictionary::subDict(const word& keyword) const
in file db/dictionary/dictionary.C at line 461.

FOAM exiting


Here are the boundary and the ' T' files :

/*--------------------------------*- C++ -*----------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: 2.1.1 |
| \\ / A nd | Web: www.OpenFOAM.org |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class polyBoundaryMesh;
location "constant/polyMesh";
object boundary;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

5
(
iceWall
{
type wall;
nFaces 40;
startFace 6280;
}
airWall
{
type wall;
nFaces 80;
startFace 6320;
}
sym
{
type symmetryPlane;
nFaces 80;
startFace 6400;
}
bottom
{
type wall;
nFaces 40;
startFace 6480;
}
frontAndBack
{
type empty;
nFaces 6400;
startFace 6520;
}
)

// ************************************************** *********************** //


/*--------------------------------*- C++ -*----------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: 2.1.1 |
| \\ / A nd | Web: www.OpenFOAM.org |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class volScalarField;
object T;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

dimensions [0 0 0 1 0 0 0];

internalField uniform 1273.15;

boundaryField
{
iceWall
{
type fixedValue;
value uniform 273.15;
}

airWall
{
type fixedValue;
value uniform 293.15
}

sym
{
type symmetryPlane;
}

bottom
{
type fixedGradient;
value uniform -200;
}

frontAndBack
{
type empty;
}
}

// ************************************************** *********************** //



Do you know what could be the problem?

Regards
Marco

Linse January 17, 2013 08:55

Nice to hear it worked!

If you indeed just copied the 0/T in here without altering it, I would suggest to try with ";" after the value for "airWall". ;-)

If it is another problem unfortunately I cannot help, because I do have no experience whatsoever concerning symmetry-BCs.


All times are GMT -4. The time now is 00:40.