17 #include <deal.II/base/quadrature_lib.h> 18 #include <deal.II/fe/fe_q.h> 23 DEAL_II_NAMESPACE_OPEN
27 template <
int dim,
int spacedim>
35 std::vector<bool> (1, false))
38 ExcMessage (
"This element can only be used for polynomial degrees " 39 "greater than zero. If you want an element of polynomial " 40 "degree zero, then it cannot be continuous and you " 41 "will want to use FE_DGQ<dim>(0)."));
42 std::vector<Point<1> > support_points_1d(degree+1);
43 for (
unsigned int i=0; i<=
degree; ++i)
44 support_points_1d[i][0] = static_cast<double>(i)/
degree;
51 template <
int dim,
int spacedim>
59 std::vector<bool> (1, false))
64 ExcMessage (
"This element can only be used for polynomial degrees " 72 template <
int dim,
int spacedim>
80 std::ostringstream namebuf;
81 bool equidistant =
true;
82 std::vector<double> points(this->
degree+1);
86 for (
unsigned int j=0; j<=this->
degree; j++)
90 for (
unsigned int j=0; j<=this->
degree; j++)
91 if (std::fabs(points[j] - (
double)j/this->
degree) > 1e-15)
97 if (equidistant ==
true)
100 <<
">(" << this->
degree <<
")";
105 bool gauss_lobatto =
true;
106 for (
unsigned int j=0; j<=this->
degree; j++)
107 if (points[j] != points_gl.
point(j)(0))
109 gauss_lobatto =
false;
112 if (gauss_lobatto ==
true)
115 <<
">(QGaussLobatto(" << this->degree+1 <<
"))";
119 <<
">(QUnknownNodes(" << this->degree <<
"))";
121 return namebuf.str();
126 template <
int dim,
int spacedim>
137 DEAL_II_NAMESPACE_CLOSE
static std::vector< unsigned int > get_dpo_vector(const unsigned int degree)
FE_Q(const unsigned int p)
const std::vector< Point< dim > > & get_points() const
::ExceptionBase & ExcMessage(std::string arg1)
const unsigned int degree
const Point< dim > & point(const unsigned int i) const
virtual FiniteElement< dim, spacedim > * clone() const
std::vector< Point< dim > > unit_support_points
#define Assert(cond, exc)
std::string dim_string(const int dim, const int spacedim)
unsigned int size() const
virtual std::string get_name() const
void initialize(const std::vector< Point< 1 > > &support_points_1d)
const std::vector< unsigned int > & get_numbering_inverse() const
TensorProductPolynomials< dim > poly_space