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

mirrorMesh error

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

Reply
 
LinkBack Thread Tools Display Modes
Old   December 2, 2015, 13:29
Default mirrorMesh error
  #1
Member
 
Join Date: Dec 2015
Posts: 40
Rep Power: 3
WhiteW is on a distinguished road
Hello to everyone, I'm using OpenFoam 2.3.0. I'm facing a problem with the function mirrorMesh that should be simply to solve..
I have make a simple mesh of an half cylinder in Gambit and saved in msh format.
I would like to reconstruct the entire mesh in OpenFoam by mirroring it.
I initialy convert the mesh in the openfoam format using
fluent3DMeshToFoam half_cil.msh
And this creates the polymesh folder.
Then when I try tu run the command
mirrorMesh
But I get the followng error:

--> FOAM FATAL ERROR:

request for objectRegistry region0 from objectRegistry half_cil failed
available objects of type objectRegistry are
0()

From function objectRegistry::lookupObject<Type>(const word&) const
in file db/objectRegistry/objectRegistryTemplates.C at line 198.

FOAM aborting


What could be the cause of this error?
I have set the mirrorMeshDict file as follow:

/*--------------------------------*- C++ -*----------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: 2.3.0 |
| \\ / A nd | Web: www.OpenFOAM.org |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class dictionary;
object mirrorMeshDict;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

planeType pointAndNormal;

pointAndNormalDict
{
basePoint (0 0 0);
normalVector (0 1 0);
}

planeTolerance 1e-5;

// ************************************************** *********************** //
WhiteW is offline   Reply With Quote

Old   December 2, 2015, 16:28
Default
  #2
Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 9,749
Blog Entries: 39
Rep Power: 103
wyldckat is a glorious beacon of lightwyldckat is a glorious beacon of lightwyldckat is a glorious beacon of lightwyldckat is a glorious beacon of lightwyldckat is a glorious beacon of light
Quick question: Can you please provide a small test case so that we can reproduce this error? Because there isn't enough information in your post to deduce what is the exact error
Or at least I don't remember a similar problem ever occurring with me and mirrorMesh.
wyldckat is offline   Reply With Quote

Old   December 3, 2015, 09:46
Default
  #3
Member
 
Join Date: Dec 2015
Posts: 40
Rep Power: 3
WhiteW is on a distinguished road
Thanks for the reply.
I cleaned some files in the folder, and adjusted the boundary condition in the folder 0 and now it works.
I thought the mirrorMesh command wasn't related to the setting in 0 and system folder.
I have some question about the command:
- mirrorMesh mirrors a mesh on a given plane. It also merges the duplicated nodes on the mirror plane and removes the symmetry surfaces from the boundary list right? Other command are not necessary in order to "clean the mesh" right?
- in the case I'm studying (an airplane), one of the symmetry faces on the symmetry plane is not completely planar. Indeed some cells of this face are still present after the mirrorMesh command(as shown in the image). Is there a way to adjust this nodes (they y value has to be y=0)
Thanks!
Attached Images
File Type: png Screenshot.png (30.3 KB, 12 views)
WhiteW is offline   Reply With Quote

Old   December 6, 2015, 12:07
Default
  #4
Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 9,749
Blog Entries: 39
Rep Power: 103
wyldckat is a glorious beacon of lightwyldckat is a glorious beacon of lightwyldckat is a glorious beacon of lightwyldckat is a glorious beacon of lightwyldckat is a glorious beacon of light
Greetings WhiteW,

Quote:
Originally Posted by WhiteW View Post
I thought the mirrorMesh command wasn't related to the setting in 0 and system folder.
OpenFOAM is conceived to work as generically as possible. This means that for dynamic meshes, it can have the mesh in time folders for a particular time snapshot. In addition, the field fields in the "0" folder are sometimes taken into account by mesh utilities, for example for adding new boundaries or renaming old boundaries.

Quote:
Originally Posted by WhiteW View Post
- mirrorMesh mirrors a mesh on a given plane. It also merges the duplicated nodes on the mirror plane and removes the symmetry surfaces from the boundary list right? Other command are not necessary in order to "clean the mesh" right?
It should at least unassign all faces from the shared patch; in other words, the symmetry patch will have 0 faces assigned to it. Nonetheless, the shared patch might still be present in "constant/polyMesh/boundary" after mirrorMesh has done its job. You can use a nearly empty "system/createPatchDict" file and run createPatch for removing patches that have no faces assigned to them. A few tutorials in OpenFOAM demonstrate this (I'm using 3.0.0 as an example):
  • compressible/rhoPimpleDyMFoam/annularThermalMixer
  • incompressible/pimpleDyMFoam/oscillatingInletACMI2D
  • incompressible/simpleFoam/rotorDisk/
  • lagrangian/reactingParcelFilmFoam/rivuletPanel
  • lagrangian/reactingParcelFilmFoam/cylinder
  • multiphase/interDyMFoam/ras/mixerVesselAMI

Quote:
Originally Posted by WhiteW View Post
- in the case I'm studying (an airplane), one of the symmetry faces on the symmetry plane is not completely planar. Indeed some cells of this face are still present after the mirrorMesh command(as shown in the image). Is there a way to adjust this nodes (they y value has to be y=0)
You can either try using:
  • snappyHexMesh to snap these points onto a plane;
  • or use moveDynamicMesh, as demonstrated in the tutorial "mesh/moveDynamicMesh/SnakeRiverCanyon".
Best regards,
Bruno
__________________
wyldckat is offline   Reply With Quote

Old   December 6, 2015, 14:18
Default
  #5
Member
 
Join Date: Dec 2015
Posts: 40
Rep Power: 3
WhiteW is on a distinguished road
Thanks wyldckat, it is all more clear now.
I'll study snappyHexMesh commands to modify the node position of the mesh.
Thanks again for your help!

WhiteW
WhiteW is offline   Reply With Quote

Reply

Thread Tools
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 On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
blockMesh with double grading. spwater OpenFOAM Native Meshers: blockMesh 86 October 20, 2016 14:01
GroovyBC the dynamic cousin of funkySetFields that lives on the suburb of the mesh gschaider OpenFOAM 300 October 29, 2014 19:00
OpenFOAM without MPI kokizzu OpenFOAM Installation 4 May 26, 2014 09:17
compile error in dynamicMesh and thermophysicalModels libraries NickG OpenFOAM Installation 2 August 30, 2013 07:42
DecomposePar links against liblamso0 with OpenMPI jens_klostermann OpenFOAM Bugs 11 June 28, 2007 17:51


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