CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Running, Solving & CFD (https://www.cfd-online.com/Forums/openfoam-solving/)
-   -   Implementation of adaptive Meshrefinement for 2D for rhoCentralFoam (https://www.cfd-online.com/Forums/openfoam-solving/123474-implementation-adaptive-meshrefinement-2d-rhocentralfoam.html)

Henning86 September 13, 2013 07:33

Implementation of adaptive Meshrefinement for 2D for rhoCentralFoam
 
Hi,


i managed to implement 2D adaptive Meshrefinement (only hex) for rhoCentralFoam.

The Implementation is based on the meshcutter. So the cells get first split in one direction and than in the other direction. (same idea as in refineMesh, multiDirRefinment)

This works great in the forward step tutorial of rhoCentralFoam - Refinement and Unrefinement. I already implemented it in parallel. I tested it on 12 processors and i get no errors. i had to change the meshcutter-class do be able to work in parallel.

The problem is if i cut a not perfect mesh with hex oriented in different directions. Some cells are not cut which results in a crash. Some of the missed cuts can be explained that there is no "splitHexCellLooper" but this can be implemented in one week.

Problem: the first refinement every cell are cut in both directions. But the second time the cells should be split results in a crash. Not only Splithex are not cut correct but hex as well, which isn't expected.

But if i restart the simulation the refinement works where it crashed in the first attempted.

I am really confused! i already checked CreateMesh.H but i find no hint in the constructors that the mesh is some how renumbered or something like that.

Any help is welcome.


All times are GMT -4. The time now is 18:31.