Template Struct cache_neighbors

Inheritance Relationships

Base Type

Struct Documentation

template<typename TUnderlying>
struct cache_neighbors : public t8_crtp_operator<TUnderlying, cache_neighbors>

Competence to cache the neighbors of an element at a specific face at the first function call.

Template Parameters:

TUnderlying – Use the element with specified competences as template parameter.

Public Functions

inline bool neighbor_cache_filled(int face) const

Function that checks if the neighbor cache for a face has been filled.

Parameters:

face[in] The face for which the cache should be checked.

Returns:

true if the cache has been filled, false otherwise.

inline bool neighbor_cache_filled_any() const

Function that checks if the neighbor cache for any face has been filled.

Returns:

true if the cache has been filled, false otherwise.

Protected Attributes

mutable std::vector<std::vector<const TUnderlying*>> m_neighbors

Neighboring elements at each face.

The length of the vectors is stored in m_num_neighbors.

mutable std::vector<std::optional<int>> m_num_neighbors

Vector with the numbers of neighbor elements at each face.

num_neighbors is stored to indicate that the cache is filled if a face does not have any neighbor.

mutable std::vector<std::vector<int>> m_dual_faces

Face id’s of the neighboring elements’ faces for each face.