unstructured mesh data structure for FVM
Dear all,
I am looking for an efficient way to extract cell->node connectivity from face->cell and face->node connectivities. Cell->node connectivity has node(vertex) numbers forming each cell. Fluent's Gambit exports mixed element mesh data with face->cell and face->node connectivities only. But my fv solver and post-processing code require cell->node connectivity. Any comments are welcome. Thank you. |
Re: unstructured mesh data structure for FVM
There is a way here, but I am not sure if it's efficient enough:
(1) Looop faces: extract the face->cell information to cell->face information. (2) Loop cells: get the cell->vertex information based on cell->face and face->vertex. I am glad to hear some other more efficient way. Ma |
Re: unstructured mesh data structure for FVM
Invert the face->cell mapping to get the cell->face mapping. Then you can proceed to write the cell->node mapping. You may need to remove duplicate entries in the cell->node mapping. The simplest way is to use an array to carry a flag for duplicated nodes. You can also use a set if you prefer.
If your fv solver expects the nodes to be in a certain order, then the problem is a little more difficult. You will have to sort the cell->face mapping based on the way the faces are connected to each other. Once the cell topology can be inferred from the cell->face mapping, the nodes can be written out in whatever order the fv solver expects. It should be an interesting exercise. Good luck, Madhukar |
Re: unstructured mesh data structure for FVM
See the recent book by Rainald Lohner Applied CFD Techniques: An Introduction based on Finite Element Method.
|
All times are GMT -4. The time now is 15:30. |