|
[Sponsors] |
[mesh manipulation] Multiplying a mesh n times |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
December 24, 2015, 08:24 |
Multiplying a mesh n times
|
#1 |
Senior Member
BastiL
Join Date: Mar 2009
Posts: 530
Rep Power: 20 |
Hello all,
I have the mesh of a segment of a geometry that I want to calculate. I want to multiply this mesh several times to create my final geometry. Additionally, the nodes at the patches where the parts are joining needs to be merged and switched from patches to internal faces. MirrorMesh does what I want as long as the geometry is symmetric, but is there something similar for geometries where I need to duplicate the mesh without mirroring? I did not find anything for this. |
|
January 12, 2016, 03:42 |
|
#2 |
Senior Member
Join Date: Mar 2010
Location: Germany
Posts: 154
Rep Power: 16 |
Hi,
I hope I got got your problem right: I suppose you're trying to simulate something like a pipe or channel consisting of multiple identical segments. You could create a copy of the original mesh for each segment and use moveMesh or transformPoints in order to put them at the correct place. Afterwards you need to use mergeMeshes and stitchMesh to connect them to one large mesh consisting of all the parts. Hope that helps. Cutter |
|
January 16, 2016, 08:04 |
|
#3 |
Senior Member
BastiL
Join Date: Mar 2009
Posts: 530
Rep Power: 20 |
Hello,
yes you got my problem right. The way you are describing may work but it is not so straightforward. I would be happy to have a utility similar to mirrorMesh, maybe multiplyMesh to perform such tasks. |
|
January 17, 2016, 15:21 |
|
#4 |
Senior Member
BastiL
Join Date: Mar 2009
Posts: 530
Rep Power: 20 |
Ok I tried the proposed way. It works smooth up to stitchMesh. Thsi fails. I guess the problem is that the boundary faces to be stitched are in one patch (because of running mirrorMesh and copying the mesh before). therefore I can't address the patches to be stitched.
|
|
January 17, 2016, 15:52 |
|
#5 |
Senior Member
Join Date: Mar 2010
Location: Germany
Posts: 154
Rep Power: 16 |
Well, you're almost at the finish line.
Rename the patches of the segments and use indices (for example inlet_part1, outlet_part1 and so on). Afterwards you'll be able to address them during the stitchMesh step. Renaming the patches can be done by simply editing the patch names within the dictionary constant/polyMesh/boundary. This can also be automated using simple shell scripts. |
|
January 17, 2016, 16:12 |
|
#6 |
Senior Member
BastiL
Join Date: Mar 2009
Posts: 530
Rep Power: 20 |
Its not that easy... I used mirrorMesh before since the geometry I need several times is symmetric itself. Mirrormesh mirrored the patch and therefore the "in" and "out" patch of the starting geometry are one. I need to split them of before copy. How can this be done?
|
|
January 17, 2016, 16:43 |
|
#7 |
Senior Member
Join Date: Mar 2010
Location: Germany
Posts: 154
Rep Power: 16 |
Use topoSet to select the faces that need to added to a separate patch (slightly larger box around them) and put them into a new face set. This face set can then be used to create a new patch using createPatch.
|
|
January 19, 2016, 04:09 |
|
#8 |
Senior Member
Niels Nielsen
Join Date: Mar 2009
Location: NJ - Denmark
Posts: 555
Rep Power: 27 |
Hi
I would really use Salome for this as it is much faster and does what you want in the same program. Just made a simple geo with mesh and copy the mesh. You can also rotate or use symmetry with a normal vector to make the mirror effect. At the end make a compound mesh and tick "merge coincident nodes". Export the mesh to UNV and use ideasUnvToFoam to convert the mesh. You need to fiddle with the BC's at the end, but that is easy compared to what you are trying to accomplish.
__________________
Linnemann PS. I do not do personal support, so please post in the forums. |
|
March 8, 2016, 10:50 |
|
#9 |
Member
Timm Severin
Join Date: Mar 2014
Location: Munich
Posts: 63
Rep Power: 12 |
I'm not entirely sure how it works, but OpenFOAM includes the extrudeMesh utility, which probably dies just what you want.
An example can be found in tutorials/multiphase/interFoam/ras/waterChannel It might take some code reading to figure out all possible options, or a couple of bananas.. but this way you can avoid the mergeMesh and stichMesh action.
__________________
PhD Student at the Institute of Biochemical Engineering at TU München Modelling of fluid dynamics in open photobioreactors. System: OpenFOAM 2.3.x, 64bit, 8 Core Xeon Workstation |
|
October 23, 2020, 05:33 |
|
#10 |
Senior Member
Franco
Join Date: Nov 2019
Location: Compiègne, France
Posts: 129
Rep Power: 6 |
hello,
i am facing the same type of geometry and would like how you got to achive it at the end? thanks a lot |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
[snappyHexMesh] Add Mesh Layers doesnt work on the whole surface | Kryo | OpenFOAM Meshing & Mesh Conversion | 13 | February 17, 2022 07:34 |
how to set periodic boundary conditions | Ganesh | FLUENT | 15 | November 18, 2020 06:09 |
[snappyHexMesh] snappyHexMesh does not create any mesh except one for the reference cell | Arman_N | OpenFOAM Meshing & Mesh Conversion | 1 | May 20, 2019 17:16 |
[mesh manipulation] Importing Multiple Meshes | thomasnwalshiii | OpenFOAM Meshing & Mesh Conversion | 18 | December 19, 2015 18:57 |
fluent add additional zones for the mesh file | SSL | FLUENT | 2 | January 26, 2008 11:55 |