Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unify code for Raviart-Thomas polynomial space #12728

Closed
kronbichler opened this issue Aug 31, 2021 · 1 comment · Fixed by #13866
Closed

Unify code for Raviart-Thomas polynomial space #12728

kronbichler opened this issue Aug 31, 2021 · 1 comment · Fixed by #13866

Comments

@kronbichler
Copy link
Member

Currently, we have the basic Raviart-Thomas polynomial space in

/**
* This class implements the <i>H<sup>div</sup></i>-conforming, vector-valued
* Raviart-Thomas polynomials as described in the book by Brezzi and Fortin.
*
* The Raviart-Thomas polynomials are constructed such that the divergence is
* in the tensor product polynomial space <i>Q<sub>k</sub></i>. Therefore, the
* polynomial order of each component must be one order higher in the
* corresponding direction, yielding the polynomial spaces
* <i>(Q<sub>k+1,k</sub>, Q<sub>k,k+1</sub>)</i> and <i>(Q<sub>k+1,k,k</sub>,
* Q<sub>k,k+1,k</sub>, Q<sub>k,k,k+1</sub>)</i> in 2D and 3D, resp.
*
* @ingroup Polynomials
*/
template <int dim>
class PolynomialsRaviartThomas : public TensorPolynomialsBase<dim>
{
and the nodal variant
// ---------------- polynomial class for FE_RaviartThomasNodal ---------------
namespace
{
template <int dim>
class PolynomialsRaviartThomasNodal : public TensorPolynomialsBase<dim>
{
public:
PolynomialsRaviartThomasNodal(const unsigned int degree);
introduced recently for #12454. The latter is the more appropriate space for higher degrees because it uses non-equidistant points for the Lagrange polynomials, and it enables a renumbering. I think we should be able to move the code of the latter to the actual polynomial class, base/polynomials_raviart_thomas.h, and create an entry point based on the right numbers for all places the basic polynomial is used. This would reduce code redundancy. The only catch is that higher degrees with the previous PolynomialsRaviartThomas would change the form (into the better), so we might need to look into some tests.

@kronbichler
Copy link
Member Author

Found while looking at #12726.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant