Function t8_forest_adapt_refine_recursive

Function Documentation

static void t8_forest_adapt_refine_recursive(t8_forest_t forest, t8_locidx_t ltreeid, t8_eclass_t tree_class, t8_locidx_t lelement_id, const t8_scheme *scheme, sc_list_t *elem_list, t8_element_array_t *telements, t8_locidx_t *num_inserted, t8_element_t **el_buffer, int *element_removed)

Check the lastly inserted element of an array for recursive refining or removing.

Parameters:
  • forest[in] The new forest currently in construction.

  • ltreeid[in] The current local tree.

  • tree_class[in] The eclass of tree ltreeid.

  • lelement_id[in] The id of the currently coarsened element in the tree of the original forest.

  • scheme[in] The scheme for this local tree.

  • elem_list[in] Helper list to temporarily insert the newly refined elements. These will eventually get copied to telements.

  • telements[in] The array of newly created (adapted) elements. The last inserted element must be the last child in its family.

  • num_inserted[inout] On input the number of elements in telement, on output the new number of elements (so it will be smaller or equal to its input).

  • el_buffer[in] Enough buffer space to store all children of the lastly created element.

  • element_removed[in] Flag set to 1 if element was removed.