Go to the documentation of this file.
20 #ifndef LIBMESH_TREE_H
21 #define LIBMESH_TREE_H
24 #include "libmesh/tree_node.h"
25 #include "libmesh/tree_base.h"
43 template <
unsigned int N>
51 unsigned int target_bin_size,
78 {
return root.n_active_bins(); }
86 const std::set<subdomain_id_type> * allowed_subdomains =
nullptr,
96 std::set<const Elem *> & candidate_elements,
97 const std::set<subdomain_id_type> * allowed_subdomains =
nullptr,
106 const std::set<subdomain_id_type> * allowed_subdomains =
nullptr,
151 #endif // LIBMESH_TREE_H
const Trees::BuildType build_type
How the tree is built.
virtual void find_elements(const Point &p, std::set< const Elem * > &candidate_elements, const std::set< subdomain_id_type > *allowed_subdomains=nullptr, Real relative_tol=TOLERANCE) const override
Fills candidate_elements with any elements containing the specified point p, optionally restricted to...
Tree< 2 > BinaryTree
A BinaryTree is a tree appropriate for 1D meshes.
The libMesh namespace provides an interface to certain functionality in the library.
static const Real TOLERANCE
TreeNode< N > root
The tree root.
virtual void print_nodes(std::ostream &my_out=libMesh::out) const override
Prints the nodes.
This class defines a node on a tree.
BuildType
enum defining how to build the tree.
virtual unsigned int n_active_bins() const override
This is the MeshBase class.
A Point defines a location in LIBMESH_DIM dimensional Real space.
This is the base class for trees, it allows pointer usage of trees.
const Elem * operator()(const Point &p, const std::set< subdomain_id_type > *allowed_subdomains=nullptr, Real relative_tol=TOLERANCE) const
virtual const Elem * find_element(const Point &p, const std::set< subdomain_id_type > *allowed_subdomains=nullptr, Real relative_tol=TOLERANCE) const override
This is the base class from which all geometric element types are derived.
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
Tree< 8 > OctTree
An OctTree is a tree appropriate for 3D meshes.
This class defines a tree that may be used for fast point location in space.
virtual void print_elements(std::ostream &my_out=libMesh::out) const override
Prints the nodes.
Tree< 4 > QuadTree
A QuadTree is a tree appropriate for 2D meshes.
Tree(const MeshBase &m, unsigned int target_bin_size, Trees::BuildType bt=Trees::NODES)
Constructor.