CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   OpenFOAM Bugs (http://www.cfd-online.com/Forums/openfoam-bugs/)
-   -   SnappyHexMesh and planar STL surfaces (http://www.cfd-online.com/Forums/openfoam-bugs/62450-snappyhexmesh-planar-stl-surfaces.html)

hannes August 1, 2008 08:23

Description: When planar STL
 
Description:
When planar STL surfaces which are aligned with coordinate planes are supplied to snappyHexMesh, an error message like to following occurs:

==============================================
Edge intersection testing:
Number of edges : 74800
Number of edges to retest : 74800


Badly formed bounding boxhttp://www.cfd-online.com/OpenFOAM_D...lipart/sad.gif-0.0720968 0.027 -0.0410269) (0.080055 0.027
0.0410628)#0 Foam::error::printStack(Foam:http://www.cfd-online.com/OpenFOAM_D...part/proud.gifstream&) in
"/home/cluster/josef/OpenFOAM/OpenFOAM-1.5/lib/linux64GccDPOpt/libOpenFOAM.so"
#1 Foam::error::abort() in
"/home/cluster/josef/OpenFOAM/OpenFOAM-1.5/lib/linux64GccDPOpt/libOpenFOAM.so"
#2
Foam::indexedOctree<foam::treedatatrisurface>::div ide(Foam::treeBoundBox
const&, Foam::DynamicList<foam::list<int>, 0u, 2u, 1u>&, int) const in
"/home/cluster/josef/OpenFOAM/OpenFOAM-1.5/lib/linux64GccDPOpt/libmeshTools.so"
#3
Foam::indexedOctree<foam::treedatatrisurface>::ind exedOctree(Foam::treeDataTriSu rface const&, Foam::treeBoundBox const&, int, double, double) in "/home/cluster/josef/OpenFOAM/OpenFOAM-1.5/lib/linux64GccDPOpt/libmeshTools.so"
#4 Foam::triSurfaceMesh::tree() const in
"/home/cluster/josef/OpenFOAM/OpenFOAM-1.5/lib/linux64GccDPOpt/libmeshTools.so"
#5 Foam::triSurfaceMesh::findLineAny(Foam::Field<foam ::vector<double> >
const&, Foam::Field<foam::vector<double> > const&,
Foam::List<foam::pointindexhit<foam::vector<double > > >&) const in
"/home/cluster/josef/OpenFOAM/OpenFOAM-1.5/lib/linux64GccDPOpt/libmeshTools.so"
#6
Foam::refinementSurfaces::findHigherIntersection(F oam::Field<foam::vector<double > > const&, Foam::Field<foam::vector<double> > const&, Foam::List<int> const&, Foam::List<int>&, Foam::List<int>&) const in "/home/cluster/josef/OpenFOAM/OpenFOAM-1.5/lib/linux64GccDPOpt/libautoMesh.so"
#7 Foam::meshRefinement::updateIntersections(Foam::Li st<int> const&) in
"/home/cluster/josef/OpenFOAM/OpenFOAM-1.5/lib/linux64GccDPOpt/libautoMesh.so"
#8 Foam::meshRefinement::meshRefinement(Foam::fvMesh& , double,
Foam::refinementSurfaces const&, Foam::shellSurfaces const&) in
"/home/cluster/josef/OpenFOAM/OpenFOAM-1.5/lib/linux64GccDPOpt/libautoMesh.so"
#9 main in
"/home/cluster/josef/OpenFOAM/OpenFOAM-1.5/applications/bin/linux64GccDPOpt/snap pyHexMesh"
#10 __libc_start_main in "/lib64/libc.so.6"
#11 Foam::regIOobject::writeObject(Foam::IOstream::str eamFormat,
Foam::IOstream::versionNumber, Foam::IOstream::compressionType) const in
"/home/cluster/josef/OpenFOAM/OpenFOAM-1.5/applications/bin/linux64GccDPOpt/snap pyHexMesh"


From function indexedOctree<type>::divide
in file lnInclude/indexedOctree.C at line 213.

FOAM aborting

==============================================

The statement after line 205 in $FOAM_SRC/meshTools/lnInclude/indexedOctree.C causes the error:

if
(
bb.min()[0] >= bb.max()[0]
|| bb.min()[1] >= bb.max()[1]
|| bb.min()[2] >= bb.max()[2]
)
{
FatalErrorIn("indexedOctree<type>::divide")
<< "Badly formed bounding box:" << bb
<< abort(FatalError);
}

If this check is removed and libmeshTools recompiled, the code runs fine without errors.


Solver/Application:
snappyHexMesh

Source file:
$FOAM_SRC/meshTools/lnInclude/indexedOctree.C

Platform:
Linux x86_64, Fedora 9

Version:
1.5

mattijs August 1, 2008 08:47

Thanks for report. The indexed
 
Thanks for report. The indexedOctree is for 3D geometry - am surprised it actually produces something useful for 2D geometry. You might get problems with truncation error. Is it possible to get the surface, blockMeshDict and snappyHexMeshDict? (m dot janssens)


All times are GMT -4. The time now is 13:50.