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/)
-   -   [blockMesh] FOAM Fatal Error when I want to make a patch in a semicircle (https://www.cfd-online.com/Forums/openfoam-meshing/210636-foam-fatal-error-when-i-want-make-patch-semicircle.html)

alexbadescu24 October 31, 2018 11:26

FOAM Fatal Error when I want to make a patch in a semicircle
 
Hy guys,
I am new to OpenFoam and C++,

I have to make an inlet patch for a semicircle section of an inside pipe. The semicircle pipe is comprised out of 4 blocks and it can be seen in the picture below https://ibb.co/cPZQv0 with the chosen numbers. The problem is when I try to write them I do not know why is giving me the error that it can find neighbor cell faces.https://ibb.co/egRzNf

Here is the code. Can you help me out please?

/*--------------------------------*- C++ -*----------------------------------*\
========= | foam-extend-4.0: Open Source CFD
\\ / F ield | URL: http://www.foam-extend.org
\\ / O peration |
\\ / A nd | OpenFOAM-6: The Open Source CFD Toolbox
\\/ M anipulation | URL: https://openfoam.org
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class dictionary;
location "constant/polyMesh";
object blockMeshDict;
}

convertToMeters 0.001;

vertices
(
(0 0 -7.5) // point 0 as 4'''
(750 0 -7.5) // point 1 as 5'''
(750 7.5 -7.5) // point 2 & 1" & 6'''
(0 7.5 -7.5) // point 3 & 0" & 7'''
(0 0 7.5) // point 4 as 0'
(750 0 7.5) // point 5 as 1'
(750 7.5 7.5) // point 6 as 2'
(0 7.5 7.5) // point 7 as 3'
(0 0 22.5) // point 8 as 4'
(750 0 22.5) // point 9 as 5'
(750 15.9 15.9) // point 10 as 6'
(0 15.9 15.9) // point 11 as 7'
(750 15.9 -15.9) // point 12 as 2" & 2'''
(0 15.9 -15.9) // point 13 as 3" & 3'''
(0 0 -22.5) // point 14 as 0'''
(750 0 -22.5) // point 15 as 1'''
);

blocks
(
// Order of points defines local coordinate system!
hex (0 1 2 3 4 5 6 7) (10 10 10) simpleGrading (1 1 1)
hex (4 5 6 7 8 9 10 11) (10 10 10) simpleGrading (1 1 1)
hex (3 2 12 13 7 6 10 11) (10 10 10) simpleGrading (1 1 1)
hex (14 15 12 13 0 1 2 3) (10 10 10) simpleGrading (1 1 1)

);

edges
(

// We can bend existing block edges only!
arc 8 11 (0 8.61 20.78)
arc 9 10 (750 8.61 20.78)
arc 11 13 (0 22.5 0)
arc 10 12 (750 22.5 0)
arc 13 14 (0 8.61 -20.78)
arc 12 15 (750 8.61 -20.78)

);

boundary
(

// Boundaries are named geometrical boundaries for the boundary conditions.

wall // boundary name
{
type wall; // 'wall' is a boundary where no flow can go through.
faces
(
(8 9 10 11)
(11 10 12 13)
(13 12 15 14)
);
}
cut // boundary name
{
type patch; // 'patch' is a general boundary where flow can go through.
faces
(
(9 8 4 5)
(5 4 0 1)
(1 0 14 15)
);
}
patch2 // boundary name
{
type patch; // 'patch' is a general boundary where flow can go through.
faces
(
(8 11 5 4)
(4 5 3 0)
(0 3 13 14)
(13 3 5 11)
);
}

// Other boundary types are, for example, symmetry, cyclic etc.

);

mergePatchPairs
(
);

yambanshee November 1, 2018 02:42

Please attach an image of the blocks you are trying to build, as well as the error that is outputted

alexbadescu24 November 3, 2018 07:50

I managed to solve the error. It was a typo in my code. Please close this thread.


All times are GMT -4. The time now is 06:02.