1 #ifndef DUNE_FEM_GRIDPART_FILTEREDGRIDPART_INTERSECTIONITERATOR_HH 2 #define DUNE_FEM_GRIDPART_FILTEREDGRIDPART_INTERSECTIONITERATOR_HH 8 #include <dune/grid/common/intersectioniterator.hh> 22 template<
class FilterType,
class Gr
idPartType,
class HostIteratorType >
29 typedef typename HostIteratorType::Intersection HostIntersection;
33 static const int dimension = HostIntersection::dimension;
39 typedef typename HostIntersection::ctype
ctype;
42 typedef typename HostIntersection::Entity
Entity;
48 typedef typename HostIntersection::Geometry
Geometry;
93 if ( filter().interiorIntersection( *hostIterator() ) )
95 nInfo_.boundary_ =
false;
96 nInfo_.boundaryId_ = 0;
97 nInfo_.neighbor_ =
true;
102 nInfo_.boundary_ = filter().intersectionBoundary( *hostIterator() );
103 nInfo_.boundaryId_ = filter().intersectionBoundaryId( *hostIterator() );
104 nInfo_.neighbor_ = filter().intersectionNeighbor( *hostIterator() );
110 nInfo_.boundary_ =
true;
111 nInfo_.boundaryId_ = filter().intersectionBoundaryId( *hostIterator() );
112 nInfo_.neighbor_ =
false;
121 const HostIteratorType & hostIterator )
122 : gridPart_( gridPart ),
123 hostIterator_( hostIterator ),
124 endIterator_( gridPart.hostGridPart().iend( en ) ),
133 : gridPart_( other.gridPart_ ),
134 hostIterator_( other.hostIterator_ ),
135 endIterator_( other.endIterator_ ),
136 nInfo_( other.nInfo_ )
142 gridPart_ = other.gridPart_;
143 hostIterator_ = other.hostIterator_;
144 nInfo_ = other.nInfo_;
161 return hostIterator_.operator==( other.hostIterator_ );
167 return !(*
this == other);
173 return nInfo_.boundary_;
179 return nInfo_.boundaryId_;
185 return nInfo_.neighbor_;
203 return hostIterator()->conforming();
209 return hostIterator()->geometryInInside();
215 return hostIterator()->geometryInOutside();
221 return hostIterator()->geometry();
227 return hostIterator()->type();
233 return hostIterator()->indexInInside();
239 return hostIterator()->indexInOutside();
243 GlobalCoordinate
outerNormal (
const LocalCoordinate & local )
const 245 return hostIterator()->outerNormal( local );
251 return hostIterator()->integrationOuterNormal( local );
257 return hostIterator()->unitOuterNormal( local );
263 return hostIterator()->centerUnitOuterNormal( );
276 const Intersection&
impl()
const 284 return *hostIterator();
288 const GridPartType & gridPart ()
const 295 return hostIterator_.operator ==( endIterator_ );
299 HostIteratorType & hostIterator ()
301 return hostIterator_;
305 const HostIteratorType & hostIterator ()
const 307 return hostIterator_;
310 const FilterType & filter ()
const 312 return gridPart().filter();
315 const GridPartType & gridPart_;
316 HostIteratorType hostIterator_, endIterator_;
325 #endif // #ifndef DUNE_FEM_GRIDPART_FILTEREDGRIDPART_INTERSECTIONITERATOR_HH NeighborInfo(const NeighborInfo &org)
Definition: filteredgridpart/intersectioniterator.hh:69
LocalGeometry geometryInInside() const
return inside entity
Definition: filteredgridpart/intersectioniterator.hh:207
const Intersection & operator*() const
dereference operator
Definition: filteredgridpart/intersectioniterator.hh:270
GlobalCoordinate outerNormal(const LocalCoordinate &local) const
return inside entity
Definition: filteredgridpart/intersectioniterator.hh:243
HostIntersection::EntityPointer EntityPointer
entity type
Definition: filteredgridpart/intersectioniterator.hh:45
Definition: filteredgridpart/intersectioniterator.hh:23
HostIntersection::Geometry Geometry
geometry type
Definition: filteredgridpart/intersectioniterator.hh:48
Entity inside() const
return inside entity
Definition: filteredgridpart/intersectioniterator.hh:189
bool operator!=(const FilteredGridPartIntersectionIterator &other) const
check for inequality
Definition: filteredgridpart/intersectioniterator.hh:165
static const int dimensionworld
world dimension
Definition: filteredgridpart/intersectioniterator.hh:35
GlobalCoordinate integrationOuterNormal(const LocalCoordinate &local) const
return inside entity
Definition: filteredgridpart/intersectioniterator.hh:249
const Intersection * operator->() const
de-pointer operator
Definition: filteredgridpart/intersectioniterator.hh:273
GlobalCoordinate unitOuterNormal(const LocalCoordinate &local) const
return inside entity
Definition: filteredgridpart/intersectioniterator.hh:255
int boundaryId() const
overloaded boundaryId method
Definition: filteredgridpart/intersectioniterator.hh:177
HostIntersection hostIntersection() const
Definition: filteredgridpart/intersectioniterator.hh:282
int indexInInside() const
return inside entity
Definition: filteredgridpart/intersectioniterator.hh:231
HostIntersection::GlobalCoordinate GlobalCoordinate
global coordinate type
Definition: filteredgridpart/intersectioniterator.hh:57
HostIntersection::LocalGeometry LocalGeometry
local geometry type
Definition: filteredgridpart/intersectioniterator.hh:51
int indexInOutside() const
return inside entity
Definition: filteredgridpart/intersectioniterator.hh:237
bool boundary() const
overloaded boundary method
Definition: filteredgridpart/intersectioniterator.hh:171
Dune::EntityPointer< Grid, Implementation >::Entity make_entity(const Dune::EntityPointer< Grid, Implementation > &entityPointer)
Definition: compatibility.hh:23
FilteredGridPartIntersectionIterator(const GridPartType &gridPart, const Entity &en, const HostIteratorType &hostIterator)
constructor
Definition: filteredgridpart/intersectioniterator.hh:119
int boundaryId_
Definition: filteredgridpart/intersectioniterator.hh:83
FilteredGridPartIntersectionIterator & operator++()
increment intersection iterator
Definition: filteredgridpart/intersectioniterator.hh:149
ThisType Intersection
type of Intersection
Definition: filteredgridpart/intersectioniterator.hh:267
Definition: coordinate.hh:4
HostIntersection::LocalCoordinate LocalCoordinate
local coordinate type
Definition: filteredgridpart/intersectioniterator.hh:54
static const int mydimension
Definition: filteredgridpart/intersectioniterator.hh:36
Definition: filteredgridpart/intersectioniterator.hh:60
bool operator==(const FilteredGridPartIntersectionIterator &other) const
check for equality
Definition: filteredgridpart/intersectioniterator.hh:159
bool boundary_
Definition: filteredgridpart/intersectioniterator.hh:84
const Intersection & impl() const
Definition: filteredgridpart/intersectioniterator.hh:276
static const int dimension
dimension
Definition: filteredgridpart/intersectioniterator.hh:33
bool neighbor() const
overloaded neighbor method
Definition: filteredgridpart/intersectioniterator.hh:183
Entity outside() const
return outside entity
Definition: filteredgridpart/intersectioniterator.hh:195
Geometry geometry() const
return inside entity
Definition: filteredgridpart/intersectioniterator.hh:219
HostIntersection::Entity Entity
entity type
Definition: filteredgridpart/intersectioniterator.hh:42
void writeNeighborInfo()
Definition: filteredgridpart/intersectioniterator.hh:89
GeometryType type() const
return inside entity
Definition: filteredgridpart/intersectioniterator.hh:225
FilteredGridPartIntersectionIterator(const ThisType &other)
copy constructor
Definition: filteredgridpart/intersectioniterator.hh:132
NeighborInfo()
Definition: filteredgridpart/intersectioniterator.hh:63
NeighborInfo & operator=(const NeighborInfo &org)
Definition: filteredgridpart/intersectioniterator.hh:75
LocalGeometry geometryInOutside() const
return inside entity
Definition: filteredgridpart/intersectioniterator.hh:213
GlobalCoordinate centerUnitOuterNormal() const
return inside entity
Definition: filteredgridpart/intersectioniterator.hh:261
HostIntersection::ctype ctype
single coordinate type
Definition: filteredgridpart/intersectioniterator.hh:39
bool conforming() const
Definition: filteredgridpart/intersectioniterator.hh:201
bool neighbor_
Definition: filteredgridpart/intersectioniterator.hh:85