#include <deal.II/base/scalar_polynomials_base.h>
+#include <deal.II/simplex/barycentric_polynomials.h>
+
DEAL_II_NAMESPACE_OPEN
/**
private:
/**
- * Scalar polynomial defined on a triangle.
+ * Scalar polynomials defined on a triangle.
*/
- const ScalarPolynomial<2> poly_tri;
+ const BarycentricPolynomials<2> poly_tri;
/**
- * Scalar polynomial defined on a line.
+ * Scalar polynomials defined on a line.
*/
- const ScalarPolynomial<1> poly_line;
+ const BarycentricPolynomials<1> poly_line;
};
#include <deal.II/base/qprojector.h>
#include <deal.II/base/tensor_product_polynomials.h>
-#include <deal.II/simplex/polynomials.h>
+#include <deal.II/simplex/barycentric_polynomials.h>
DEAL_II_NAMESPACE_OPEN
// linear polynomial to map the reference quadrature points correctly
// on faces
- const Simplex::ScalarPolynomial<1> poly(1);
+ const auto poly = Simplex::BarycentricPolynomials<1>::get_fe_p_basis(1);
// new (projected) quadrature points and weights
std::vector<Point<2>> points;
std::vector<Point<3>> points;
std::vector<double> weights;
- const Simplex::ScalarPolynomial<2> poly_tri(1);
- const TensorProductPolynomials<2> poly_quad(
+ const auto poly_tri = Simplex::BarycentricPolynomials<2>::get_fe_p_basis(1);
+ const TensorProductPolynomials<2> poly_quad(
Polynomials::generate_complete_Lagrange_basis(
{Point<1>(0.0), Point<1>(1.0)}));
const std::vector<unsigned int> & dpo_vector,
const typename FiniteElementData<dim>::Conformity conformity)
: dealii::FE_Poly<dim, spacedim>(
- Simplex::ScalarPolynomial<dim>(degree),
+ BarycentricPolynomials<dim>::get_fe_p_basis(degree),
FiniteElementData<dim>(dpo_vector,
dim == 2 ? ReferenceCell::Type::Tri :
ReferenceCell::Type::Tet,
// ---------------------------------------------------------------------
+#include <deal.II/simplex/barycentric_polynomials.h>
#include <deal.II/simplex/polynomials.h>
DEAL_II_NAMESPACE_OPEN
ScalarWedgePolynomial<dim>::ScalarWedgePolynomial(const unsigned int degree)
: ScalarPolynomialsBase<dim>(degree,
compute_n_polynomials_wedge(dim, degree))
- , poly_tri(degree)
- , poly_line(degree)
+ , poly_tri(BarycentricPolynomials<2>::get_fe_p_basis(degree))
+ , poly_line(BarycentricPolynomials<1>::get_fe_p_basis(degree))
{}
// ---------------------------------------------------------------------
-// Test Simplex::ScalarPolynomial on an the points of an arbitrary quadrature
-// rule.
+// Test Simplex::BarycentricPolynomials on an the points of an arbitrary
+// quadrature rule.
#include <deal.II/base/quadrature_lib.h>
void
test(const unsigned int degree)
{
- Simplex::ScalarPolynomial<dim> poly(degree);
- QSimplex<dim> quad(QGauss<dim>(degree + 1));
+ const auto poly =
+ Simplex::BarycentricPolynomials<dim>::get_fe_p_basis(degree);
+ QSimplex<dim> quad(QGauss<dim>(degree + 1));
std::vector<double> values(poly.n());
std::vector<Tensor<1, dim>> grads(poly.n());