|
p4est 2.8.7.456-de8c6
p4est is a software library for parallel adaptive mesh refinement.
|
Provide various functions to interface dune to a p4est mesh. More...
#include <p4est_iterate.h>
Go to the source code of this file.
Functions | |
| void | p4est_dune_iterate_balanced (p4est_t *p4est, p4est_ghost_t *ghost_layer, void *user_data, p4est_iter_volume_t iter_volume, p4est_iter_face_t iter_face) |
| Volume and face iterator over a 2:1 balanced forest. | |
| void | p4est_dune_iterate (p4est_t *p4est, p4est_ghost_t *ghost_layer, void *user_data, p4est_iter_volume_t iter_volume, p4est_iter_face_t iter_face) |
| Execute user supplied callbacks at every local volume and face. | |
Provide various functions to interface dune to a p4est mesh.
For example, populate element corner and face number tables, where the range for each codimension begins with 0 and is contiguous.
We also provide a face-only variant of the iterator that visits all small quadrants on one side of a hanging face from separate callbacks in order.
| void p4est_dune_iterate | ( | p4est_t * | p4est, |
| p4est_ghost_t * | ghost_layer, | ||
| void * | user_data, | ||
| p4est_iter_volume_t | iter_volume, | ||
| p4est_iter_face_t | iter_face | ||
| ) |
Execute user supplied callbacks at every local volume and face.
Execute the user-supplied callback functions at every volume and face in the local forest. When multiple small quadrants are on the other side of the face of a large quadrant, the callback is executed for every small face neighbor in turn, with the same large quadrant on the other side. The user_data pointer is not touched by the iterator, only passed to each of the callbacks. Any of the callbacks may be NULL. The callback functions are interspersed with each other, i.e. some face callbacks will occur between volume callbacks:
The convention for the context information passed to the callbacks is the same as for p4est_iterate with the following exception: For a hanging face, we call the callback anew for every small neighbor quadrant with the same large neighbor quadrant. The hanging side data (see p4est_iter_face_side_hanging_t) is populated at index [0] each time, and we store the number of the small quadrant within the order of its face siblings in the variable is.hanging.quadid[1], values in [0, 2).
| [in] | p4est | The forest to iterate over. It is not required to be 2:1 balanced. |
| [in] | ghost_layer | Valid ghost structure or NULL. |
| [in,out] | user_data | optional context to supply to each callback. |
| [in] | iter_volume | callback function for every quadrant interior. |
| [in] | iter_face | callback function for every face between. |
| void p4est_dune_iterate_balanced | ( | p4est_t * | p4est, |
| p4est_ghost_t * | ghost_layer, | ||
| void * | user_data, | ||
| p4est_iter_volume_t | iter_volume, | ||
| p4est_iter_face_t | iter_face | ||
| ) |
Volume and face iterator over a 2:1 balanced forest.
See p4est_dune_iterate for a detailed reference.