|
[Sponsors] |
[mesh manipulation] Using refineMesh for a unstructured mesh where direction is hard to define |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
November 9, 2018, 16:49 |
Using refineMesh for a unstructured mesh where direction is hard to define
|
#1 |
New Member
Chen Shen
Join Date: Sep 2018
Posts: 14
Rep Power: 8 |
Hello,
I have a mesh that is generated from fluent. The 2D mesh looks like this: Using the following refineMeshdict: Code:
set c1; // Type of coordinate system: // - global : coordinate system same for every cell. Usually aligned with // x,y,z axis. Specify in globalCoeffs section below. // - patchLocal : coordinate system different for every cell. Specify in // patchLocalCoeffs section below. coordinateSystem global; // Specifies 2 directions by a name and a vector. The normal direction is // calculated as tan1^tan2 globalCoeffs { tan1 ( 1 0 0 ); tan2 ( 0 1 0 ); } patchLocalCoeffs { // Normal direction is face normal of zero'th face of patch patch frontAndBackPlanes; tan1 ( 1 0 0 ); tan2 ( 0 1 0 ); } // Specifies the direction to be refined by the name used above // To refine in the third direction, use the keyword 'normal' directions ( tan1 tan2 // normal ); // Whether to use hex topology. This will // - if patchLocal: all cells on selected patch should be hex // - split all hexes in 2x2x2 through the middle of edges. useHexTopology yes; // Cut purely geometric (will cut hexes through vertices) or take // topology into account. Incompatible with 'useHexTopology' geometricCut no; // Write meshes from intermediate steps which will not pass the checkMesh. what is the correct approach to refine this mesh? I have tried using different value for tan1 and tan2, selecting patchLocal rather then global etc.. but with no luck. I have attached the test case. To run it, run: fluentMeshToFoam refineMesh.msh topoSet refineMesh Thanks, Chen |
|
November 12, 2018, 12:28 |
|
#2 |
New Member
Lorena Fernández Fernández
Join Date: May 2016
Location: Spain
Posts: 21
Rep Power: 10 |
Hi Chen,
I think that your problem it is because your mesh is no-structured. One edge have five cells as neighbour, it is not usual for this utility. You could try to change at "true": "useHexTopology", "geometricCut" or/and "writeMesh. Best regards, Lorena |
|
November 12, 2018, 20:13 |
|
#3 | |
New Member
Chen Shen
Join Date: Sep 2018
Posts: 14
Rep Power: 8 |
Quote:
Thanks for the suggestion. I have tried played with those options with no luck. However if I try to refine them adaptively at the run time (choose limits that all cells will fail into) all cells will be cut into 8 small cells without deformation. I tried to write my code to refine the mesh but I find it is hard to reording the old cells faces and vertices and insert new cell infos into them and make sure the connectivity remains correct. I plan to have a deep look into the adaptive mesh refinement code and modify refineMesh when I got the time. Chen |
||
January 21, 2019, 09:29 |
|
#4 |
Senior Member
krishna kant
Join Date: Feb 2016
Location: Hyderabad, India
Posts: 133
Rep Power: 10 |
Hello All,
I have a very simple question to ask, suppose I want to refine my mesh 16 or 40 times. Can I do it with refineMesh in one run ? or I need to keep on doing it for n number of times? |
|
January 21, 2019, 10:55 |
|
#5 | |
New Member
Lorena Fernández Fernández
Join Date: May 2016
Location: Spain
Posts: 21
Rep Power: 10 |
Quote:
Hi Krishna, As far as I know, you could not do it with a single run. Use recursively "topoSet" and "refineMesh" for each level of refinement you need. Regards, Lorena |
||
January 28, 2019, 03:44 |
|
#6 |
Senior Member
krishna kant
Join Date: Feb 2016
Location: Hyderabad, India
Posts: 133
Rep Power: 10 |
I have generated an unstructured mesh in icemcfd and I use refineMesh to mesh make it refine. It work fine when run in serial but shows problem in parallel mode. The error message is number of faces in communication is not same. Is this a general problem, ever reported before for refineMesh ?
|
|
Tags |
refinemesh, unstructured mesh |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Gambit problems | Althea | FLUENT | 22 | January 4, 2017 04:19 |
Moving mesh | Niklas Wikstrom (Wikstrom) | OpenFOAM Running, Solving & CFD | 122 | June 15, 2014 07:20 |
[Gmsh] 2D Mesh Generation Tutorial for GMSH | aeroslacker | OpenFOAM Meshing & Mesh Conversion | 12 | January 19, 2012 04:52 |
fluent add additional zones for the mesh file | SSL | FLUENT | 2 | January 26, 2008 12:55 |
unstructured vs. structured grids | Frank Muldoon | Main CFD Forum | 1 | January 5, 1999 11:09 |