11#ifndef QUGAR_IMPL_UTILS_HPP
12#define QUGAR_IMPL_UTILS_HPP
Class for tolerance related computations.
Definition tolerance.hpp:33
Domain functions.
Definition domain_function.hpp:41
Class for storing an implicit domain reparameterization using Lagrange cells.
Definition impl_utils.hpp:102
Declaration of a few implicit functions template class ready to be consumed by Algoim.
Definition affine_transf.hpp:28
Vector< int, dim - 1 > get_edge_constant_dirs(int local_edge_id)
Gets the constant directions of the local edge.
int get_facet_side(int local_facet_id)
Gets the side of the facet. Either 0 or 1.
int get_facet_constant_dir(int local_facet_id)
Gets the constant direction of the local facet.
Vector< int, dim - 1 > get_edge_sides(int local_edge_id)
Gets the sides of the edge. Either 0 or 1 along each constant direction.
bool on_levelset(const ImplicitFunc< dim > &phi, const Point< dim > &point, Tolerance tol=Tolerance())
Checks if a point belongs to the levelset of an implicit function phi.
int get_local_facet_id(int const_dir, int side)
Get the local facet ID for a given const direction and side.
double real
Definition types.hpp:18
::algoim::uvector< T, dim > Vector
Class representing a vector.
Definition vector.hpp:31
Vector< T, dim > Point
Class representing a dim-dimensional Point.
Definition point.hpp:34
Definition and implementation of Point class.
Struct for storing and managing computed roots and intervals of an implicit function.
Definition impl_utils.hpp:109
int get_num_roots() const
Gets the number of roots in the container.
std::vector< real > roots
List of roots.
Definition impl_utils.hpp:111
std::vector< bool > active_intervals
Flags indicating if the intervals defined by two consecutive roots are active.
Definition impl_utils.hpp:117
void clear()
Clears the container to the initial state.
std::vector< std::pair< real, int > > roots_ids
Definition impl_utils.hpp:120
std::vector< int > func_ids
Restrictions to which root correspond to (there is a one to correspondence).
Definition impl_utils.hpp:115
void sort_roots()
Sorts (in increasing order) the roots in the container and the according restriction indices func_ids...
bool empty() const
Checks whether the container is empty.
Point< dim > point
Point at which roots are computed.
Definition impl_utils.hpp:113
void adjust_roots(const Tolerance &tol, real x0, real x1)
Adjust the container roots by sorting them and forcing near roots (up to a _olerance) to be coinciden...
void add_root(real root, int func_id)
Adds a new root.
RootsIntervals()
Default constructor.
Definition of tolerance related functionalities.