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

[Salome] Salome-OpenFOAM external flow (around a ship)

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

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   August 8, 2009, 15:57
Default Salome-OpenFOAM external flow (around a ship)
  #1
Senior Member
 
Tomislav Maric
Join Date: Mar 2009
Location: Darmstadt, Germany
Posts: 284
Blog Entries: 5
Rep Power: 21
tomislav_maric is on a distinguished road
Hello everyone,

I'm trying to use Salome-MECA for meshing a ship. I've search all over the net and posted on Salome forum but I've hit a dead end.

Has anyone here used Salome-MECA to create hex. mesh for external 3D flows?

I have gone through all the tutorials and I'm really familiar with the GUI (and TUI for automatic geometry generation), but I just can't mesh a ship or anything with external 3D flow. Tetrahedron mesh is really not a problem, but hex is a big one.

Best regards,
Tomislav
tomislav_maric is offline   Reply With Quote

Old   August 8, 2009, 17:14
Default
  #2
Senior Member
 
Ahmed
Join Date: Mar 2009
Location: NY
Posts: 251
Rep Power: 18
Ahmed is on a distinguished road
It might help you
There are several ship cases on the following page
http://www.salome-platform.org/UserSection/salome_use/
I guess you can expand them to your needs
Ahmed is offline   Reply With Quote

Old   August 8, 2009, 20:03
Default
  #3
Senior Member
 
Tomislav Maric
Join Date: Mar 2009
Location: Darmstadt, Germany
Posts: 284
Blog Entries: 5
Rep Power: 21
tomislav_maric is on a distinguished road
Quote:
Originally Posted by Ahmed View Post
It might help you
There are several ship cases on the following page
http://www.salome-platform.org/UserSection/salome_use/
I guess you can expand them to your needs
Thank you, I've studied these, but they are not related to my problem at all.

As I have written in my latter post, the problem is meshing external 3d flows. I have already done complicated 2D hex meshes of S60 ship hull, but I have problems creating 3D hex meshes for external flows. So, if anyone has used Salome to generate 3D mesh for external flow please let me know, I'm having problems in this area.

Best,
Tomislav
tomislav_maric is offline   Reply With Quote

Old   August 9, 2009, 03:49
Default
  #4
Senior Member
 
linnemann's Avatar
 
Niels Nielsen
Join Date: Mar 2009
Location: NJ - Denmark
Posts: 555
Rep Power: 27
linnemann will become famous soon enough
Hi

I actually don't think Salome has 3D hex volume meshing capabilities unless you extrude the hex 2D mesh, but I could be wrong.
linnemann is offline   Reply With Quote

Old   August 9, 2009, 06:44
Default
  #5
Senior Member
 
Tomislav Maric
Join Date: Mar 2009
Location: Darmstadt, Germany
Posts: 284
Blog Entries: 5
Rep Power: 21
tomislav_maric is on a distinguished road
Quote:
Originally Posted by linnemann View Post
Hi

I actually don't think Salome has 3D hex volume meshing capabilities unless you extrude the hex 2D mesh, but I could be wrong.
I can only hope that this is not true. That would mean I have spent 10 days learning meshing in Salome and there's no way I can mesh a ship.

Thank you, I'll try and play around with extrusion, maybe I manage to make something useful.
tomislav_maric is offline   Reply With Quote

Old   August 9, 2009, 16:20
Default
  #6
Senior Member
 
linnemann's Avatar
 
Niels Nielsen
Join Date: Mar 2009
Location: NJ - Denmark
Posts: 555
Rep Power: 27
linnemann will become famous soon enough
Hi

What I would do.

Create a 2D tet mesh for all the patches (just as you have before just without volume mesh and no 2d hex) and then right-click the mesh and export to STL.

Then use the STL in engrid and create a prismatic boundary mesh where your hull is. Do this right and you will get as good results, since the prismatic boundary mesh captures the BL (guessing that's what you want) as good as Hexes.

Engrid has the possibility to export directly to OpenFOAM and even with polyhedra mesh, and polys give a good solution from my experience.

So you will have a prismatic BL at the patches you choose in engrid and you get the nice polyhedra cells in the volume = win-win :-)

Just what I would do.
linnemann is offline   Reply With Quote

Old   August 10, 2009, 05:19
Default
  #7
Senior Member
 
Tomislav Maric
Join Date: Mar 2009
Location: Darmstadt, Germany
Posts: 284
Blog Entries: 5
Rep Power: 21
tomislav_maric is on a distinguished road
@linneman

Thank you very much for the advice! Of course I'll try that!

Best regards,
Tomislav
tomislav_maric is offline   Reply With Quote

Old   August 10, 2009, 06:00
Default
  #8
Senior Member
 
santos's Avatar
 
Jose Luis Santos
Join Date: Mar 2009
Location: Portugal
Posts: 215
Rep Power: 18
santos is on a distinguished road
Send a message via Skype™ to santos
Hi Tomislav,

Another option: use Salome to create your geometry, export the patches in STL format (you can do it already in the Geometry module, no need to use the Mesh module), and use snappyHexMesh to create your hex/poly mesh.

Regards,
Jose Santos
santos is offline   Reply With Quote

Old   August 10, 2009, 06:05
Default
  #9
Senior Member
 
linnemann's Avatar
 
Niels Nielsen
Join Date: Mar 2009
Location: NJ - Denmark
Posts: 555
Rep Power: 27
linnemann will become famous soon enough
You could do that.

But as I recall snappyHexMesh doesn't have support for refining the surface mesh but uses the surface mesh to generate the volume mesh.

Exporting to an STL directly from the GEO module will give you VERY coarse tet cells on the surface.

A plane surface will just be 2 triangles.

But if snappyHexMesh has surface remesh capabilities that will surely be a good approach.

Regards
linnemann is offline   Reply With Quote

Old   August 10, 2009, 06:12
Default
  #10
Senior Member
 
santos's Avatar
 
Jose Luis Santos
Join Date: Mar 2009
Location: Portugal
Posts: 215
Rep Power: 18
santos is on a distinguished road
Send a message via Skype™ to santos
I think sHM doesnt work like that. It uses a blockMesh background mesh to define the surface mesh. Moreover, you can really refine the surface mesh, you even have a section for that in snappyHexMeshDict. Look in the User Guide for a more detailed description.

Regards,
Jose Santos
santos is offline   Reply With Quote

Old   August 10, 2009, 06:17
Default
  #11
Senior Member
 
Tomislav Maric
Join Date: Mar 2009
Location: Darmstadt, Germany
Posts: 284
Blog Entries: 5
Rep Power: 21
tomislav_maric is on a distinguished road
There are problems with snappy and ships. I'm actually working on ship simulations with two colleagues and they have tried using snappy for generating the mesh around the ship for a while and they had lots of problems with it. That's why I decided to try and use Salome or something other than snappy, and if I succeed in generating a good mesh, then we would all use that software.

here are their (and consequently mine) experiences:

[Sun Aug 9 2009 19:04:19] … the problems with snappy... allright:
1) There is no possibility to create a smooth transition area between the different refinement levels. A "step" does always exist
[Sun Aug 9 2009 19:04:37] … 2) sharp edges cannot be meshed easily
[Sun Aug 9 2009 19:05:18] … 3) getting a good mesh (area ratio, angles, determinants) etc. is a tough and nerve-killing issue


I'm trying to compile engrid with VTK from OpenFOAM ThirdParty directory and I'm having trouble finding VTKLIBDIR and VTKINCDIR... there are tons of headers and libs inside $ParaView_INST_DIR.. help?

Thank you both for the information!
tomislav_maric is offline   Reply With Quote

Old   August 10, 2009, 06:30
Default
  #12
Senior Member
 
santos's Avatar
 
Jose Luis Santos
Join Date: Mar 2009
Location: Portugal
Posts: 215
Rep Power: 18
santos is on a distinguished road
Send a message via Skype™ to santos
Have you tried the pre-compiled binaries from:
ftp://loerrach.engits.de/
?

If you happen to use OpenSUSE, you can grab recent RPMs from:
http://download.opensuse.org/reposit.../openSUSE_11.1

Regards,
Jose Santos
santos is offline   Reply With Quote

Old   August 10, 2009, 06:41
Default
  #13
Senior Member
 
Tomislav Maric
Join Date: Mar 2009
Location: Darmstadt, Germany
Posts: 284
Blog Entries: 5
Rep Power: 21
tomislav_maric is on a distinguished road
Quote:
Originally Posted by santos View Post
Have you tried the pre-compiled binaries from:
ftp://loerrach.engits.de/
?

If you happen to use OpenSUSE, you can grab recent RPMs from:
http://download.opensuse.org/reposit.../openSUSE_11.1

Regards,
Jose Santos
I did try this, and I have used ./setup under root and it installed the binaries without an error. Then when I tried to run it I got this:

tomislav@icarus:enGrid_linux32bit_1.0$ start_engrid
/opt/enGrid/engrid: relocation error: /opt/enGrid/libc.so.6: symbol _dl_out_of_memory, version GLIBC_PRIVATE not defined in file ld-linux.so.2 with link time reference

I'm running Ubuntu 8.10 Intrepid Ibex, had to switch from SUSE because I coulnd't find a way to connect via pptp protocol to the net, but that's another tale.
tomislav_maric is offline   Reply With Quote

Old   August 10, 2009, 06:58
Default
  #14
Senior Member
 
Tomislav Maric
Join Date: Mar 2009
Location: Darmstadt, Germany
Posts: 284
Blog Entries: 5
Rep Power: 21
tomislav_maric is on a distinguished road
I have used the .deb package reluctantly and it worked! I like to keep my applications local, especially when they are not listed in the official repos. I'll try and create the mesh now. Thank you both very much for your advice.
tomislav_maric is offline   Reply With Quote

Old   August 10, 2009, 07:00
Default
  #15
Senior Member
 
linnemann's Avatar
 
Niels Nielsen
Join Date: Mar 2009
Location: NJ - Denmark
Posts: 555
Rep Power: 27
linnemann will become famous soon enough
I unfortunately cant help you there since I'm not using Ubuntu.

