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

[snappyHexMesh] SnappyHexMesh: .eMesh file format

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   March 12, 2014, 12:01
Default SnappyHexMesh: .eMesh file format
  #1
New Member
 
Shantanu Kale
Join Date: Dec 2013
Posts: 25
Rep Power: 12
shantanukale is on a distinguished road
Hello!
What should be the file format for .eMesh file (binary or ascii)?
Also, I can see the geometry after running snappyHexMesh.
The geometry I am trying to simulate is circular cylinder in a rectangular domain.

Thank you.
shantanukale is offline   Reply With Quote

Old   March 13, 2014, 07:53
Default
  #2
Senior Member
 
Join Date: Mar 2010
Location: Germany
Posts: 154
Rep Power: 16
cutter is on a distinguished road
Hi,

it's a simple ASCII file format. Have a look at the tutorial cases! You can visualize the *.eMesh files using Paraview/ paraFoam.

Cutter


Code:
/*--------------------------------*- C++ -*----------------------------------*\
| =========                 |                                                 |
| \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox           |
|  \\    /   O peration     | Version:  2.2.x                                 |
|   \\  /    A nd           | Web:      www.OpenFOAM.org                      |
|    \\/     M anipulation  |                                                 |
\*---------------------------------------------------------------------------*/
FoamFile
{
    version     2.0;
    format      ascii;
    class       featureEdgeMesh;
    location    "constant/triSurface";
    object      Sample.eMesh;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //


// points:

2229
(
(2.6 7.44 3.8)
(2.6 7.44 0)
(1.95 7.44 3.8)
...
(0.419528 0.45 2.81578)
(0.425194 0.45 1.63303)
)


// edges:

2233
(
(171 172)
(173 174)
(175 173)
...
(369 25)
(26 370)
)

// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //


// ************************************************************************* //
cutter is offline   Reply With Quote

Old   March 13, 2014, 07:58
Default
  #3
New Member
 
Shantanu Kale
Join Date: Dec 2013
Posts: 25
Rep Power: 12
shantanukale is on a distinguished road
Thanks a lot...
The file that i have generated using surfaceFeatureExtract shows binary format.
i cant see the co-ordinates of the points.
in this case, what best can be done?

Thank You.
shantanukale is offline   Reply With Quote

Old   March 13, 2014, 10:07
Default
  #4
Senior Member
 
Join Date: Mar 2010
Location: Germany
Posts: 154
Rep Power: 16
cutter is on a distinguished road
Make sure the option writeFormat is set to ascii in you ./system/controlDict.

You may also set the option writeObj to yes in the file ./system/surfaceFeatureExtractDict. This will write *.obj files to ./constant/triSurface. These files are also human readable and can be visualized using Paraview/ paraFoam.

Cutter
cutter is offline   Reply With Quote

Old   March 14, 2014, 04:35
Default
  #5
New Member
 
Shantanu Kale
Join Date: Dec 2013
Posts: 25
Rep Power: 12
shantanukale is on a distinguished road
Thanks a lot...
The file is now written in ascii format.
How to remove cells in between a geometry. i am trying to mesh circular cylinder in square domain.

Thank You.
shantanukale is offline   Reply With Quote

Old   March 14, 2014, 06:58
Default
  #6
Senior Member
 
Join Date: Mar 2010
Location: Germany
Posts: 154
Rep Power: 16
cutter is on a distinguished road
You need to specify a point within your fluid domain in order the tell snappyHexMesh whether it needs to mesh at the inside or outside of your cylinder. This is done with the option locationInMesh in the ./system/snappyHexMeshDict.

Have a look at the tutorial cases (motorBike for example) and the documentation:

http://www.openfoam.org/docs/user/snappyHexMesh.php
https://sites.google.com/site/snappy...ppyhexmeshdict

Good luck!

Cutter
cutter is offline   Reply With Quote

Old   March 14, 2014, 07:10
Default
  #7
New Member
 
Shantanu Kale
Join Date: Dec 2013
Posts: 25
Rep Power: 12
shantanukale is on a distinguished road
Thanks a lot...
my domain size is (0,0,0) to (40, 20, 0.1)
i have the cylinder generated in paraview and then translated it using translation feature so that it can fit in the domain.
the location of the cylinder in the domain is (10.5,10.5,0.05)
locationinmesh point co-ordinates are (8.009512, 8.00900512, 0.019009512)

Thank You..
shantanukale is offline   Reply With Quote

Old   March 14, 2014, 09:14
Default
  #8
Senior Member
 
Join Date: Mar 2010
Location: Germany
Posts: 154
Rep Power: 16
cutter is on a distinguished road
No problem, nice to hear it's finally working.

Now it's my turn to ask questions: What are the steps to export the cylinder surface from Paraview? I tried it myself, the resulting STL file (via File->Save Data) is missing lots of triangles.

Thanks and good luck with your case!

Cutter
cutter is offline   Reply With Quote

Old   March 14, 2014, 09:37
Default
  #9
New Member
 
Shantanu Kale
Join Date: Dec 2013
Posts: 25
Rep Power: 12
shantanukale is on a distinguished road
The steps that I have followed are:
1. Generate a cylinder using sources option in menu bar
2. Using features, transform the geometry to the desired location (we may have to use the base geometry for this purpose, say a box in which the cylinder is located.
3. Then extract surface keeping the translation active.

Thank You.
shantanukale is offline   Reply With Quote

Old   November 25, 2015, 17:39
Default surfaceFeatureExtract in foam-extend 3.2
  #10
New Member
 
Nacho Larrabide
Join Date: Aug 2015
Posts: 2
Rep Power: 0
nacholarrabide is on a distinguished road
hi all,

sorry if this is not the right post for this question. If so, please point me in the right direction.

I'm trying to generate edges for a tube-like geometry using the surfaceFeatureExtract utility from foam-ext 3.2. I can get the right edges, but in .obj format and not .eMesh format. The thing is that I cannot input these to snappyMeshHex for edge snapping. Which is the right way to do this in foam-ext 3.2?

Thanks in advance,

Nacho
nacholarrabide is offline   Reply With Quote

Old   November 26, 2015, 15:15
Default
  #11
New Member
 
Nacho Larrabide
Join Date: Aug 2015
Posts: 2
Rep Power: 0
nacholarrabide is on a distinguished road
Well, I found a way out. Apparently the version of OpenFOAM behind foam_extend 3.2 is older than 2.2, so the new features of surfaceExtractFeatures (like using a Dict file) are not there. yet. My workaround was to install OpenFOAM 3.0 (sudo apt-get install openfoam30) and in a separate shell use the new utilities to preprocess the mesh. This is far from clean, but it works out well, since the new and old OpenFOAM mesh file formats are compatible (so far).

Nacho
nacholarrabide 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
[swak4Foam] swak4foam for OpenFOAM 4.0 mnikku OpenFOAM Community Contributions 80 May 17, 2022 08:06
OpenFoam "Permission denied" and "command not found" problems. iyidaniel@yahoo.co.uk OpenFOAM Running, Solving & CFD 11 January 2, 2018 06:47
polynomial BC srv537 OpenFOAM Pre-Processing 4 December 3, 2016 09:07
[swak4Foam] Problem installing swak_2.x for OpenFoam-2.4.0 towanda OpenFOAM Community Contributions 6 September 5, 2015 21:03
[OpenFOAM.org] Compile OF 2.3 on Mac OS X .... the patch gschaider OpenFOAM Installation 225 August 25, 2015 19:43


All times are GMT -4. The time now is 18:52.