20 #ifndef LIBMESH_POINT_LOCATOR_TREE_H 21 #define LIBMESH_POINT_LOCATOR_TREE_H 24 #include "libmesh/point_locator_base.h" 25 #include "libmesh/tree_base.h" 87 virtual void clear()
override final;
99 virtual void init()
override final;
109 const std::set<subdomain_id_type> * allowed_subdomains =
nullptr)
const override final;
116 std::set<const Elem *> & candidate_elements,
117 const std::set<subdomain_id_type> * allowed_subdomains =
nullptr)
const override final;
128 const std::set<subdomain_id_type> * allowed_subdomains,
129 bool use_close_to_point,
138 const std::set<subdomain_id_type> * allowed_subdomains,
200 #endif // LIBMESH_POINT_LOCATOR_TREE_H virtual void enable_out_of_mesh_mode() override final
Enables out-of-mesh mode.
~PointLocatorTree()
Destructor.
BuildType
enum defining how to build the tree.
virtual const Elem * operator()(const Point &p, const std::set< subdomain_id_type > *allowed_subdomains=nullptr) const override final
Locates the element in which the point with global coordinates p is located, optionally restricted to...
static constexpr Real TOLERANCE
virtual void clear() override final
Clears the locator.
virtual void init() override final
Initializes the locator, so that the operator() methods can be used.
std::shared_ptr< TreeBase > _tree
Pointer to our tree.
unsigned int get_target_bin_size() const
Get the target bin size.
This is the base class from which all geometric element types are derived.
The libMesh namespace provides an interface to certain functionality in the library.
const Elem * _element
Pointer to the last element that was found by the tree.
This is the MeshBase class.
PointLocatorTree(const MeshBase &mesh, const PointLocatorBase *master=nullptr)
Constructor.
This is the base class for point locators.
Trees::BuildType _build_type
How the underlying tree is built.
unsigned int _target_bin_size
Target bin size, which gets passed to the constructor of _tree.
bool _out_of_mesh_mode
true if out-of-mesh mode is enabled.
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
const Elem * perform_linear_search(const Point &p, const std::set< subdomain_id_type > *allowed_subdomains, bool use_close_to_point, Real close_to_point_tolerance=TOLERANCE) const
As a fallback option, it's helpful to be able to do a linear search over the entire mesh...
std::set< const Elem * > perform_fuzzy_linear_search(const Point &p, const std::set< subdomain_id_type > *allowed_subdomains, Real close_to_point_tolerance=TOLERANCE) const
A method to check if "fat" point p is in multiple elements.
void set_target_bin_size(unsigned int target)
Set the target bin size.
A Point defines a location in LIBMESH_DIM dimensional Real space.
virtual void disable_out_of_mesh_mode() override final
Disables out-of-mesh mode (default).