QUGaR 0.0.7
Loading...
Searching...
No Matches
qugar::UnfittedKDTree< dim > Class Template Reference

#include <unfitted_domain_kd_tree.hpp>

Inheritance diagram for qugar::UnfittedKDTree< dim >:
[legend]
Collaboration diagram for qugar::UnfittedKDTree< dim >:
[legend]

Public Member Functions

 UnfittedKDTree (const GridPtr grid)
 
 UnfittedKDTree (const SubGridPtr subgrid)
 
bool is_leaf () const
 
void set_status (const ImmersedCellStatus &status)
 
void branch ()
 
ImmersedCellStatus get_status () const
 
SubGridPtr get_subgrid () const
 
GridPtr get_grid () const
 
SelfPtr get_child (int index)
 
SelfConstPtr get_child (int index) const
 
bool is_in_tree (std::int64_t cell_id) const
 
SelfConstPtr find_leaf (std::int64_t cell_id) const
 
void get_leaves (ImmersedCellStatus status, std::vector< SelfConstPtr > &leaves) const
 
void get_cell_ids (ImmersedCellStatus status, std::vector< std::int64_t > &cell_ids) const
 
void get_cell_ids (ImmersedCellStatus status, const std::vector< std::int64_t > &target_cell_ids, std::vector< std::int64_t > &cell_ids) const
 
std::size_t get_num_cells (ImmersedCellStatus status) const
 
std::size_t get_num_leaves (ImmersedCellStatus status) const
 
bool is_cell (ImmersedCellStatus status, std::int64_t cell_id) const
 

Private Types

using GridPtr = std::shared_ptr<const CartGridTP<dim>>
 
using SubGridPtr = std::shared_ptr<const SubCartGridTP<dim>>
 
using Self = UnfittedKDTree<dim>
 
using SelfConstPtr = std::shared_ptr<const Self>
 
using SelfPtr = std::shared_ptr<Self>
 

Private Member Functions

template<typename Func_0 , typename Func_1 >
void transverse_tree (const Func_0 &func_0, const Func_1 &func_1) const
 
template<typename Func_0 , typename Func_1 >
std::size_t reduce (const Func_0 &func_0, const Func_1 &func_1) const
 

Static Private Member Functions

static std::function< bool(const Self &)> create_leaf_checker (ImmersedCellStatus status)
 

Private Attributes

SubGridPtr subgrid_
 
ImmersedCellStatus status_
 
std::array< std::shared_ptr< UnfittedKDTree< dim > >, 2 > children_
 

Member Typedef Documentation

◆ GridPtr

template<int dim>
using qugar::UnfittedKDTree< dim >::GridPtr = std::shared_ptr<const CartGridTP<dim>>
private

◆ Self

template<int dim>
using qugar::UnfittedKDTree< dim >::Self = UnfittedKDTree<dim>
private

◆ SelfConstPtr

template<int dim>
using qugar::UnfittedKDTree< dim >::SelfConstPtr = std::shared_ptr<const Self>
private

◆ SelfPtr

template<int dim>
using qugar::UnfittedKDTree< dim >::SelfPtr = std::shared_ptr<Self>
private

◆ SubGridPtr

template<int dim>
using qugar::UnfittedKDTree< dim >::SubGridPtr = std::shared_ptr<const SubCartGridTP<dim>>
private

Constructor & Destructor Documentation

◆ UnfittedKDTree() [1/2]

template<int dim>
qugar::UnfittedKDTree< dim >::UnfittedKDTree ( const GridPtr grid)
explicit

◆ UnfittedKDTree() [2/2]

template<int dim>
qugar::UnfittedKDTree< dim >::UnfittedKDTree ( const SubGridPtr subgrid)
explicit

Member Function Documentation

◆ branch()

template<int dim>
void qugar::UnfittedKDTree< dim >::branch ( )

◆ create_leaf_checker()

template<int dim>
static std::function< bool(const Self &)> qugar::UnfittedKDTree< dim >::create_leaf_checker ( ImmersedCellStatus status)
staticprivate

◆ find_leaf()

template<int dim>
SelfConstPtr qugar::UnfittedKDTree< dim >::find_leaf ( std::int64_t cell_id) const
nodiscard

◆ get_cell_ids() [1/2]

template<int dim>
void qugar::UnfittedKDTree< dim >::get_cell_ids ( ImmersedCellStatus status,
const std::vector< std::int64_t > & target_cell_ids,
std::vector< std::int64_t > & cell_ids ) const

◆ get_cell_ids() [2/2]

template<int dim>
void qugar::UnfittedKDTree< dim >::get_cell_ids ( ImmersedCellStatus status,
std::vector< std::int64_t > & cell_ids ) const

◆ get_child() [1/2]

template<int dim>
SelfPtr qugar::UnfittedKDTree< dim >::get_child ( int index)
nodiscard

◆ get_child() [2/2]

template<int dim>
SelfConstPtr qugar::UnfittedKDTree< dim >::get_child ( int index) const
nodiscard

◆ get_grid()

template<int dim>
GridPtr qugar::UnfittedKDTree< dim >::get_grid ( ) const
nodiscard

◆ get_leaves()

template<int dim>
void qugar::UnfittedKDTree< dim >::get_leaves ( ImmersedCellStatus status,
std::vector< SelfConstPtr > & leaves ) const

◆ get_num_cells()

template<int dim>
std::size_t qugar::UnfittedKDTree< dim >::get_num_cells ( ImmersedCellStatus status) const
nodiscard

◆ get_num_leaves()

template<int dim>
std::size_t qugar::UnfittedKDTree< dim >::get_num_leaves ( ImmersedCellStatus status) const
nodiscard

◆ get_status()

template<int dim>
ImmersedCellStatus qugar::UnfittedKDTree< dim >::get_status ( ) const
nodiscard

◆ get_subgrid()

template<int dim>
SubGridPtr qugar::UnfittedKDTree< dim >::get_subgrid ( ) const
nodiscard

◆ is_cell()

template<int dim>
bool qugar::UnfittedKDTree< dim >::is_cell ( ImmersedCellStatus status,
std::int64_t cell_id ) const
nodiscard

◆ is_in_tree()

template<int dim>
bool qugar::UnfittedKDTree< dim >::is_in_tree ( std::int64_t cell_id) const
nodiscard

◆ is_leaf()

template<int dim>
bool qugar::UnfittedKDTree< dim >::is_leaf ( ) const
nodiscard

◆ reduce()

template<int dim>
template<typename Func_0 , typename Func_1 >
std::size_t qugar::UnfittedKDTree< dim >::reduce ( const Func_0 & func_0,
const Func_1 & func_1 ) const
private

◆ set_status()

template<int dim>
void qugar::UnfittedKDTree< dim >::set_status ( const ImmersedCellStatus & status)

◆ transverse_tree()

template<int dim>
template<typename Func_0 , typename Func_1 >
void qugar::UnfittedKDTree< dim >::transverse_tree ( const Func_0 & func_0,
const Func_1 & func_1 ) const
private

Member Data Documentation

◆ children_

template<int dim>
std::array<std::shared_ptr<UnfittedKDTree<dim> >, 2> qugar::UnfittedKDTree< dim >::children_
private

◆ status_

template<int dim>
ImmersedCellStatus qugar::UnfittedKDTree< dim >::status_
private

◆ subgrid_

template<int dim>
SubGridPtr qugar::UnfittedKDTree< dim >::subgrid_
private

The documentation for this class was generated from the following file: