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

Import or generating Meshes from Koordinates Gau%c3%9fKr%c3%bcger

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

Reply
 
LinkBack Thread Tools Display Modes
Old   August 15, 2008, 06:47
Default Hello We are trying to eva
  #1
New Member
 
Tobias Rothhardt
Join Date: Mar 2009
Location: Hannover, Germany
Posts: 2
Rep Power: 0
toby is on a distinguished road
Hello

We are trying to evaluate if OpenFoam could help us solving different hydrodynamic and temperature distribution problems.

The Main Problem i have right know, is to generate a mesh from pure data or to import a mesh.
Maybe it helps if i tell briefly what we try to solve for: Most of the time we are generating meshes from koordinates which represents a 3D Surface, in general a river bed or part of a coastline. Then we start with certain water levels, water temperatures, water input at the one end of the model and water outgoing at the other end of the model. After these parameters are set we try to compute and visualise for water flow, turbulence or areas of overflooding.

So back to the origin Problem. I only have Data represented by koordinates in the Gauß-Krüger format (like 3559041.037 5813109.094 55.239). Generally there are about 10000-20000 of these points to describe the surface of the modelled area. So far i could not find out how to generate a mesh from this data. The other option would be to use another programm (opensource if possible) to generate the mesh from this data and then export in a format OpenFoam would be able to read.

Maybe anyone has an idea how we can do this or which mesh generator could work.

Maybe anyone solved allready hydrodynamic problems like described above with OpenFoam and could us to get started.

Thanks in advance.

T.Rothhardt
toby is offline   Reply With Quote

Old   August 15, 2008, 08:42
Default It sounds to me that you need
  #2
Senior Member
 
Hrvoje Jasak
Join Date: Mar 2009
Location: London, England
Posts: 1,763
Rep Power: 21
hjasak will become famous soon enough
It sounds to me that you need a separate mesh generator, capable of generating a surface description from a bunch of points (no ideas here).

As for hydrodynamics, I have been doing a lot of work here) - have a look at one recent movie of 2 bodies with 6-DOF solvers and automatic mesh motion in a free surface VOF flow:

http://powerlab.fsb.hr/ped/kturbo/OpenFOAM/movies/VOF+6-DOF/twoBoatsLargeDistanc e.mpg

Enjoy,

Hrv
__________________
Hrvoje Jasak
Providing commercial FOAM/OpenFOAM and CFD Consulting: http://wikki.co.uk
hjasak is offline   Reply With Quote

Old   August 15, 2008, 10:16
Default Hi I do not know, if the n
  #3
ngj
Senior Member
 
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Deltares, Delft, The Netherlands
Posts: 1,619
Rep Power: 25
ngj will become famous soon enoughngj will become famous soon enough
Hi

I do not know, if the numerical scheme behind the mesh motion is robust enough to accept possibly very large deformations, but assume that it is sufficiently robust then could you achieve what you want in the following way?

1. Generate a mesh with the correct horizontal lay-out which is extruded some magnitude in the y-direction.

2. The bottom patch, in the following called the bathymetry patch (BP), is horizontal, but you know the y-coordinate, y_Old.

3. Make an interpolation of you measured bathymetry onto every point on BP considered as a y_New=h(x,z) making the depth a dependent variable of the horizontal coordinates.

4. The distance delta = y_New - y_Old, could then be used to make a displacement of the lowermost points using the moving mesh algorithms.

5. The mesh is ready for some interesting work.

If it works, please let us know.

As it is bathymetries you are looking at the data set should be well behaved, i.e. one bed level per horizontal coordinate (x,z).

The most significant drawback is that you do not completely control the actual discretization of the mesh, but using the correct diffusion coefficients in the laplacian and make some clever choices in the initial plane bed mesh you should be able to control the upper bound in the discretization.

Further, as far as I am aware of, no such routine is present in OF, but it will not be impossible to make such an implementation.

Have fun,

Niels

P.S. Nice movie, Hrv
__________________
Please note that I do not use the Friend-feature, so do not be offended, if I do not accept a request.
ngj is offline   Reply With Quote

Old   August 15, 2008, 18:56
Default It depends on the geometry: I
  #4
Senior Member
 
Hrvoje Jasak
Join Date: Mar 2009
Location: London, England
Posts: 1,763
Rep Power: 21
hjasak will become famous soon enough
It depends on the geometry: I can do "reasonable things, corresponding to a non-trivial transfnite mapping, but wrapping a mesh around corners or in deep/sharp concave angles will probably not work...

Hrv
__________________
Hrvoje Jasak
Providing commercial FOAM/OpenFOAM and CFD Consulting: http://wikki.co.uk
hjasak is offline   Reply With Quote

Old   August 16, 2008, 10:07
Default I agree on the point that shar
  #5
ngj
Senior Member
 
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Deltares, Delft, The Netherlands
Posts: 1,619
Rep Power: 25
ngj will become famous soon enoughngj will become famous soon enough
I agree on the point that sharp angles will not do, but as Tobias apparently is considering river engineering, then it is highly unlikely that any angle will exceed the angle of repose (30 degrees), except if constructions are present of course.

- Niels
__________________
Please note that I do not use the Friend-feature, so do not be offended, if I do not accept a request.
ngj is offline   Reply With Quote

Old   August 18, 2008, 04:07
Default Well, thx for the answers so f
  #6
New Member
 
Tobias Rothhardt
Join Date: Mar 2009
Location: Hannover, Germany
Posts: 2
Rep Power: 0
toby is on a distinguished road
Well, thx for the answers so far, i will review the proposals as soon as i get to that point. I did some work on generating/importing an mesh in OF on Friday. I do have a closed source tool (which i would like to discard) to generate a mesh from my given Data and i also have a possibility to export this mesh in STL format. The next task has been to convert the mesh into a format OF can read and to manipulate the mesh. At the moment i'm trying out engrid, an opensource tool from http://www.engits.com . The current release (0.9) gives the possibility to import my STL Mesh and to export the mesh (after working on it) into Gmsh or Netgen Files. These formats i should then be able to import into OF (not done till now, i will try to do today). The next release shell even give native OF export which should make things easier.

I will now try to import the, lets call it "Bottom Surface Mesh" which represents the Riverbed and then i have to get somehow an other layer into it which shell represent my waterlevel or, as we talk about an VOF Problem, a fixed concentration at these points. After this i hopefully have a true 3-D Mesh and start with some calc on it.

I keep you informed about progress.
toby is offline   Reply With Quote

Old   November 21, 2008, 07:48
Default Hi Tobias, Engrid looks nic
  #7
Senior Member
 
Vincent RIVOLA
Join Date: Mar 2009
Location: France
Posts: 277
Rep Power: 9
vinz is on a distinguished road
Hi Tobias,

Engrid looks nice indeed.
Apparently you already tried it. I see you said you were importing STL files into Engrid and working with them.
Is it really possible to directly work on the stl file or should one do a surface mesh first in gmesh for intance??
I would be very interested in knowing what you think about this software after using it for sometime.

Thanks in advance.

Vincent
vinz is offline   Reply With Quote

Old   February 27, 2009, 16:25
Default I faced this same meshing prob
  #8
New Member
 
Jason Neuswanger
Join Date: Mar 2009
Location: Fairbanks, AK
Posts: 3
Rep Power: 8
jasonneuswanger is on a distinguished road
I faced this same meshing problem recently. I figured out something that kind of worked, although it was an ugly process and the results are far from ideal.

I set up my data for a simple ASCII .obj file using Excel, and copied and pasted it into a text editor and saved as .obj after replacing tabs with spaces. Then I imported the .obj file into Meshlab, which I used to create a 2D surface for the bathymetry, and saved it as a .ply file. I imported the .ply file into Blender, which I used to extrude the mesh to 3D, flatten the top, and separate different faces. I exported the .stl file from Blender that could be read by OpenFOAM.

Now I have a 3D snappyHexMesh for my riverbed in OpenFOAM, constructed entirely with open source software. That said, there were a million little tricks along the way, and the mesh misses a lot of bathymetry points.

I would like to know if you found a better solution to the problem using free and/or open-source software.
jasonneuswanger is offline   Reply With Quote

Reply

Thread Tools
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 On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Generating nonuniform meshes with sizefunction alberto OpenFOAM Native Meshers: blockMesh 27 April 18, 2012 03:53
File format for import meshes in OpenFoam t42 OpenFOAM Meshing Format & General Technical 5 August 1, 2007 08:45
BSL Automatic Wall Function - Shifted koordinates Sali CFX 0 April 26, 2007 05:04
Generating big meshes with GAMBIT on NT Andrew Ooi FLUENT 12 February 2, 2000 23:26
cylindrical koordinates I.Dotsikas Main CFD Forum 4 May 4, 1999 20:44


All times are GMT -4. The time now is 08:55.