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

[mesh manipulation] mirrorMesh is not preserving the mesh regions

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   April 11, 2023, 07:18
Default mirrorMesh is not preserving the mesh regions
  #1
Member
 
Zeinab
Join Date: Feb 2023
Posts: 32
Rep Power: 3
Zena27 is on a distinguished road
Hello all,
I have a cylinder that is divided in two regions. I already specified the regions when I am creating it on blockMesh, the problem is that when I mirror the mesh it loses all the data about the regions and it treats it as just one region.

Is there any solution for this? I am using OFv2212
Zena27 is offline   Reply With Quote

Old   July 4, 2023, 07:37
Default
  #2
New Member
 
Eduardo
Join Date: Feb 2019
Posts: 9
Rep Power: 7
ERodriguez is on a distinguished road
Hi Zeinab
Did you find the answer to this? I am going through your same problem ...
Regards
ERodriguez is offline   Reply With Quote

Old   July 4, 2023, 08:18
Default
  #3
Member
 
Zeinab
Join Date: Feb 2023
Posts: 32
Rep Power: 3
Zena27 is on a distinguished road
Hello,
actually no. Also, as far as I remember, the regions are not mirrored (also but not sure the cellzones). I could find a turn around to define the regions after mirroring.

You can tell me what would you like to do and I can try to help you with your case.
Zena27 is offline   Reply With Quote

Old   July 4, 2023, 09:07
Default
  #4
New Member
 
Eduardo
Join Date: Feb 2019
Posts: 9
Rep Power: 7
ERodriguez is on a distinguished road
Hi
Thanks for the quick answer

I have a relatively complex region in which I define several porous media through cellZones (I could work with cellSets also and then convert the sets into zones by using topoSet)

I have only meshed half of my domain because the geometry is a bit complex and it is easier. However, the flow is not symmetric so I need to simulate my whole domain. Imagine a C-shaped pipe, I can mesh only half of it but in order to simulate inlet and outlet I need to simulate the whole domain.

I am meshing by using another software and then converting into OpenFOAM format for half of my domain and I wanted to use mirrorMesh to duplicate my mesh. However, I am not keeping the cellZones so I would need to redefine all my porous media cellZones in order to assign their properties.

I think my problem was related to yours and also THIS post.

I might be able to redefine the cellZones after the mirrorMesh operation. However, the regions are rather complex and I would rather just use the cellZones that I have created in my meshing software directly into the OpenFOAM mesh.

Let me know if I could make anything clearer

Best regards
ERodriguez is offline   Reply With Quote

Old   July 6, 2023, 10:05
Default
  #5
Member
 
Zeinab
Join Date: Feb 2023
Posts: 32
Rep Power: 3
Zena27 is on a distinguished road
Hello,

sorry for the late reply. I don't think that there is way of doing it other than defining the cellZones again after mirroring, or by coding it.

I don't know about your case specifically but you can think about automating the generation of the cellZone using python.
Zena27 is offline   Reply With Quote

Old   July 14, 2023, 04:18
Default
  #6
New Member
 
Eduardo
Join Date: Feb 2019
Posts: 9
Rep Power: 7
ERodriguez is on a distinguished road
In case it is useful for someone in the future
At the end I found a workaround by using surfaceToCell in topoSet so I had to define (externally) *.stl files so the cells inside them were selected as my porous media. The bad thing about this approach is that sometimes cells near the boundary of the STL were wrongly selected so it required a lot of manual tweaking based on unselecting discrete cells based on their coordinates.
Anyway, it worked ...
Regards
ERodriguez 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
[snappyHexMesh] snappyHexMesh does not create any mesh except one for the reference cell Arman_N OpenFOAM Meshing & Mesh Conversion 1 May 20, 2019 18: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
[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
fluent add additional zones for the mesh file SSL FLUENT 2 January 26, 2008 12:55


All times are GMT -4. The time now is 10:16.