|
[Sponsors] |
[snappyHexMesh] Multiple meshed components missing |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
February 24, 2020, 19:31 |
Multiple meshed components missing
|
#1 |
New Member
Carl Reilly
Join Date: Aug 2010
Posts: 26
Rep Power: 16 |
Hi,
I'm new to OpenFoam and snappyHexMesh and am trying to learn it via online tutorials and other sources. I have experience with other commercial packages. I am trying to mesh a relatively simple geometry which contains multiple bodies in snappyHexMesh. I have started to play with the snappyHexMeshDict and surfaceFeatureExtractDict to understand what each parameter does. At some point in my 'playing' I did something which means that instead of all components getting meshed, only one component is meshed at the end. Initially all components were being meshed. Attached is an image of the geometry (as defined after the surface extract step). Also attached is an image of the final mesh, as you can see it is only 1 of the 4 components that make up the geometry. (There are additional .stl files) to define the some of the surfaces where I want to apply patches/boundary conditions. If I redefine the "locationInMesh" variable then the part that is meshed is changed to the one containing the coordinate. I tried including multiple locationInMesh variables, but this does not work, only the last one is used. I have set debug to 1. This means I can view the meshing steps. At 0.012 all the mesh is present (see image), but at 0.013 only a single component is left. When looking in the log.mpirun file (running on 4cpu) I see that between 0.012 and 0.013 a step titled "Remove unreachable sections of mesh" is undertaken. (line 2512 of log.mpirun). I assume that for some reason snappy is removing the mesh from the other volumes. But i'm not sure why and how to resolve this. I know I should be able to mesh multiple volumes (as it did it initially). I think that the mesh is of high enough resolution to resolve the components adequately. Any help in resolving this would be appreciated, I have tried to attach all the relevant cast files. |
|
February 25, 2020, 08:13 |
|
#2 |
Member
Join Date: Sep 2018
Location: France
Posts: 62
Rep Power: 8 |
Hi carl,
Did you try with this function activated: Code:
multiRegionFeatureSnap true; |
|
February 25, 2020, 12:44 |
|
#3 |
New Member
Carl Reilly
Join Date: Aug 2010
Posts: 26
Rep Power: 16 |
Thanks for the reply. I checked my snappyHexMeshDict and found multiRegionFeatureSnap was set to false. I tried changing it to true but the results seem the same.
Any further thoughts? |
|
February 25, 2020, 13:36 |
|
#4 |
Member
Join Date: Sep 2018
Location: France
Posts: 62
Rep Power: 8 |
Another hint, by looking at the tutorial in heatTransfer/chtMultiRegionFoam/snappyMultiRegionHeater/system/snappyHexMeshDict,
you can try : Code:
locationsInMesh ( (( 0.005 0.005 0.005) heater) (( 0.05 0.005 0.005) rightSolid) ... ); // Whether any faceZones (as specified in the refinementSurfaces) // are only on the boundary of corresponding cellZones or also allow // free-standing zone faces. Not used if there are no faceZones. allowFreeStandingZoneFaces false; Cheers, |
|
February 25, 2020, 14:41 |
|
#5 |
New Member
Carl Reilly
Join Date: Aug 2010
Posts: 26
Rep Power: 16 |
I have just tried locationsInMesh and locationInMesh with multiple regions defined. With both I get an error from snappyHexMesh.
I think one issue is that I am using OpenFoam V7, not OpenFoam V1912 (OpenFoam.com). I know the solvers are slightly different, but had assumed (wrongly?) that sHM was the same. Am I correct in thinking that snappyHexMesh has no evolved to be different in the two versions of OpenFoam? If so, is this the correct forum for support with OpenFoam V7, and is there a commonly used way of specifying the OpenFoam release being used, or should I just have put Version: OpenFoam V7 in my initial post to clarify the version used? There is a tutorial in OpenFoam7 which appears to use multiple .stl files and regions in the domain. I'll try and understand this tutorial to see if it offers any insight to my issue. Code:
openfoam7\tutorials\heatTransfer\chtMultiRegionFoam\shellAndTubeHeatExchanger |
|
February 25, 2020, 14:58 |
|
#6 |
Member
Join Date: Sep 2018
Location: France
Posts: 62
Rep Power: 8 |
Yes this is the correct forum for both version don’t worry. You can mention your version on your first post for instance it is better for the other prople to know it. And yes there is on the last both versions some differences with some functions on the ESI versions (v1912, ...) for snappyHexMesh that are not implemented in the fundation versions (5, 6, ...). But mostly these are advanced functions so I don’t if there is some differences for chtMultiRegionFoam.
Cheers, |
|
February 25, 2020, 14:58 |
|
#7 |
New Member
Carl Reilly
Join Date: Aug 2010
Posts: 26
Rep Power: 16 |
This is an example of the error, it seems that it does not like the definition of
locationInMesh. The error for locationsInMesh says that it does not recognize the variable locationsInMesh. Code:
[3] Selecting decompositionMethod hierarchical [3] [3] [3] --> FOAM FATAL IO ERROR: [3] keyword locationInMesh is undefined in dictionary "IOstream.castellatedMeshControls" [0] [0] [0] --> FOAM FATAL IO ERROR: [0] keyword locationInMesh is undefined in dictionary "/home/carl/OpenFOAM/carl-7/run/castTest/system/snappyHexMeshDict.castellatedMeshControls" [0] [0] file: /home/carl/OpenFOAM/carl-7/run/castTest/system/snappyHexMeshDict.castellatedMeshControls from line 81 to line 165. [0] [0] From function const Foam::entry& Foam::dictionary::lookupEntry(const Foam::word&, bool, bool) const [0] in file db/dictionary/dictionary.C at line [3] [3] file: IOstream.castellatedMeshControls from line 0 to line 0. [3] [3] From function const Foam::entry& Foam::dictionary::lookupEntry(const Foam::word&, bool, bool) const [3] in file db/dictionary/dictionary.C at line 573. [3] FOAM parallel run exiting |
|
November 10, 2021, 01:14 |
|
#8 |
Senior Member
Desh
Join Date: Mar 2021
Location: Sydney
Posts: 118
Rep Power: 5 |
Probably too late now but ''locationInMesh'' should be ''locationsInMesh''.
|
|
Tags |
bodies, multiple volumes, snappyhesmesh |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
[General] Extracting ParaView Data into Python Arrays | Jeffzda | ParaView | 30 | November 6, 2023 22:00 |
Velocity components residuals are missing when running with interDyMFoam | vsammartano | OpenFOAM Running, Solving & CFD | 13 | October 24, 2022 13:23 |
how to set periodic boundary conditions | Ganesh | FLUENT | 15 | November 18, 2020 07:09 |
[ICEM] Multiple edges | asal | ANSYS Meshing & Geometry | 2 | March 22, 2013 11:10 |
OpenFOAM static build on Cray XT5 | asaijo | OpenFOAM Installation | 9 | April 6, 2011 13:21 |