4 #ifndef DUNE_GRID_INTERSECTION_HH
5 #define DUNE_GRID_INTERSECTION_HH
162 template<
class Gr
idImp,
template<
class>
class IntersectionImp>
165 #if DUNE_GRID_EXPERIMENTAL_GRID_EXTENSIONS
170 friend class GridDefaultImplementation<
171 GridImp::
dimension, GridImp::dimensionworld,
172 typename GridImp::ctype,
173 typename GridImp::GridFamily> ;
186 enum {
dim=GridImp::dimension };
191 typedef typename GridImp::template Codim<0>::Entity
Entity;
197 typedef typename GridImp::template Codim<1>::Geometry
Geometry;
221 typedef typename GridImp::ctype
ctype;
246 #if ! DUNE_GRID_EXPERIMENTAL_GRID_EXTENSIONS
472 template<
class Gr
idImp,
template<
class>
class IntersectionImp>
475 enum { dim=GridImp::dimension };
476 enum { dimworld=GridImp::dimensionworld };
477 typedef typename GridImp::ctype ct;
485 FieldVector<ct, dimworld> n = asImp().unitOuterNormal(local);
486 n *= asImp().intersectionGlobal().integrationElement(local);
493 FieldVector<ct, dimworld> n = asImp().outerNormal(local);
503 const GenericReferenceElement<ct, dim-1> & refElement =
504 GenericReferenceElements<ct, dim-1>::general(type);
505 return asImp().unitOuterNormal(refElement.position(0,0));
513 IntersectionImp<GridImp>& asImp ()
514 {
return static_cast<IntersectionImp<GridImp>&
>(*this);}
515 const IntersectionImp<GridImp>& asImp ()
const
516 {
return static_cast<const IntersectionImp<GridImp>&
>(*this);}
521 #endif // DUNE_GRID_INTERSECTION_HH