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

[Other] Merging two different mesh

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

Like Tree1Likes
  • 1 Post By student666

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   September 1, 2017, 07:26
Default Merging two different mesh
  #1
New Member
 
Fabio
Join Date: Jun 2016
Posts: 11
Rep Power: 6
Fabiio87 is on a distinguished road
Dear all,

I was wondering if it is possible to create two different structured mesh with two different blockMeshDict file and then merge them together.

Does anybody know if it is possible to do this?

Best Regards,

Fabio
Fabiio87 is offline   Reply With Quote

Old   September 1, 2017, 09:19
Default
  #2
Senior Member
 
M. C.
Join Date: May 2013
Location: Italy
Posts: 286
Blog Entries: 6
Rep Power: 13
student666 is on a distinguished road
Code:
mergeMesh mastermesh slavemesh -overwrite
Sent from my ASUS_X008D using CFD Online Forum mobile app

Last edited by student666; September 1, 2017 at 16:16.
student666 is offline   Reply With Quote

Old   September 1, 2017, 09:29
Default
  #3
New Member
 
Fabio
Join Date: Jun 2016
Posts: 11
Rep Power: 6
Fabiio87 is on a distinguished road
Quote:
Originally Posted by student666 View Post
mergeMesh mastermesh slavemesh -overwrite

Sent from my ASUS_X008D using CFD Online Forum mobile app

Thanks for your reply.

For "mastermesh", "slavemesh" do you mean the name of the BlockMeshDict files?

Please let me know,

Regards,

Fabio
Fabiio87 is offline   Reply With Quote

Old   September 1, 2017, 11:08
Default
  #4
Senior Member
 
Join Date: Aug 2013
Posts: 404
Rep Power: 12
Antimony is on a distinguished road
Hi,

No. Not the names of the blockMeshDict files.

You need to create the two meshes and then call mergeMesh.

mastermesh should indicate the name/location of the case where the first mesh is located

slavemesh should indicate the name/location of the case where the second mesh is located

Hope this helps.

Cheers,
Antimony
Antimony is offline   Reply With Quote

Old   September 1, 2017, 16:23
Default
  #5
Senior Member
 
M. C.
Join Date: May 2013
Location: Italy
Posts: 286
Blog Entries: 6
Rep Power: 13
student666 is on a distinguished road
Read this.

http://www.sourceflux.de/blog/genera...snappyhexmesh/

It gives you a visual explanation

Eg: folder named run contains masterMesh and slaveMesh, so type into your terminal

Code:
oldpc@oldpc-DIXONSXP:~/OpenFOAM/oldpc-2.2.0/run$ mergeMeshes masterMesh slaveMesh -overwrite
Ciao
Fabiio87 likes this.
student666 is offline   Reply With Quote

Old   September 13, 2017, 12:03
Default
  #6
New Member
 
Fabio
Join Date: Jun 2016
Posts: 11
Rep Power: 6
Fabiio87 is on a distinguished road
Thanks for the very clear explanation.

Best Regards

Fabio

Quote:
Originally Posted by student666 View Post
Read this.

http://www.sourceflux.de/blog/genera...snappyhexmesh/

It gives you a visual explanation

Eg: folder named run contains masterMesh and slaveMesh, so type into your terminal

Code:
oldpc@oldpc-DIXONSXP:~/OpenFOAM/oldpc-2.2.0/run$ mergeMeshes masterMesh slaveMesh -overwrite
Ciao
Fabiio87 is offline   Reply With Quote

Old   March 10, 2020, 09:39
Default
  #7
Super Moderator
 
Tobi's Avatar
 
Tobias Holzmann
Join Date: Oct 2010
Location: Augsburg
Posts: 2,448
Blog Entries: 6
Rep Power: 46
Tobi has a spectacular aura aboutTobi has a spectacular aura aboutTobi has a spectacular aura about
Send a message via ICQ to Tobi Send a message via Skype™ to Tobi
Hi everybody,

actually I am facing the same question. However, getting through mergeMesh, it should not connect the two meshes. So I guess stitchMeshes can maybe do the work but actually I found, that it does not work properly. Imagine you have a block structured mesh (piston + liner) which needs to be merged with the mesh including the valve. How would you proceed? Using ACMI boundary conditions would make the deal here but I donīt want to waste computational costs regarding mapping / interpolation etc.
__________________
Keep foaming,
Tobias Holzmann
Tobi is offline   Reply With Quote

Old   September 22, 2020, 09:05
Default multiple blocks in Block mesh and then issues with snapyHexMesh
  #8
Member
 
Join Date: Apr 2015
Posts: 42
Rep Power: 7
HosseinB is on a distinguished road
Hi all,


I have spent a long time to figure this out and I couldn't.


I have a seven-block mesh and merged common surfaces using mergepatchpairs in the blockMeshDict. checkMesh of this mesh seems fine.


After this step, I position an STL object somewhere in the mesh and run the snappyHexMesh to prepare my mesh.



I get so many warning of this type and usually the meshing fails:


"
FOAM Warning :

From function static Foam::vectorField Foam::snappySnapDriver::calcNearestSurface(bool, const Foam::meshRefinement&, const labelList&, const labelList&, const scalarField&, const indirectPrimitivePatch&, Foam:ointField&, Foam::vectorField&)
in file snappyHexMeshDriver/snappySnapDriver.C at line 2021
For point:3631049 coordinate-5.4045 0 -0.445) did not find any surface within:0.0200667 metre.

"


These warning start right after the onset of mesh morphing and the coordinates given in the warning are the location of merged patches.

Last edited by HosseinB; September 23, 2020 at 14:28.
HosseinB is offline   Reply With Quote

Old   September 23, 2020, 14:30
Default
  #9
Member
 
Join Date: Apr 2015
Posts: 42
Rep Power: 7
HosseinB is on a distinguished road
The problem was not the mesh, it was a snapControls parameter named:



nFeatureSnapIter


which was causing the issue. I commented this it out and the problem was resolved.




version OpenFOAM 1912.
HosseinB is offline   Reply With Quote

Reply

Tags
blockmeshdict block mesh, meshing, openfoam

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] Add Mesh Layers doesnt work on the whole surface Kryo OpenFOAM Meshing & Mesh Conversion 12 March 11, 2020 17:16
[snappyHexMesh] Creating multiple multiple cell zones with snappyHexMesh - a newbie in deep water! divergence OpenFOAM Meshing & Mesh Conversion 0 January 23, 2019 05:17
[snappyHexMesh] SnappyHexMesh no layers and no decent mesh for complex geometry pizzaspinate OpenFOAM Meshing & Mesh Conversion 1 February 25, 2015 08:05
[ICEM] Generating Mesh for STL Car in Windtunnel Simulation tommymoose ANSYS Meshing & Geometry 48 April 15, 2013 05:24
[snappyHexMesh] Layers:problem with curvature giulio.topazio OpenFOAM Meshing & Mesh Conversion 10 August 22, 2012 10:03


All times are GMT -4. The time now is 01:02.