CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Meshing & Mesh Conversion

[snappyHexMesh] stl file problem

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   October 13, 2013, 13:11
Question stl file problem
  #1
New Member
 
Gabriel Boucher
Join Date: Jul 2013
Posts: 23
Rep Power: 12
Alfalfa is on a distinguished road
Hello, I'm new to snappy and want to give it a try. I ran the motorbike tutorial and everything went well. I then wanted to try with another geometry (a sphere) and compare it with my results from Star-CCM+. Here come the problems... I built a sphere in Salome and saved it in *.stl then I modified the surfaceFeatureExtractDict to extract the features (I changed the name of the file for sphere.stl). but when I run it, I get this error:

Code:
/*---------------------------------------------------------------------------*\
| =========                 |                                                 |
| \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox           |
|  \\    /   O peration     | Version:  2.2.0                                 |
|   \\  /    A nd           | Web:      www.OpenFOAM.org                      |
|    \\/     M anipulation  |                                                 |
\*---------------------------------------------------------------------------*/
Build  : 2.2.0
Exec   : surfaceFeatureExtract
Date   : Oct 13 2013
Time   : 12:58:35
Host   : "gabriel-All-Series"
PID    : 8342
Case   : /home/gabriel/OpenFOAM/OpenFOAM-2.2.0/gabriel-2.2.0/run/airFoil2D
nProcs : 1
sigFpe : Enabling floating point exception trapping (FOAM_SIGFPE).
fileModificationChecking : Monitoring run-time modified files using timeStampMaster
allowSystemOperations : Disallowing user-supplied system call operations

// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
Create time

Reading surfaceFeatureExtractDict

Surface            : "sphere.stl"


Feature line extraction is only valid on closed manifold surfaces.
Statistics:
Triangles    : 1200
Vertices     : 609
Bounding Box : (-0.997147 -0.997146 -1) (0.997146 0.997146 1)


Constructing feature set from included angle 150

Initial feature set:
    feature points : 1
    feature edges  : 49
    of which
        region edges   : 49
        external edges : 0
        internal edges : 0

#0  Foam::error::printStack(Foam::Ostream&) at ??:?
#1  Foam::sigFpe::sigHandler(int) at ??:?
#2   in "/lib/x86_64-linux-gnu/libc.so.6"
#3  Foam::tmp<Foam::Field<Foam::Vector<double> > > Foam::operator/<Foam::Vector<double> >(Foam::UList<Foam::Vector<double> > const&, Foam::tmp<Foam::Field<double> > const&) at ??:?
#4  void Foam::extendedFeatureEdgeMesh::sortPointsAndEdges<Foam::triSurface>(Foam::triSurface const&, Foam::List<int> const&, Foam::List<int> const&, Foam::List<int> const&) at ??:?
#5  Foam::extendedFeatureEdgeMesh::extendedFeatureEdgeMesh(Foam::surfaceFeatures const&, Foam::objectRegistry const&, Foam::fileName const&) at ??:?
#6  
 at ??:?
#7  __libc_start_main in "/lib/x86_64-linux-gnu/libc.so.6"
#8  
 at ??:?
Floating point exception (core dumped)
I tried to use another program (blender) to generate the stl file but I still get the same error. I tried with a cone instead of a sphere, still nothing and now I don't know what to do. I also tried binary and ascii for the stl but it doesn't change anythig.

Here's my surfaceFeatureExtractDict:

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

sphere.stl
{
    // How to obtain raw features (extractFromFile || extractFromSurface)
    extractionMethod    extractFromSurface;

    extractFromSurfaceCoeffs
    {
        // Mark edges whose adjacent surface normals are at an angle less
        // than includedAngle as features
        // - 0  : selects no edges
        // - 180: selects all edges
        includedAngle   150;
    }

    // Write options

        // Write features to obj format for postprocessing
        writeObj                yes;
}


// ************************************************************************* //
Any help would be appreciated

Gabriel
Alfalfa is offline   Reply With Quote

Old   October 13, 2013, 16:30
Default
  #2
New Member
 
Gabriel Boucher
Join Date: Jul 2013
Posts: 23
Rep Power: 12
Alfalfa is on a distinguished road
Ok, I found a way to make it work... but I'm not sure why it doesn't work the intended way. What i did is I used blender to create a ''mesh'' sphere instead of a surface one and saved it in *.obj. After that, it worked. I still have a question though. When I run snappy, I get a warning saying:

Number of cells in mesh:10240 does not equal size of cellLevel:455769

I can get rid of this by deleting cellLevel and pointLevel files from the polymesh directory but it's a weird error and I don't get it.

Does anyone knows what could be the problem here?
Alfalfa is offline   Reply With Quote

Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Custom Thermophysical Properties wsmith02 OpenFOAM 4 June 1, 2023 14:30
[swak4Foam] swak4foam for OpenFOAM 4.0 mnikku OpenFOAM Community Contributions 80 May 17, 2022 08:06
[swak4Foam] funkyDoCalc with OF2.3 massflow NiFl OpenFOAM Community Contributions 14 November 25, 2020 03:30
DxFoam reader update hjasak OpenFOAM Post-Processing 69 April 24, 2008 01:24
DecomposePar links against liblamso0 with OpenMPI jens_klostermann OpenFOAM Bugs 11 June 28, 2007 17:51


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