// ...then have some objects of which the meaning will become clear
// below...
- QTrapez<dim> vertex_quadrature;
+ QTrapezoid<dim> vertex_quadrature;
FEValues<dim> fe_values(dof_handler.get_fe(),
vertex_quadrature,
update_gradients | update_quadrature_points);
// In this context, it is instructive to point out what a more general way
// would be. For general finite elements, the way to go would be to take a
// quadrature formula with the quadrature points in the vertices of a
- // cell. The <code>QTrapez</code> formula for the trapezoidal rule does
+ // cell. The <code>QTrapezoid</code> formula for the trapezoidal rule does
// exactly this. With this quadrature formula, we would then initialize an
// <code>FEValues</code> object in each cell, and use the
// <code>FEValues::get_function_values</code> function to obtain the values
// discussion in the introduction.
else
{
- const QTrapez<dim> vertex_quadrature;
- FEValues<dim> fe_values(fe, vertex_quadrature, update_gradients);
+ const QTrapezoid<dim> vertex_quadrature;
+ FEValues<dim> fe_values(fe, vertex_quadrature, update_gradients);
std::vector<Tensor<1, dim>> field_gradients(vertex_quadrature.size());
// points for integration. To avoid this problem, we simply use a
// trapezoidal rule and iterate it <code>degree+2</code> times in each
// coordinate direction (again as explained in step-7):
- QTrapez<1> q_trapez;
+ QTrapezoid<1> q_trapez;
QIterated<dim> quadrature(q_trapez, degree + 2);
// With this, we can then let the library compute the errors and output
// on each cell. To this end, recall that if we had a single $Q_1$ field
// (rather than the vector-valued field of higher order) then the maximum
// would be attained at a vertex of the mesh. In other words, we should use
- // the QTrapez class that has quadrature points only at the vertices of
+ // the QTrapezoid class that has quadrature points only at the vertices of
// cells.
//
// For higher order shape functions, the situation is more complicated: the
// FiniteElement::get_unit_support_points() function, reduce the output to a
// unique set of points to avoid duplicate function evaluations, and create
// a Quadrature object using these points. Another option, chosen here, is
- // to use the QTrapez class and combine it with the QIterated class that
- // repeats the QTrapez formula on a number of sub-cells in each coordinate
+ // to use the QTrapezoid class and combine it with the QIterated class that
+ // repeats the QTrapezoid formula on a number of sub-cells in each coordinate
// direction. To cover all support points, we need to iterate it
// <code>stokes_degree+1</code> times since this is the polynomial degree of
// the Stokes element in use:
template <int dim>
double BoussinesqFlowProblem<dim>::get_maximal_velocity() const
{
- const QIterated<dim> quadrature_formula(QTrapez<1>(), stokes_degree + 1);
+ const QIterated<dim> quadrature_formula(QTrapezoid<1>(), stokes_degree + 1);
const unsigned int n_q_points = quadrature_formula.size();
FEValues<dim> fe_values(stokes_fe, quadrature_formula, update_values);
std::pair<double, double>
BoussinesqFlowProblem<dim>::get_extrapolated_temperature_range() const
{
- const QIterated<dim> quadrature_formula(QTrapez<1>(), temperature_degree);
+ const QIterated<dim> quadrature_formula(QTrapezoid<1>(),
+ temperature_degree);
const unsigned int n_q_points = quadrature_formula.size();
FEValues<dim> fe_values(temperature_fe, quadrature_formula, update_values);
template <int dim>
double BoussinesqFlowProblem<dim>::get_maximal_velocity() const
{
- const QIterated<dim> quadrature_formula(QTrapez<1>(),
+ const QIterated<dim> quadrature_formula(QTrapezoid<1>(),
parameters.stokes_velocity_degree);
const unsigned int n_q_points = quadrature_formula.size();
template <int dim>
double BoussinesqFlowProblem<dim>::get_cfl_number() const
{
- const QIterated<dim> quadrature_formula(QTrapez<1>(),
+ const QIterated<dim> quadrature_formula(QTrapezoid<1>(),
parameters.stokes_velocity_degree);
const unsigned int n_q_points = quadrature_formula.size();
std::pair<double, double>
BoussinesqFlowProblem<dim>::get_extrapolated_temperature_range() const
{
- const QIterated<dim> quadrature_formula(QTrapez<1>(),
+ const QIterated<dim> quadrature_formula(QTrapezoid<1>(),
parameters.temperature_degree);
const unsigned int n_q_points = quadrature_formula.size();
{
Assert(fe.degree == 1, ExcNotImplemented());
- const QTrapez<dim> quadrature_formula;
- FEValues<dim> fe_values(fe,
+ const QTrapezoid<dim> quadrature_formula;
+ FEValues<dim> fe_values(fe,
quadrature_formula,
update_values | update_JxW_values);
// error on each cell. Finally, we compute the global L infinity error
// from the L infinity errors on each cell with a call to
// VectorTools::compute_global_error.
- const QTrapez<1> q_trapez;
+ const QTrapezoid<1> q_trapez;
const QIterated<dim> q_iterated(q_trapez, fe->degree * 2 + 1);
VectorTools::integrate_difference(dof_handler,
solution,