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

snappyHexMesh segmentation fault

Register Blogs Members List Search Today's Posts Mark Forums Read

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   June 23, 2020, 06:03
Default snappyHexMesh segmentation fault
  #1
New Member
 
NewtonianGuy
Join Date: Jun 2020
Posts: 6
Rep Power: 2
NewtonianGuy is on a distinguished road
Hi everyone!

I Am currently trying to model a flow over an airfoil. For that I created a BlockMesh base and i am trying to use snappyhexmesh to enter my geometry in the mesh. Everytime I try to run snappyhexmesh i get a segmentation fault (core dumped). I am new in OpenFoam and i would appreciate any help.

I have attached my snappyHexMeshDict, blockmeshDict and .stl file.

Here is also the error message :

Code:
/*---------------------------------------------------------------------------*\
  =========                 |
  \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox
   \\    /   O peration     | Website:  https://openfoam.org
    \\  /    A nd           | Version:  7
     \\/     M anipulation  |
\*---------------------------------------------------------------------------*/
Build  : 7-3bcbaf946ae9
Exec   : snappyHexMesh
Date   : Jun 23 2020
Time   : 11:16:22
Host   : "cheikhna"
PID    : 13290
I/O    : uncollated
Case   : /home/cheikhna/OpenFOAM/cheikhna-7/run/airFoil2D
nProcs : 1
sigFpe : Enabling floating point exception trapping (FOAM_SIGFPE).
fileModificationChecking : Monitoring run-time modified files using timeStampMaster (fileModificationSkew 10)
allowSystemOperations : Allowing user-supplied system call operations

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

Create mesh for time = 0

Read mesh in = 0.11 s

Overall mesh bounding box  : (0 0 -1) (110 20 1)
Relative tolerance         : 1e-06
Absolute matching distance : 0.000111821

#0  Foam::error::printStack(Foam::Ostream&) at ??:?
#1  Foam::sigSegv::sigHandler(int) at ??:?
#2  ? in "/lib/x86_64-linux-gnu/libc.so.6"
#3  STLLexer::lex() at ??:?
#4  Foam::triSurface::readSTLASCII(Foam::fileName const&) at ??:?
#5  Foam::triSurface::readSTL(Foam::fileName const&) at ??:?
#6  Foam::triSurface::read(Foam::fileName const&, Foam::word const&, bool) at triSurface.C:?
#7  Foam::triSurface::triSurface(Foam::fileName const&) at ??:?
#8  Foam::triSurfaceMesh::triSurfaceMesh(Foam::IOobject const&, Foam::dictionary const&) at ??:?
#9  Foam::searchableSurface::adddictConstructorToTable<Foam::triSurfaceMesh>::New(Foam::IOobject const&, Foam::dictionary const&) at ??:?
#10  Foam::searchableSurface::New(Foam::word const&, Foam::IOobject const&, Foam::dictionary const&) at ??:?
#11  Foam::searchableSurfaces::searchableSurfaces(Foam::IOobject const&, Foam::dictionary const&, bool) at ??:?
#12  ? in "/opt/openfoam7/platforms/linux64GccDPInt32Opt/bin/snappyHexMesh"
#13  __libc_start_main in "/lib/x86_64-linux-gnu/libc.so.6"
#14  ? in "/opt/openfoam7/platforms/linux64GccDPInt32Opt/bin/snappyHexMesh"
Segmentation fault (core dumped)
Also i do not know where I can enter the location of my STL file in the rectangular mesh that I created. For example, I want to place the geometry in the middle not far from the inlet etc... At first, I thought it was locationInMesh but I found that its used to select the region for the meshing.

Tell me if I need to submit any additional files.

Thank you
Attached Images
File Type: png airfoil.PNG (28.5 KB, 3 views)
Attached Files
File Type: txt snappyHexMeshDict.txt (1.8 KB, 2 views)
File Type: txt blockMeshDict.txt (1.5 KB, 1 views)
NewtonianGuy is offline   Reply With Quote

Old   June 23, 2020, 09:41
Default
  #2
Member
 
Join Date: Feb 2016
Posts: 36
Rep Power: 6
LeeRuns is on a distinguished road
I would believe the segmentation fault may be a "red herring" in your debugging process. Let fix the location in mesh part first.

1. Assuming you want to simulate flow external to the geometry. The location in mesh should be a point within the rectangle, but it should NOT be within the airfoil geometry.

2. For shm to know where the airfoil stl is, use the geometry sub dictionary inside of shm. It is in the top of the file.

Also remember that shm only looks For STL files located in the case/constant/triSurface directory.
LeeRuns is offline   Reply With Quote

Old   June 25, 2020, 03:49
Default
  #3
New Member
 
NewtonianGuy
Join Date: Jun 2020
Posts: 6
Rep Power: 2
NewtonianGuy is on a distinguished road
Thank you for your advice! I finally managed to find my problem. I believe it was the STL file taken out from solidworks. It was in binary and not in ASCII, I did the conversion using the surfaceConvert from OpenFoam.

Regarding the location in Mesh, it is simply the coordinates of my blockmesh that I can shift (vertices), or shit my geometry in solidworks with respect to the frame.
NewtonianGuy is offline   Reply With Quote

Old   June 25, 2020, 08:25
Default
  #4
Member
 
Join Date: Feb 2016
Posts: 36
Rep Power: 6
LeeRuns is on a distinguished road
Quote:
Originally Posted by NewtonianGuy View Post
Thank you for your advice! I finally managed to find my problem. I believe it was the STL file taken out from solidworks. It was in binary and not in ASCII, I did the conversion using the surfaceConvert from OpenFoam.

Regarding the location in Mesh, it is simply the coordinates of my blockmesh that I can shift (vertices), or shit my geometry in solidworks with respect to the frame.
Can you re-phrase your last statement? I am having a hard time understanding.
LeeRuns is offline   Reply With Quote

Old   June 25, 2020, 08:41
Default
  #5
New Member
 
NewtonianGuy
Join Date: Jun 2020
Posts: 6
Rep Power: 2
NewtonianGuy is on a distinguished road
Sorry...

I meant that I found a way to place my geometry in my base Mesh (generated through blockMesh). I though first that snappyHexMesh can place my geometry in a disered place but it doesnt (correct me if i am wrong). So basically, I just changed the coordinates of my base mesh to have my airfoil in the center for example.
NewtonianGuy is offline   Reply With Quote

Old   June 25, 2020, 12:36
Default
  #6
Member
 
Join Date: Feb 2016
Posts: 36
Rep Power: 6
LeeRuns is on a distinguished road
Your are correct.
SnappyHexMesh does not move surface file to the background mesh

Open foam does have the "surfaceTransformPoints" function, which can be used to move, scale, and rotate surfaces.

https://www.openfoam.com/documentati...ormPoints.html
LeeRuns is offline   Reply With Quote

Reply

Tags
openfoam, segmentation fault, snappy hex mesh

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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
snappyHexMesh in parallel leads to segmentation fault ChrisHa OpenFOAM Pre-Processing 1 January 14, 2019 10:04
[snappyHexMesh] SnappyHexMesh multioprocessor run causes segmentation fault MarcusNHofer OpenFOAM Meshing & Mesh Conversion 5 June 11, 2015 08:06
[snappyHexMesh] snappyHexMesh Segmentation Fault avd28 OpenFOAM Meshing & Mesh Conversion 11 May 11, 2015 20:32
[snappyHexMesh] SnappyHexMesh segmentation Fault nithishgupta OpenFOAM Meshing & Mesh Conversion 1 December 18, 2014 04:03
segmentation fault when installing OF-2.1.1 on a cluster Rebecca513 OpenFOAM Installation 9 July 31, 2012 15:06


All times are GMT -4. The time now is 05:53.