But I've made a precompiled package available for CentoS 64Bit

https://sourceforge.net/projects/centfoam


I just checked what Santos wrote and he is correct about SnappyHexMesh, seems like a good approach.

I have only one advice, explode the volume into faces and export each face to a separate ASCII stl's and open them and give them meaningful names this will make the meshing in SHM easier. see here


Regards Linnemann
linnemann is offline   Reply With Quote

Old   August 10, 2009, 12:30
Default
  #16
Senior Member
 
Tomislav Maric
Join Date: Mar 2009
Location: Darmstadt, Germany
Posts: 284
Blog Entries: 5
Rep Power: 21
tomislav_maric is on a distinguished road
I have managed to create a 2D tet mesh of ship and domain faces in Salome.

Now I'm trying to import .stl in engrid, but there's nothing on the screen (even after I click redraw), and information bar on the bottom of the window states 0 mesh elements (both 2D and 3D). Am I doing something wrong? Is there some option to set in Salome? I only clicked "Import STL" and selected the .stl file.

I have tried to use .vtk and it worked fine.


Best regards,
Tomislav
tomislav_maric is offline   Reply With Quote

Old   August 10, 2009, 13:51
Default
  #17
Senior Member
 
Tomislav Maric
Join Date: Mar 2009
Location: Darmstadt, Germany
Posts: 284
Blog Entries: 5
Rep Power: 21
tomislav_maric is on a distinguished road
It's me again,

there is a problem with meshing 2D surfaces using Netgen 1D-2D automatic algorithm for generation of the mesh. The mesh looks great (to my layman eyes) but when I export it to .stl, the file has only

begin solid
end solid

and nothing in between. I'll try and get a good mesh with some other algorithms.

Best regards,

Tomislav
tomislav_maric is offline   Reply With Quote

Old   August 11, 2009, 12:00
Default
  #18
Senior Member
 
Tomislav Maric
Join Date: Mar 2009
Location: Darmstadt, Germany
Posts: 284
Blog Entries: 5
Rep Power: 21
tomislav_maric is on a distinguished road
This works only when using Netgen 2D for surfaces, then wire discretisation, than 0d node distance.

After battling with it for a while, I have managed to save a .stl file and read it into Engrid. When I tried to make the prismatic BL, I got this error:

p, li { white-space: pre-wrap; } CalcLocalH: 4104 Points 0 Elements 8200 Surface Elements
Check subdomain 1 / 1
8200 open elements
ERROR: Edge 2313 - 3335 multiple times in surface mesh
ERROR: Edge 2313 - 3336 multiple times in surface mesh
ERROR: Edge 3335 - 3336 multiple times in surface mesh
ERROR: Surface mesh not consistent
ERROR: Stop meshing since surface mesh not consistent
deleting Operation 0xa8e04a4


in the engrid output screen. Now, I had to manipulate the mesh by hand an create two additional triangles, because this kind of meshing in Salome gave me two/three really deformed triangles at the bow and stern corner of the deck face.



Could this cause this problem? How do I fix this?



Thanks in advance,
Tomislav
tomislav_maric is offline   Reply With Quote

Old   August 11, 2009, 12:02
Default
  #19
Senior Member
 
Tomislav Maric
Join Date: Mar 2009
Location: Darmstadt, Germany
Posts: 284
Blog Entries: 5
Rep Power: 21
tomislav_maric is on a distinguished road
sorry, I forgot to add:

I have made two separate meshes, one of the bounding box shell feature and one mesh of the ship hull shell feature in salome. Could this mean that some mesh elements ended up with the same ID number?

Best regards,
Tomislav
tomislav_maric is offline   Reply With Quote

Old   August 11, 2009, 12:35
Default
  #20
Senior Member
 
linnemann's Avatar
 
Niels Nielsen
Join Date: Mar 2009
Location: NJ - Denmark
Posts: 555
Rep Power: 27
linnemann will become famous soon enough
Hi

Quote:
I have made two separate meshes, one of the bounding box shell feature and one mesh of the ship hull shell feature in salome. Could this mean that some mesh elements ended up with the same ID number?
Yes I think that's whats going on

When using Engrid I don't think exporting the faces by themselves and then after wards combining will work (this was for SnappyHexMesh).

Try to export it as a single entity from Salome, you can always split the patches in Engrid, as per the manual (mouse + P then S).

Regards

Linnemann
linnemann is offline   Reply With Quote

Reply

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
Frequently Asked Questions about Installing OpenFOAM wyldckat OpenFOAM Installation 3 November 14, 2023 12:58
Simulation of flow around a ship hull using fluent and Openfoam manoj_nav FLUENT 0 December 17, 2015 02:05
Volume flow rate boundary condition in OpenFOAM mayank.dce2k7 OpenFOAM Running, Solving & CFD 13 August 11, 2014 21:16
[Salome] Mesh conversion Salome to OpenFOAM VMartinez OpenFOAM Meshing & Mesh Conversion 11 April 21, 2014 03:54
internal flow and external flow ? Pathway0320 FLUENT 1 November 17, 2006 04:37


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