|
[Sponsors] |
[snappyHexMesh] snappyHexMesh is not using the stl file |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
December 16, 2014, 12:15 |
snappyHexMesh is not using the stl file
|
#1 |
Member
Ahmad Habib
Join Date: Nov 2014
Location: Aleppo, Syria
Posts: 53
Rep Power: 12 |
Hello every one, I'm training on the use of snappyHexMesh and during the procedure I'm having a problem,the snappyHexMesh is not using the triSurfaces so there is no cells to remove, it types these in the terminal:
( Not all entries in refinementSurfaces dictionary were used. The following entries were not used : 1(car.stl) ) and ( Not all entries in refinementRegions dictionary were used. The following entries were not used : 1(car.stl) ) - the *.stl file where made once by SOLIDWORKS (ASCII format) and once by FreeCAD (ASCII format). - the stl file is in the correct direction (constant/triSurface). - the stl file is closed surface (I used surfaceCheck). - the stl file is like this: (( solid car facet normal 0.991911 0.126938 0.000000 outer loop vertex -0.026076 -0.011176 -0.033830 vertex -0.026017 -0.011637 -0.033390 . . . vertex -0.025949 -0.012660 0.031710 endloop endfacet endsolid car)) - the stl file is in the center of the background mesh (I used paraview to make sure). - the background mesh has the aspect ratio of 1 and an appropriate grid spacing (the stl file is much much bigger than the zero level cell. so what to do please help |
|
December 16, 2014, 12:33 |
|
#2 |
New Member
larry
Join Date: Jul 2014
Posts: 12
Rep Power: 12 |
Hi Ahmad,
I am also new to OpenFOAM world. Can you post your snappyHexMeshDict file? Maybe during copy paste you have made an error in the geometry sub-directory of snappyHexMesh. Are you sure that the names corresponds to the .stl surfaces? |
|
December 16, 2014, 12:59 |
snappyHexMeshDict
|
#3 |
Member
Ahmad Habib
Join Date: Nov 2014
Location: Aleppo, Syria
Posts: 53
Rep Power: 12 |
Code:
/*--------------------------------*- C++ -*----------------------------------*\ | ========= | | | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | | \\ / O peration | Version: 2.3.0 | | \\ / A nd | Web: www.OpenFOAM.org | | \\/ M anipulation | | \*---------------------------------------------------------------------------*/ FoamFile { version 2.0; format ascii; class dictionary; object snappyHexMeshDict; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // castellatedMesh true; snap true; addLayers false; geometry { car.stl { type triSurfaceMesh; name cylinder; } refineBox { type searchableBox; min (-0.1 -0.1 -0.1); max (0.1 0.1 0.1); } }; castellatedMeshControls { maxLocalCells 10000000; maxGlobalCells 10000000; minRefinementCells 0; nCellsBetweenLevels 1; features ( ); refinementSurfaces { car.stl { // Surface-wise min and max refinement level level (4 4); } } resolveFeatureAngle 30; refinementRegions { refineBox { mode inside; levels ((1E15 2)); } car.stl { mode distance; levels ((0.05 4) (0.1 3)); } } locationInMesh (-0.19999 0.0001 0.0001); allowFreeStandingZoneFaces true; } snapControls { nSmoothPatch 3; tolerance 1.0; nSolveIter 300; nRelaxIter 5; nFeatureSnapIter 10; implicitFeatureSnap false; explicitFeatureSnap true; multiRegionFeatureSnap true; } addLayersControls { relativeSizes true; layers { // "" // { // nSurfaceLayers 1; // } } expansionRatio 1.0; finalLayerThickness 0.3; minThickness 0.25; nGrow 0; featureAngle 30; nRelaxIter 5; nSmoothSurfaceNormals 1; nSmoothNormals 3; nSmoothThickness 10; maxFaceThicknessRatio 0.5; maxThicknessToMedialRatio 0.3; minMedianAxisAngle 90; nBufferCellsNoExtrude 0; nLayerIter 50; nRelaxedIter 20; } meshQualityControls { #include "meshQualityDict" relaxed { maxNonOrtho 75; } nSmoothScale 4; errorReduction 0.75; } writeFlags ( scalarLevels // write volScalarField with cellLevel for postprocessing layerSets // write cellSets, faceSets of faces in layer layerFields // write volScalarField for layer coverage ); mergeTolerance 1E-6; // ************************************************************************* // Last edited by a_habib; December 16, 2014 at 14:45. |
|
December 16, 2014, 13:08 |
|
#4 |
New Member
larry
Join Date: Jul 2014
Posts: 12
Rep Power: 12 |
Hi Ahmad
Make the following modification and tell me if it works Code:
geometry { car.stl { type triSurfaceMesh; name car; } |
|
December 16, 2014, 14:10 |
|
#5 |
Member
Ahmad Habib
Join Date: Nov 2014
Location: Aleppo, Syria
Posts: 53
Rep Power: 12 |
it didn't work and I don't know where the ''cylinder'' came from,
|
|
December 16, 2014, 14:24 |
|
#6 |
New Member
larry
Join Date: Jul 2014
Posts: 12
Rep Power: 12 |
Hi Ahmad,
I think that your snappyHexMeshDict is not correct. For example, you haven't included anything in the features sub-dictionary. I am not sure but for your case the feature subdictionary should be sth like that: Code:
features ( { file "car.eMesh"; level 2; } ) |
|
December 16, 2014, 14:36 |
|
#7 |
Member
Ahmad Habib
Join Date: Nov 2014
Location: Aleppo, Syria
Posts: 53
Rep Power: 12 |
look at this
Code:
Reading refinement surfaces. --> FOAM Warning : From function refinementSurfaces::refinementSurfaces(..) in file autoHexMesh/refinementSurfaces/refinementSurfaces.C at line 226 Reading "/home/ahmad/my_tutorials/snappyHexMesh/car_snappyHexMesh_02/system/snappyHexMeshDict.castellatedMeshControls.refinementSurfaces" from line 70 to line 70 Not all entries in refinementSurfaces dictionary were used. The following entries were not used : 1(car.stl) Read refinement surfaces in = 0.02 s Reading refinement shells. Refinement level 2 for all cells inside refineBox --> FOAM Warning : From function shellSurfaces::shellSurfaces(..) in file autoHexMesh/shellSurfaces/shellSurfaces.C at line 420 Reading "/home/ahmad/my_tutorials/snappyHexMesh/car_snappyHexMesh_02/system/snappyHexMeshDict.castellatedMeshControls.refinementRegions" from line 82 to line 88 Not all entries in refinementRegions dictionary were used. The following entries were not used : 1(car.stl) Read refinement shells in = 0 s |
|
December 16, 2014, 17:33 |
I Got It
|
#8 |
Member
Ahmad Habib
Join Date: Nov 2014
Location: Aleppo, Syria
Posts: 53
Rep Power: 12 |
this is the it:
Code:
refinementSurfaces { car { level (3 3); } } resolveFeatureAngle 30; refinementRegions { refineBox { mode inside; levels ((1E15 1)); } car { mode distance; levels ((0.05 3) (0.1 2)); } } |
|
December 16, 2014, 17:50 |
|
#9 |
New Member
larry
Join Date: Jul 2014
Posts: 12
Rep Power: 12 |
That's nice man!!
I am happy you solved your problem. Regards, Christos |
|
June 12, 2020, 18:36 |
Thank you contributors!
|
#10 |
New Member
Morgan
Join Date: Jun 2020
Posts: 2
Rep Power: 0 |
The above posts were very helpful to me in troubleshooting my snappyHexMesh. Thanks all!
|
|
Tags |
help needed, snappyhexmesh, stl file |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
[swak4Foam] funkyDoCalc with OF2.3 massflow | NiFl | OpenFOAM Community Contributions | 14 | November 25, 2020 04:30 |
OpenFoam "Permission denied" and "command not found" problems. | iyidaniel@yahoo.co.uk | OpenFOAM Running, Solving & CFD | 11 | January 2, 2018 07:47 |
polynomial BC | srv537 | OpenFOAM Pre-Processing | 4 | December 3, 2016 10:07 |
SparceImage v1.7.x Issue on MAC OS X | rcarmi | OpenFOAM Installation | 4 | August 14, 2014 07:42 |
ParaView Compilation | jakaranda | OpenFOAM Installation | 3 | October 27, 2008 12:46 |