1#ifndef DUNE_FEM_GRIDPART_FILTER_RADIALFILTER_HH
2#define DUNE_FEM_GRIDPART_FILTER_RADIALFILTER_HH
4#include <dune/common/fvector.hh>
17 template <
typename ct,
int dimw >
38 template<
class Entity >
41 constexpr int cc = Entity::codimension;
43 DUNE_THROW( InvalidStateException,
"RadialFilter::contains only available for codim 0 entities" );
44 ctype dist = (entity.geometry().center() - center_).two_norm();
45 return (dist > radius_);
49 template<
class Intersection >
52 return contains( intersection.outside() );
58 template <
class Intersection >
65 template <
class Intersection >
72 template <
class Intersection>
Definition: bindguard.hh:11
given center x and radius r, filter is characteristic function of clos B_r( x )
Definition: radialfilter.hh:19
static constexpr int dimensionworld
export dimension
Definition: radialfilter.hh:25
bool intersectionBoundary(const Intersection &) const
return what boundary id we have in case of boundary intersection
Definition: radialfilter.hh:59
RadialFilter(const GlobalCoordinateType ¢er=GlobalCoordinateType(0), ctype radius=0.25)
constructor
Definition: radialfilter.hh:31
int intersectionBoundaryId(const Intersection &) const
return what boundary id we have in case of boundary intersection
Definition: radialfilter.hh:66
Dune::FieldVector< ct, dimw > GlobalCoordinateType
coordinate type
Definition: radialfilter.hh:28
ct ctype
export template parameter
Definition: radialfilter.hh:22
bool contains(const Entity &entity) const
check whether entity center is inside of circle
Definition: radialfilter.hh:39
bool intersectionNeighbor(const Intersection &) const
if contains() is true then we have an interior entity
Definition: radialfilter.hh:73
bool interiorIntersection(const Intersection &intersection) const
default implementation returns contains from neighbor
Definition: radialfilter.hh:50