Commit b0e6a264 by Henrik Stolzmann

Furthermore removed the unused member variable row1_.
 ... ... @@ -12,6 +12,24 @@ namespace Dune { /* * RTPreBasisFactory provides a basis for the Raviart-Thomas function space. * RaviartThomasL2InterpolationFactory provides the linear functionals. * * Defaultbasisfactory::create first builds the function space and the linear functionals. * Then the constructor of BasisMatrix gets called. There the matrix * * * A_{i,j} := N_j(\phi_i) * * * with linear functionals $N_j$ and basisfunctions $\phi_i$ gets assembled. * Then the matrix gets inverted and is then used as a coefficent matrix for the standard monomial basis. * * For more details on the theory see the first chapter "Construction of Local Finite Element Spaces Using the Generic Reference Elements" * of the book "Advances in Dune" by Dedner, Flemisch and Klöfkorn published in 2012. */ template< unsigned int dim, class SF, class CF > struct RaviartThomasBasisFactory : public DefaultBasisFactory< RTPreBasisFactory, ... ...
 ... ... @@ -103,10 +103,16 @@ namespace Dune struct RTL2InterpolationBuilder { static const unsigned int dimension = dim; // for the dofs associated to the element typedef OrthonormalBasisFactory< dimension, Field > TestBasisFactory; typedef typename TestBasisFactory::Object TestBasis; // for the dofs associated to the faces typedef OrthonormalBasisFactory< dimension-1, Field > TestFaceBasisFactory; typedef typename TestFaceBasisFactory::Object TestFaceBasis; // the normals of the faces typedef FieldVector< Field, dimension > Normal; RTL2InterpolationBuilder () = default; ... ... @@ -127,11 +133,16 @@ namespace Dune std::size_t order () const { return order_; } // number of faces unsigned int faceSize () const { return faceSize_; } // basis associated to the element TestBasis *testBasis () const { return testBasis_; } // basis associated to face f TestFaceBasis *testFaceBasis ( unsigned int f ) const { assert( f < faceSize() ); return faceStructure_[ f ].basis_; } // normal of face f const Normal &normal ( unsigned int f ) const { assert( f < faceSize() ); return *(faceStructure_[ f ].normal_); } template< class Topology > ... ... @@ -147,6 +158,17 @@ namespace Dune faceStructure_.reserve( faceSize_ ); for( unsigned int face = 0; face < faceSize_; ++face ) { /* For simplices or cubes of arbitrary dimension you could just use * *  * GeometryType faceGeometry = Impl::getBase(geometry_); * TestFaceBasis *faceBasis = TestFaceBasisFactory::template create< faceGeometry >( order ); *  * * For i.e. Prisms and Pyramids in 3d this does not work because they contain squares and triangles as faces. * And depending on the dynamic face index a different face geometry is needed. * */ TestFaceBasis *faceBasis = Impl::IfTopology< CreateFaceBasis, dimension-1 >::apply( refElement.type( face, 1 ).id(), order ); faceStructure_.emplace_back( faceBasis, refElement.integrationOuterNormal( face ) ); } ... ... @@ -327,7 +349,15 @@ namespace Dune } private: /** /brief evaluate boundary functionals **/ /** \brief evaluate boundary functionals * * \param startRow row of matrix to start * \param mVal value of the testBasis at a quadrature point on a face * \param rtVal value of the RaviartThomasBasis at a quadrature point on a face * \param normal the normal of the face * \param weight quadrature weight * \param matrix result gets written into matrix starting with row: row */ template void fillBnd (unsigned int startRow, const MVal &mVal, ... ... @@ -350,6 +380,14 @@ namespace Dune assert( miter == mVal.end() ); } } /** \brief evaluate interior functionals * * \param startRow row of matrix to start * \param mVal value of the testBasis at a quadrature point in the interior of the ReferenceElement * \param rtVal value of the RaviartThomasBasis at a quadrature point in the interior of the ReferenceElement * \param weight quadrature weight * \param matrix result gets written into matrix starting with row: row */ template void fillInterior (unsigned int startRow, const MVal &mVal, ... ...