168 * #ifndef MFMFE_DATA_H
169 * #define MFMFE_DATA_H
171 * #include <deal.II/base/function.h>
172 * #include <deal.II/base/tensor_function.h>
177 * <a name=
"data.h-Dataandexactsolution"></a>
178 * <h3>Data and exact solution.</h3>
182 * This file declares the classes
for the given
data, i.e.
183 * right-hand side, exact solution, permeability tensor and
184 * boundary conditions. For simplicity only 2
d cases are
185 * provided, but 3
d can be added straightforwardly.
196 *
class RightHandSide :
public Function<dim>
199 * RightHandSide () :
Function<dim>(1) {}
202 *
const unsigned int component = 0)
const override;
206 *
double RightHandSide<dim>::value (
const Point<dim> &p,
207 *
const unsigned int )
const
209 *
const double x = p[0];
210 *
const double y = p[1];
215 *
return -(x*(y*y*y*y)*6.0-(y*y)*
sin(x*y*2.0)*2.0+2.0)*(x*2.0+x*x+y*y+1.0)-
sin(x*y)*(
cos(x*y*2.0)+(x*x)*(y*y*y)*1.2E1
216 * -x*y*
sin(x*y*2.0)*2.0)*2.0-(x*2.0+2.0)*(x*2.0+(x*x)*(y*y*y*y)*3.0+y*
cos(x*y*2.0))+(x*x)*(
sin(x*y*2.0)
217 * -x*(y*y)*6.0)*
pow(x+1.0,2.0)*2.0-x*
cos(x*y)*(x*2.0+(x*x)*(y*y*y*y)*3.0+y*(
pow(
cos(x*y),2.0)*2.0-1.0))
218 * -x*y*
cos(x*y)*((x*x)*(y*y*y)*4.0+
pow(
cos(x*y),2.0)*2.0-1.0);
220 *
Assert(
false, ExcMessage(
"The RHS data for dim != 2 is not provided"));
227 *
class PressureBoundaryValues :
public Function<dim>
230 * PressureBoundaryValues () :
Function<dim>(1) {}
233 *
const unsigned int component = 0)
const override;
237 *
double PressureBoundaryValues<dim>::value (
const Point<dim> &p,
238 *
const unsigned int )
const
240 *
const double x = p[0];
241 *
const double y = p[1];
246 *
return (x*x*x)*(y*y*y*y)+
cos(x*y)*
sin(x*y)+x*x;
248 *
Assert(
false, ExcMessage(
"The BC data for dim != 2 is not provided"));
255 *
class ExactSolution :
public Function<dim>
258 * ExactSolution () :
Function<dim>(dim+1) {}
269 * ExactSolution<dim>::vector_value (
const Point<dim> &p,
273 * ExcDimensionMismatch (
values.size(), dim+1));
275 *
const double x = p[0];
276 *
const double y = p[1];
281 *
values(0) = -(x*2.0+(x*x)*(y*y*y*y)*3.0+y*
cos(x*y*2.0))*(x*2.0+x*x+y*y+1.0)-x*
sin(x*y)*(
cos(x*y*2.0)+(x*x)*(y*y*y)*4.0);
282 *
values(1) = -
sin(x*y)*(x*2.0+(x*x)*(y*y*y*y)*3.0+y*
cos(x*y*2.0))-x*(
cos(x*y*2.0)+(x*x)*(y*y*y)*4.0)*
pow(x+1.0,2.0);
286 *
Assert(
false, ExcMessage(
"The exact solution for dim != 2 is not provided"));
292 * ExactSolution<dim>::vector_gradient (
const Point<dim> &p,
295 *
const double x = p[0];
296 *
const double y = p[1];
301 * grads[0][0] = -(x*(y*y*y*y)*6.0-(y*y)*
sin(x*y*2.0)*2.0+2.0)*(x*2.0+x*x+y*y+1.0)-
sin(x*y)*(
cos(x*y*2.0)
302 * +(x*x)*(y*y*y)*1.2E1-x*y*
sin(x*y*2.0)*2.0)-(x*2.0+2.0)*(x*2.0+(x*x)*(y*y*y*y)*3.0
303 * +y*
cos(x*y*2.0))-x*y*
cos(x*y)*((x*x)*(y*y*y)*4.0+
pow(
cos(x*y),2.0)*2.0-1.0);
304 * grads[0][1] = -(
cos(x*y*2.0)+(x*x)*(y*y*y)*1.2E1-x*y*
sin(x*y*2.0)*2.0)*(x*2.0+x*x+y*y+1.0)
305 * -y*(x*2.0+(x*x)*(y*y*y*y)*3.0+y*
cos(x*y*2.0))*2.0-(x*x)*
cos(x*y)*((x*x)*(y*y*y)*4.0
306 * +
pow(
cos(x*y),2.0)*2.0-1.0)+(x*x)*
sin(x*y)*(
sin(x*y*2.0)-x*(y*y)*6.0)*2.0;
307 * grads[1][0] = -
sin(x*y)*(x*(y*y*y*y)*6.0-(y*y)*
sin(x*y*2.0)*2.0+2.0)-
pow(x+1.0,2.0)*(
cos(x*y*2.0)
308 * +(x*x)*(y*y*y)*1.2E1-x*y*
sin(x*y*2.0)*2.0)-x*(
cos(x*y*2.0)+(x*x)*(y*y*y)*4.0)*(x*2.0+2.0)
309 * -y*
cos(x*y)*(x*2.0+(x*x)*(y*y*y*y)*3.0+y*(
pow(
cos(x*y),2.0)*2.0-1.0));
310 * grads[1][1] = -
sin(x*y)*(
cos(x*y*2.0)+(x*x)*(y*y*y)*1.2E1-x*y*
sin(x*y*2.0)*2.0)+(x*x)*(
sin(x*y*2.0)
311 * -x*(y*y)*6.0)*
pow(x+1.0,2.0)*2.0-x*
cos(x*y)*(x*2.0+(x*x)*(y*y*y*y)*3.0
312 * +y*(
pow(
cos(x*y),2.0)*2.0-1.0));
316 *
Assert(
false, ExcMessage(
"The exact solution's gradient for dim != 2 is not provided"));
334 * KInverse<dim>::value_list (
const std::vector<
Point<dim> > &points,
338 * ExcDimensionMismatch (points.size(),
values.size()));
340 *
for (
unsigned int p=0; p<points.size(); ++p)
344 *
const double x = points[p][0];
345 *
const double y = points[p][1];
350 *
values[p][0][0] =
pow(x+1.0,2.0)/(x*4.0+(x*x)*(y*y)-
pow(
sin(x*y),2.0)+x*(y*y)*2.0+(x*x)*6.0+(x*x*x)*4.0+x*x*x*x+y*y+1.0);
351 *
values[p][0][1] = -
sin(x*y)/(x*4.0+(x*x)*(y*y)-
pow(
sin(x*y),2.0)+x*(y*y)*2.0+(x*x)*6.0+(x*x*x)*4.0+x*x*x*x+y*y+1.0);
352 *
values[p][1][0] = -
sin(x*y)/(x*4.0+(x*x)*(y*y)-
pow(
sin(x*y),2.0)+x*(y*y)*2.0+(x*x)*6.0+(x*x*x)*4.0+x*x*x*x+y*y+1.0);
353 *
values[p][1][1] = (x*2.0+x*x+y*y+1.0)/(x*4.0+(x*x)*(y*y)-
pow(
sin(x*y),2.0)+x*(y*y)*2.0+(x*x)*6.0+(x*x*x)*4.0+x*x*x*x+y*y+1.0);
356 *
Assert(
false, ExcMessage(
"The inverse of permeability tensor for dim != 2 is not provided"));
366<a name=
"ann-mfmfe.cc"></a>
367<h1>Annotated version of mfmfe.cc</h1>
390 * <a name=
"mfmfe.cc-Includefiles"></a>
391 * <h3>Include files</h3>
395 * As usual, the list of necessary header files. There is not
396 * much
new here, the files are included in order
397 * base-lac-grid-dofs-numerics followed by the
C++ headers.
400 * #include <deal.II/base/convergence_table.h>
401 * #include <deal.II/base/quadrature_lib.h>
402 * #include <deal.II/base/logstream.h>
403 * #include <deal.II/base/timer.h>
404 * #include <deal.II/base/utilities.h>
405 * #include <deal.II/base/work_stream.h>
407 * #include <deal.II/lac/full_matrix.h>
408 * #include <deal.II/lac/solver_cg.h>
409 * #include <deal.II/lac/block_sparse_matrix.h>
410 * #include <deal.II/lac/block_vector.h>
411 * #include <deal.II/lac/precondition.h>
413 * #include <deal.II/grid/grid_generator.h>
414 * #include <deal.II/grid/grid_tools.h>
415 * #include <deal.II/grid/grid_in.h>
416 * #include <deal.II/grid/tria.h>
417 * #include <deal.II/dofs/dof_renumbering.h>
418 * #include <deal.II/dofs/dof_tools.h>
419 * #include <deal.II/fe/fe_dgq.h>
420 * #include <deal.II/fe/fe_system.h>
421 * #include <deal.II/fe/fe_tools.h>
422 * #include <deal.II/numerics/vector_tools.h>
423 * #include <deal.II/numerics/matrix_tools.h>
424 * #include <deal.II/numerics/data_out.h>
427 * #include <unordered_map>
431 * This is a header needed
for the purposes of the
432 * multipoint flux mixed method, as it declares the
433 *
new enhanced Raviart-Thomas finite element.
436 * #include <deal.II/fe/fe_rt_bubbles.h>
440 * For the sake of readability, the classes representing
441 *
data, i.e. RHS, BCs, permeability tensor and the exact
442 * solution are placed in a file
data.h which is included
450 * As
always the program is in the
namespace of its own with
451 * the deal.II classes and
functions imported into it
461 * <a name=
"mfmfe.cc-Definitionofmultipointfluxassemblydatastructures"></a>
462 * <h3>Definition of multipoint flux assembly
data structures</h3>
466 * The main idea of the MFMFE method is to perform local elimination
467 * of the velocity variables in order to obtain the resulting
468 * pressure system. Since in deal.II assembly happens cell-wise,
469 * some extra work needs to be done in order to get the local
470 * mass matrices @f$A_i@f$ and the corresponding to them @f$B_i@f$.
473 *
namespace DataStructures
477 * This will be achieved by assembling cell-wise, but instead of placing
478 * the terms into a global system
matrix, they will populate node-associated
479 * full matrices. For
this, a
data structure with fast lookup is crucial, hence
486 *
size_t operator()(
const Point<dim> &p)
const
489 * h1 = std::hash<double>()(p[0]);
496 * h2 = std::hash<double>()(p[1]);
499 * h2 = std::hash<double>()(p[1]);
500 * h3 = std::hash<double>()(p[2]);
501 *
return (h1 ^ (h2 << 1)) ^ h3;
503 *
Assert(
false, ExcNotImplemented());
510 * Here, the actual hash-tables are defined. We use the
C++ STL <code>unordered_map</code>,
511 * with the hash function specified above. For convenience these are aliased as follows
515 *
using PointToMatrixMap = std::unordered_map<Point<dim>, std::map<std::pair<types::global_dof_index,types::global_dof_index>,
double>, hash_points<dim>>;
518 *
using PointToVectorMap = std::unordered_map<Point<dim>, std::map<types::global_dof_index, double>, hash_points<dim>>;
521 *
using PointToIndexMap = std::unordered_map<Point<dim>, std::set<types::global_dof_index>, hash_points<dim>>;
525 * Next, since
this particular program allows
for the use of
526 * multiple threads, the helper CopyData structures
527 * are defined. There are two kinds of these, one is used
528 *
for the copying cell-wise contributions to the corresponding
529 * node-associated
data structures...
533 *
struct NodeAssemblyCopyData
535 * PointToMatrixMap<dim> cell_mat;
536 * PointToVectorMap<dim> cell_vec;
537 * PointToIndexMap<dim> local_pres_indices;
538 * PointToIndexMap<dim> local_vel_indices;
539 * std::vector<types::global_dof_index> local_dof_indices;
544 * ... and the other one
for the actual process of
545 * local velocity elimination and assembling the global
550 *
struct NodeEliminationCopyData
563 * Similarly, two ScratchData classes are defined.
564 * One
for the assembly part, where we need
570 *
struct NodeAssemblyScratchData
577 * NodeAssemblyScratchData (
const NodeAssemblyScratchData &scratch_data);
581 * std::vector<unsigned int> n_faces_at_vertex;
583 *
const unsigned long num_cells;
585 * std::vector<Tensor<2,dim>> k_inverse_values;
586 * std::vector<double> rhs_values;
587 * std::vector<double> pres_bc_values;
589 * std::vector<Tensor<1,dim> > phi_u;
590 * std::vector<double> div_phi_u;
591 * std::vector<double> phi_p;
595 * NodeAssemblyScratchData<dim>::
605 * fe_face_values (fe,
609 * num_cells(tria.n_active_cells()),
610 * k_inverse_values(quad.size()),
611 * rhs_values(quad.size()),
612 * pres_bc_values(f_quad.size()),
613 * phi_u(fe.dofs_per_cell),
614 * div_phi_u(fe.dofs_per_cell),
615 * phi_p(fe.dofs_per_cell)
617 * n_faces_at_vertex.resize(tria.n_vertices(), 0);
620 *
for (; face != endf; ++face)
621 *
for (
unsigned int v=0; v<GeometryInfo<dim>::vertices_per_face; ++v)
622 * n_faces_at_vertex[face->vertex_index(v)] += 1;
626 * NodeAssemblyScratchData<dim>::
627 * NodeAssemblyScratchData (
const NodeAssemblyScratchData &scratch_data)
629 * fe_values (scratch_data.fe_values.get_fe(),
630 * scratch_data.fe_values.get_quadrature(),
633 * fe_face_values (scratch_data.fe_face_values.get_fe(),
634 * scratch_data.fe_face_values.get_quadrature(),
637 * n_faces_at_vertex(scratch_data.n_faces_at_vertex),
638 * num_cells(scratch_data.num_cells),
639 * k_inverse_values(scratch_data.k_inverse_values),
640 * rhs_values(scratch_data.rhs_values),
641 * pres_bc_values(scratch_data.pres_bc_values),
642 * phi_u(scratch_data.phi_u),
643 * div_phi_u(scratch_data.div_phi_u),
644 * phi_p(scratch_data.phi_p)
649 * ...and the other, simpler one,
for the velocity elimination and recovery
652 *
struct VertexEliminationScratchData
654 * VertexEliminationScratchData () =
default;
655 * VertexEliminationScratchData (
const VertexEliminationScratchData &scratch_data);
666 * VertexEliminationScratchData::
667 * VertexEliminationScratchData (
const VertexEliminationScratchData &scratch_data)
669 * velocity_matrix(scratch_data.velocity_matrix),
670 * pressure_rhs(scratch_data.pressure_rhs),
671 * local_pressure_solution(scratch_data.local_pressure_solution),
672 * tmp_rhs1(scratch_data.tmp_rhs1),
673 * tmp_rhs2(scratch_data.tmp_rhs2),
674 * tmp_rhs3(scratch_data.tmp_rhs3)
683 * <a name=
"mfmfe.cc-ThecodeMultipointMixedDarcyProblemcodeclasstemplate"></a>
684 * <h3>The <code>MultipointMixedDarcyProblem</code>
class template</h3>
688 * The main
class, besides the constructor and destructor, has only one
public member
689 * <code>
run()</code>, similarly to the tutorial programs. The
private members can
690 * be grouped into the ones that are used
for the cell-wise assembly, vertex elimination,
691 * pressure solve, vertex velocity recovery and postprocessing. Apart from the
692 * MFMFE-specific
data structures, the rest of the members should look familiar.
696 *
class MultipointMixedDarcyProblem
699 * MultipointMixedDarcyProblem (
const unsigned int degree);
700 * ~MultipointMixedDarcyProblem ();
701 *
void run (
const unsigned int refine);
704 * DataStructures::NodeAssemblyScratchData<dim> &scratch_data,
705 * DataStructures::NodeAssemblyCopyData<dim> ©_data);
706 *
void copy_cell_to_node(
const DataStructures::NodeAssemblyCopyData<dim> ©_data);
707 *
void node_assembly();
708 *
void make_cell_centered_sp ();
709 *
void nodal_elimination(
const typename DataStructures::PointToMatrixMap<dim>::iterator &n_it,
710 * DataStructures::VertexEliminationScratchData &scratch_data,
711 * DataStructures::NodeEliminationCopyData<dim> ©_data);
712 *
void copy_node_to_system(
const DataStructures::NodeEliminationCopyData<dim> ©_data);
713 *
void pressure_assembly ();
714 *
void solve_pressure ();
715 *
void velocity_assembly (
const typename DataStructures::PointToMatrixMap<dim>::iterator &n_it,
716 * DataStructures::VertexEliminationScratchData &scratch_data,
717 * DataStructures::NodeEliminationCopyData<dim> ©_data);
718 *
void copy_node_velocity_to_global(
const DataStructures::NodeEliminationCopyData<dim> ©_data);
719 *
void velocity_recovery ();
720 *
void reset_data_structures ();
721 *
void compute_errors (
const unsigned int cycle);
722 *
void output_results (
const unsigned int cycle,
const unsigned int refine);
724 *
const unsigned int degree;
734 * std::unordered_map<Point<dim>,
FullMatrix<double>, DataStructures::hash_points<dim>> pressure_matrix;
735 * std::unordered_map<Point<dim>,
FullMatrix<double>, DataStructures::hash_points<dim>> A_inverse;
736 * std::unordered_map<Point<dim>,
Vector<double>, DataStructures::hash_points<dim>> velocity_rhs;
738 * DataStructures::PointToMatrixMap<dim> node_matrix;
739 * DataStructures::PointToVectorMap<dim> node_rhs;
741 * DataStructures::PointToIndexMap<dim> pressure_indices;
742 * DataStructures::PointToIndexMap<dim> velocity_indices;
744 *
unsigned long n_v, n_p;
756 * <a name=
"mfmfe.cc-Constructoranddestructorcodereset_data_structurescode"></a>
757 * <h4>Constructor and destructor, <code>reset_data_structures</code></h4>
761 * In the constructor of
this class, we store the
value that was
762 * passed in concerning the degree of the finite elements we shall use (a
764 * and then construct the vector valued element belonging to the space @f$V_h^k@f$ described
765 * in the introduction. The constructor also takes care of initializing the
766 * computing timer, as it is of interest
for us how well our method performs.
770 * MultipointMixedDarcyProblem<dim>::MultipointMixedDarcyProblem (
const unsigned int degree)
783 * The destructor clears the <code>dof_handler</code> and
784 * all of the
data structures we used
for the method.
788 * MultipointMixedDarcyProblem<dim>::~MultipointMixedDarcyProblem()
790 * reset_data_structures ();
791 * dof_handler.clear();
797 * This method clears all the
data that was used after one refinement
802 *
void MultipointMixedDarcyProblem<dim>::reset_data_structures ()
804 * pressure_indices.clear();
805 * velocity_indices.clear();
806 * velocity_rhs.clear();
808 * pressure_matrix.clear();
809 * node_matrix.clear();
817 * <a name=
"mfmfe.cc-Cellwiseassemblyandcreationofthelocalnodalbaseddatastructures"></a>
818 * <h4>Cell-wise assembly and creation of the local, nodal-based
data structures</h4>
822 * First, the function that copies local cell contributions to the corresponding nodal
823 * matrices and vectors is defined. It places the
values obtained from local cell integration
824 * into the correct place in a
matrix/vector corresponding to a specific node.
828 *
void MultipointMixedDarcyProblem<dim>::copy_cell_to_node(
const DataStructures::NodeAssemblyCopyData<dim> ©_data)
830 *
for (
auto m : copy_data.cell_mat)
835 *
for (
auto p : copy_data.cell_vec.at(m.
first))
838 *
for (
auto p : copy_data.local_pres_indices.at(m.
first))
841 *
for (
auto p : copy_data.local_vel_indices.at(m.
first))
850 * Second, the function that does the cell assembly is defined. While it is
851 * similar to the tutorial programs in a way it uses scrath and
copy data
852 * structures, the need to localize the DOFs leads to several differences.
856 *
void MultipointMixedDarcyProblem<dim>::
858 * DataStructures::NodeAssemblyScratchData<dim> &scratch_data,
859 * DataStructures::NodeAssemblyCopyData<dim> ©_data)
861 * copy_data.cell_mat.clear();
862 * copy_data.cell_vec.clear();
863 * copy_data.local_vel_indices.clear();
864 * copy_data.local_pres_indices.clear();
866 *
const unsigned int dofs_per_cell = fe.dofs_per_cell;
867 *
const unsigned int n_q_points = scratch_data.fe_values.get_quadrature().size();
868 *
const unsigned int n_face_q_points = scratch_data.fe_face_values.get_quadrature().size();
870 * copy_data.local_dof_indices.resize(dofs_per_cell);
871 * cell->get_dof_indices (copy_data.local_dof_indices);
873 * scratch_data.fe_values.reinit (cell);
875 *
const KInverse<dim> k_inverse;
876 *
const RightHandSide<dim> rhs;
877 *
const PressureBoundaryValues<dim> pressure_bc;
879 * k_inverse.value_list (scratch_data.fe_values.get_quadrature_points(), scratch_data.k_inverse_values);
880 * rhs.value_list(scratch_data.fe_values.get_quadrature_points(), scratch_data.rhs_values);
886 * std::unordered_map<unsigned int, std::unordered_map<unsigned int, double>> div_map;
890 * One, we need to be able to
assemble the communication between velocity and
891 * pressure variables and put it on the right place in our
final, local version
892 * of the B
matrix. This is a little messy, as such communication is not in fact
893 * local, so we
do it in two steps. First, we compute all relevant LHS and RHS
896 *
for (
unsigned int q=0; q<n_q_points; ++q)
898 *
const Point<dim> p = scratch_data.fe_values.quadrature_point(q);
900 *
for (
unsigned int k=0; k<dofs_per_cell; ++k)
902 * scratch_data.phi_u[k] = scratch_data.fe_values[velocity].value(k, q);
903 * scratch_data.div_phi_u[k] = scratch_data.fe_values[velocity].divergence (k, q);
904 * scratch_data.phi_p[k] = scratch_data.fe_values[pressure].value (k, q);
907 *
for (
unsigned int i=0; i<dofs_per_cell; ++i)
909 *
for (
unsigned int j=n_vel; j<dofs_per_cell; ++j)
911 *
double div_term = (- scratch_data.div_phi_u[i] * scratch_data.phi_p[j]
912 * - scratch_data.phi_p[i] * scratch_data.div_phi_u[j]) * scratch_data.fe_values.JxW(q);
915 * div_map[i][j] += div_term;
918 *
double source_term = -scratch_data.phi_p[i] * scratch_data.rhs_values[q] * scratch_data.fe_values.JxW(q);
920 *
if (
std::abs(scratch_data.phi_p[i]) > 1.e-12 ||
std::abs(source_term) > 1.e-12)
921 * copy_data.cell_vec[p][copy_data.local_dof_indices[i]] += source_term;
927 * Then, by making another pass, we compute the mass
matrix terms and incorporate the
928 * divergence form and RHS accordingly. This
second pass, allows us to know where
929 * the total contribution will be put in the nodal
data structures, as with
this
930 * choice of quadrature rule and finite element only the basis
functions corresponding
931 * to the same quadrature points yield non-zero contribution.
934 *
for (
unsigned int q=0; q<n_q_points; ++q)
936 * std::set<types::global_dof_index> vel_indices;
937 *
const Point<dim> p = scratch_data.fe_values.quadrature_point(q);
939 *
for (
unsigned int k=0; k<dofs_per_cell; ++k)
941 * scratch_data.phi_u[k] = scratch_data.fe_values[velocity].value(k, q);
942 * scratch_data.div_phi_u[k] = scratch_data.fe_values[velocity].divergence (k, q);
943 * scratch_data.phi_p[k] = scratch_data.fe_values[pressure].value (k, q);
946 *
for (
unsigned int i=0; i<dofs_per_cell; ++i)
947 *
for (
unsigned int j=i; j<dofs_per_cell; ++j)
949 *
double mass_term = scratch_data.phi_u[i]
950 * * scratch_data.k_inverse_values[q]
951 * * scratch_data.phi_u[j]
952 * * scratch_data.fe_values.JxW(q);
956 * copy_data.cell_mat[p][std::make_pair(copy_data.local_dof_indices[i], copy_data.local_dof_indices[j])] +=
958 * vel_indices.insert(i);
959 * copy_data.local_vel_indices[p].insert(copy_data.local_dof_indices[j]);
963 *
for (
auto i : vel_indices)
964 * for (auto el : div_map[i])
967 * copy_data.cell_mat[p][
std::make_pair(copy_data.local_dof_indices[i],
968 * copy_data.local_dof_indices[el.
first])] += el.
second;
969 * copy_data.local_pres_indices[p].insert(copy_data.local_dof_indices[el.first]);
975 * The pressure boundary conditions are computed as in @ref step_20
"step-20",
978 * std::map<types::global_dof_index,double> pres_bc;
979 *
for (
unsigned int face_no=0;
980 * face_no<GeometryInfo<dim>::faces_per_cell;
982 *
if (cell->at_boundary(face_no))
984 * scratch_data.fe_face_values.reinit (cell, face_no);
985 * pressure_bc.value_list(scratch_data.fe_face_values.get_quadrature_points(), scratch_data.pres_bc_values);
987 *
for (
unsigned int q=0; q<n_face_q_points; ++q)
988 *
for (
unsigned int i = 0; i < dofs_per_cell; ++i)
990 *
double tmp = -(scratch_data.fe_face_values[velocity].value(i, q) *
991 * scratch_data.fe_face_values.normal_vector(q) *
992 * scratch_data.pres_bc_values[q] *
993 * scratch_data.fe_face_values.JxW(q));
996 * pres_bc[copy_data.local_dof_indices[i]] += tmp;
1002 * ...but we distribute them to the corresponding nodal
data structures
1005 *
for (
auto m : copy_data.cell_vec)
1006 * for (unsigned
int i=0; i<dofs_per_cell; ++i)
1007 *
if (
std::abs(pres_bc[copy_data.local_dof_indices[i]]) > 1.e-12)
1008 * copy_data.cell_vec[m.first][copy_data.local_dof_indices[i]] += pres_bc[copy_data.local_dof_indices[i]];
1014 * Finally, <code>node_assembly()</code> takes care of all the
1015 * local computations via
WorkStream mechanism. Notice that the choice
1016 * of the quadrature rule here is dictated by the formulation of the
1017 * method. It has to be <code>degree+1</code> points Gauss-Lobatto
1018 *
for the
volume integrals and <code>degree</code>
for the face ones,
1019 * as mentioned in the introduction.
1022 *
template <
int dim>
1023 *
void MultipointMixedDarcyProblem<dim>::node_assembly()
1027 * dof_handler.distribute_dofs(fe);
1029 *
const std::vector<types::global_dof_index> dofs_per_component
1033 *
QGauss<dim-1> face_quad(degree);
1035 * n_v = dofs_per_component[0];
1036 * n_p = dofs_per_component[dim];
1038 * pres_rhs.reinit(n_p);
1041 * dof_handler.end(),
1043 * &MultipointMixedDarcyProblem::assemble_system_cell,
1044 * &MultipointMixedDarcyProblem::copy_cell_to_node,
1045 * DataStructures::NodeAssemblyScratchData<dim>(fe,
triangulation,quad,face_quad),
1046 * DataStructures::NodeAssemblyCopyData<dim>());
1052 * <a name=
"mfmfe.cc-Makingthesparsitypattern"></a>
1053 * <h4>Making the sparsity pattern</h4>
1057 * Having computed all the local contributions, we actually have
1058 * all the information needed to make a cell-centered sparsity
1060 * leads to a slower solution.
1063 *
template <
int dim>
1064 *
void MultipointMixedDarcyProblem<dim>::make_cell_centered_sp()
1069 * std::set<types::global_dof_index>::iterator pi_it, pj_it;
1070 *
unsigned int i, j;
1071 *
for (
auto el : node_matrix)
1072 * for (pi_it = pressure_indices[el.
first].
begin(), i = 0;
1073 * pi_it != pressure_indices[el.first].end();
1075 *
for (pj_it = pi_it, j = 0;
1076 * pj_it != pressure_indices[el.first].end();
1078 * dsp.add(*pi_it - n_v, *pj_it - n_v);
1082 * cell_centered_sp.copy_from(dsp);
1083 * pres_system_matrix.reinit (cell_centered_sp);
1090 * <a name=
"mfmfe.cc-Thelocaleliminationprocedure"></a>
1091 * <h4>The local elimination procedure</h4>
1095 * This function
finally performs the local elimination procedure.
1096 * Mathematically, it follows the same idea as in computing the
1097 * Schur complement (as mentioned in the introduction) but we
do
1098 * so locally. Namely, local velocity DOFs are expressed in terms
1099 * of corresponding pressure
values, and then used
for the local
1103 *
template <
int dim>
1104 *
void MultipointMixedDarcyProblem<dim>::
1105 * nodal_elimination(
const typename DataStructures::PointToMatrixMap<dim>::iterator &n_it,
1106 * DataStructures::VertexEliminationScratchData &scratch_data,
1107 * DataStructures::NodeEliminationCopyData<dim> ©_data)
1109 *
unsigned int n_edges = velocity_indices.at((*n_it).first).size();
1110 *
unsigned int n_cells = pressure_indices.at((*n_it).first).size();
1112 * scratch_data.velocity_matrix.reinit(n_edges,n_edges);
1113 * copy_data.pressure_matrix.reinit(n_edges,n_cells);
1115 * copy_data.velocity_rhs.reinit(n_edges);
1116 * scratch_data.pressure_rhs.reinit(n_cells);
1119 * std::set<types::global_dof_index>::iterator vi_it, vj_it, p_it;
1121 *
for (vi_it = velocity_indices.at((*n_it).first).begin(), i = 0;
1122 * vi_it != velocity_indices.at((*n_it).first).end();
1126 *
for (vj_it = velocity_indices.at((*n_it).first).begin(), j = 0;
1127 * vj_it != velocity_indices.at((*n_it).first).end();
1130 * scratch_data.velocity_matrix.add(i, j, node_matrix[(*n_it).first][std::make_pair(*vi_it, *vj_it)]);
1132 * scratch_data.velocity_matrix.add(j, i, node_matrix[(*n_it).first][std::make_pair(*vi_it, *vj_it)]);
1135 *
for (p_it = pressure_indices.at((*n_it).first).begin(), j = 0;
1136 * p_it != pressure_indices.at((*n_it).first).end();
1138 * copy_data.pressure_matrix.add(i, j, node_matrix[(*n_it).first][std::make_pair(*vi_it, *p_it)]);
1140 * copy_data.velocity_rhs(i) += node_rhs.at((*n_it).first)[*vi_it];
1143 *
for (p_it = pressure_indices.at((*n_it).first).begin(), i = 0;
1144 * p_it != pressure_indices.at((*n_it).first).end();
1146 * scratch_data.pressure_rhs(i) += node_rhs.at((*n_it).first)[*p_it];
1149 * copy_data.Ainverse.reinit(n_edges,n_edges);
1151 * scratch_data.tmp_rhs1.reinit(n_edges);
1152 * scratch_data.tmp_rhs2.reinit(n_edges);
1153 * scratch_data.tmp_rhs3.reinit(n_cells);
1155 * copy_data.Ainverse.invert(scratch_data.velocity_matrix);
1156 * copy_data.node_pres_matrix.reinit(n_cells, n_cells);
1157 * copy_data.node_pres_rhs = scratch_data.pressure_rhs;
1159 * copy_data.node_pres_matrix = 0;
1160 * copy_data.node_pres_matrix.triple_product(copy_data.Ainverse,
1161 * copy_data.pressure_matrix,
1162 * copy_data.pressure_matrix,
true,
false);
1164 * copy_data.Ainverse.vmult(scratch_data.tmp_rhs1, copy_data.velocity_rhs,
false);
1165 * copy_data.pressure_matrix.Tvmult(scratch_data.tmp_rhs3, scratch_data.tmp_rhs1,
false);
1166 * copy_data.node_pres_rhs *= -1.0;
1167 * copy_data.node_pres_rhs += scratch_data.tmp_rhs3;
1169 * copy_data.p = (*n_it).first;
1175 * Each node
's pressure system is then distributed to a global pressure
1176 * system, using the indices we computed in the previous stages.
1179 * template <int dim>
1180 * void MultipointMixedDarcyProblem<dim>::
1181 * copy_node_to_system(const DataStructures::NodeEliminationCopyData<dim> ©_data)
1183 * A_inverse[copy_data.p] = copy_data.Ainverse;
1184 * pressure_matrix[copy_data.p] = copy_data.pressure_matrix;
1185 * velocity_rhs[copy_data.p] = copy_data.velocity_rhs;
1188 * std::set<types::global_dof_index>::iterator pi_it, pj_it;
1190 * for (pi_it = pressure_indices[copy_data.p].begin(), i = 0;
1191 * pi_it != pressure_indices[copy_data.p].end();
1195 * for (pj_it = pressure_indices[copy_data.p].begin(), j = 0;
1196 * pj_it != pressure_indices[copy_data.p].end();
1198 * pres_system_matrix.add(*pi_it - n_v, *pj_it - n_v, copy_data.node_pres_matrix(i, j));
1200 * pres_rhs(*pi_it - n_v) += copy_data.node_pres_rhs(i);
1208 * The @ref WorkStream mechanism is again used for the assembly
1209 * of the global system for the pressure variable, where the
1210 * previous functions are used to perform local computations.
1213 * template <int dim>
1214 * void MultipointMixedDarcyProblem<dim>::pressure_assembly()
1216 * TimerOutput::Scope t(computing_timer, "Pressure matrix assembly");
1218 * QGaussLobatto<dim> quad(degree+1);
1219 * QGauss<dim-1> face_quad(degree);
1221 * pres_rhs.reinit(n_p);
1223 * WorkStream::run(node_matrix.begin(),
1224 * node_matrix.end(),
1226 * &MultipointMixedDarcyProblem::nodal_elimination,
1227 * &MultipointMixedDarcyProblem::copy_node_to_system,
1228 * DataStructures::VertexEliminationScratchData(),
1229 * DataStructures::NodeEliminationCopyData<dim>());
1237 * <a name="mfmfe.cc-Velocitysolutionrecovery"></a>
1238 * <h4>Velocity solution recovery</h4>
1242 * After solving for the pressure variable, we want to follow
1243 * the above procedure backwards, in order to obtain the
1244 * velocity solution (again, this is similar in nature to the
1245 * Schur complement approach, see @ref step_20 "step-20", but here it is done
1246 * locally at each node). We have almost everything computed and
1247 * stored already, including inverses of local mass matrices,
1248 * so the following is a relatively straightforward implementation.
1251 * template <int dim>
1252 * void MultipointMixedDarcyProblem<dim>::
1253 * velocity_assembly (const typename DataStructures::PointToMatrixMap<dim>::iterator &n_it,
1254 * DataStructures::VertexEliminationScratchData &scratch_data,
1255 * DataStructures::NodeEliminationCopyData<dim> ©_data)
1257 * unsigned int n_edges = velocity_indices.at((*n_it).first).size();
1258 * unsigned int n_cells = pressure_indices.at((*n_it).first).size();
1260 * scratch_data.tmp_rhs1.reinit(n_edges);
1261 * scratch_data.tmp_rhs2.reinit(n_edges);
1262 * scratch_data.tmp_rhs3.reinit(n_cells);
1263 * scratch_data.local_pressure_solution.reinit(n_cells);
1265 * copy_data.vertex_vel_solution.reinit(n_edges);
1267 * std::set<types::global_dof_index>::iterator p_it;
1270 * for (p_it = pressure_indices[(*n_it).first].begin(), i = 0;
1271 * p_it != pressure_indices[(*n_it).first].end();
1273 * scratch_data.local_pressure_solution(i) = pres_solution(*p_it - n_v);
1275 * pressure_matrix[(*n_it).first].vmult(scratch_data.tmp_rhs2, scratch_data.local_pressure_solution, false);
1276 * scratch_data.tmp_rhs2 *= -1.0;
1277 * scratch_data.tmp_rhs2+=velocity_rhs[(*n_it).first];
1278 * A_inverse[(*n_it).first].vmult(copy_data.vertex_vel_solution, scratch_data.tmp_rhs2, false);
1280 * copy_data.p = (*n_it).first;
1286 * Copy nodal velocities to a global solution vector by using
1287 * local computations and indices from early stages.
1290 * template <int dim>
1291 * void MultipointMixedDarcyProblem<dim>::
1292 * copy_node_velocity_to_global(const DataStructures::NodeEliminationCopyData<dim> ©_data)
1294 * std::set<types::global_dof_index>::iterator vi_it;
1297 * for (vi_it = velocity_indices[copy_data.p].begin(), i = 0;
1298 * vi_it != velocity_indices[copy_data.p].end();
1300 * vel_solution(*vi_it) += copy_data.vertex_vel_solution(i);
1306 * Use @ref WorkStream to run everything concurrently.
1309 * template <int dim>
1310 * void MultipointMixedDarcyProblem<dim>::velocity_recovery()
1312 * TimerOutput::Scope t(computing_timer, "Velocity solution recovery");
1314 * QGaussLobatto<dim> quad(degree+1);
1315 * QGauss<dim-1> face_quad(degree);
1317 * vel_solution.reinit(n_v);
1319 * WorkStream::run(node_matrix.begin(),
1320 * node_matrix.end(),
1322 * &MultipointMixedDarcyProblem::velocity_assembly,
1323 * &MultipointMixedDarcyProblem::copy_node_velocity_to_global,
1324 * DataStructures::VertexEliminationScratchData(),
1325 * DataStructures::NodeEliminationCopyData<dim>());
1327 * solution.reinit(2);
1328 * solution.block(0) = vel_solution;
1329 * solution.block(1) = pres_solution;
1330 * solution.collect_sizes();
1338 * <a name="mfmfe.cc-Pressuresystemsolver"></a>
1339 * <h4>Pressure system solver</h4>
1343 * The solver part is trivial. We use the CG solver with no
1344 * preconditioner for simplicity.
1347 * template <int dim>
1348 * void MultipointMixedDarcyProblem<dim>::solve_pressure()
1350 * TimerOutput::Scope t(computing_timer, "Pressure CG solve");
1352 * pres_solution.reinit(n_p);
1354 * SolverControl solver_control (static_cast<int>(2.0*n_p), 1e-10);
1355 * SolverCG<> solver (solver_control);
1357 * PreconditionIdentity identity;
1358 * solver.solve(pres_system_matrix, pres_solution, pres_rhs, identity);
1366 * <a name="mfmfe.cc-Postprocessing"></a>
1367 * <h3>Postprocessing</h3>
1371 * We have two postprocessing steps here, first one computes the
1372 * errors in order to populate the convergence tables. The other
1373 * one takes care of the output of the solutions in <code>.vtk</code>
1379 * <a name="mfmfe.cc-Computeerrors"></a>
1380 * <h4>Compute errors</h4>
1384 * The implementation of this function is almost identical to @ref step_20 "step-20".
1385 * We use @ref ComponentSelectFunction as masks to use the right
1386 * solution component (velocity or pressure) and @ref integrate_difference
1387 * to compute the errors. Since we also want to compute Hdiv seminorm of the
1388 * velocity error, one must provide gradients in the <code>ExactSolution</code>
1389 * class implementation to avoid exceptions. The only noteworthy thing here
1390 * is that we again use lower order quadrature rule instead of projecting the
1391 * solution to an appropriate space in order to show superconvergence, which is
1392 * mathematically justified.
1395 * template <int dim>
1396 * void MultipointMixedDarcyProblem<dim>::compute_errors(const unsigned cycle)
1398 * TimerOutput::Scope t(computing_timer, "Compute errors");
1400 * const ComponentSelectFunction<dim> pressure_mask(dim, dim+1);
1401 * const ComponentSelectFunction<dim> velocity_mask(std::make_pair(0, dim), dim+1);
1403 * ExactSolution<dim> exact_solution;
1405 * Vector<double> cellwise_errors (triangulation.n_active_cells());
1407 * QTrapezoid<1> q_trapez;
1408 * QIterated<dim> quadrature(q_trapez,degree+2);
1409 * QGauss<dim> quadrature_super(degree);
1411 * VectorTools::integrate_difference (dof_handler, solution, exact_solution,
1412 * cellwise_errors, quadrature,
1413 * VectorTools::L2_norm,
1415 * const double p_l2_error = cellwise_errors.l2_norm();
1417 * VectorTools::integrate_difference (dof_handler, solution, exact_solution,
1418 * cellwise_errors, quadrature_super,
1419 * VectorTools::L2_norm,
1421 * const double p_l2_mid_error = cellwise_errors.l2_norm();
1423 * VectorTools::integrate_difference (dof_handler, solution, exact_solution,
1424 * cellwise_errors, quadrature,
1425 * VectorTools::L2_norm,
1427 * const double u_l2_error = cellwise_errors.l2_norm();
1429 * VectorTools::integrate_difference (dof_handler, solution, exact_solution,
1430 * cellwise_errors, quadrature,
1431 * VectorTools::Hdiv_seminorm,
1433 * const double u_hd_error = cellwise_errors.l2_norm();
1435 * const unsigned int n_active_cells=triangulation.n_active_cells();
1436 * const unsigned int n_dofs=dof_handler.n_dofs();
1438 * convergence_table.add_value("cycle", cycle);
1439 * convergence_table.add_value("cells", n_active_cells);
1440 * convergence_table.add_value("dofs", n_dofs);
1441 * convergence_table.add_value("Velocity,L2", u_l2_error);
1442 * convergence_table.add_value("Velocity,Hdiv", u_hd_error);
1443 * convergence_table.add_value("Pressure,L2", p_l2_error);
1444 * convergence_table.add_value("Pressure,L2-nodal", p_l2_mid_error);
1452 * <a name="mfmfe.cc-Outputresults"></a>
1453 * <h4>Output results</h4>
1457 * This function also follows the same idea as in @ref step_20 "step-20" tutorial
1458 * program. The only modification to it is the part involving
1459 * a convergence table.
1462 * template <int dim>
1463 * void MultipointMixedDarcyProblem<dim>::output_results(const unsigned int cycle, const unsigned int refine)
1465 * TimerOutput::Scope t(computing_timer, "Output results");
1467 * std::vector<std::string> solution_names(dim, "u");
1468 * solution_names.push_back ("p");
1469 * std::vector<DataComponentInterpretation::DataComponentInterpretation>
1470 * interpretation (dim, DataComponentInterpretation::component_is_part_of_vector);
1471 * interpretation.push_back (DataComponentInterpretation::component_is_scalar);
1473 * DataOut<dim> data_out;
1474 * data_out.add_data_vector (dof_handler, solution, solution_names, interpretation);
1475 * data_out.build_patches ();
1477 * std::ofstream output ("solution" + std::to_string(dim) + "d-" + std::to_string(cycle) + ".vtk");
1478 * data_out.write_vtk (output);
1480 * convergence_table.set_precision("Velocity,L2", 3);
1481 * convergence_table.set_precision("Velocity,Hdiv", 3);
1482 * convergence_table.set_precision("Pressure,L2", 3);
1483 * convergence_table.set_precision("Pressure,L2-nodal", 3);
1484 * convergence_table.set_scientific("Velocity,L2", true);
1485 * convergence_table.set_scientific("Velocity,Hdiv", true);
1486 * convergence_table.set_scientific("Pressure,L2", true);
1487 * convergence_table.set_scientific("Pressure,L2-nodal", true);
1488 * convergence_table.set_tex_caption("cells", "\\# cells");
1489 * convergence_table.set_tex_caption("dofs", "\\# dofs");
1490 * convergence_table.set_tex_caption("Velocity,L2", " \\|\\u - \\u_h\\|_{L^2} ");
1491 * convergence_table.set_tex_caption("Velocity,Hdiv", " \\|\\nabla\\cdot(\\u - \\u_h)\\|_{L^2} ");
1492 * convergence_table.set_tex_caption("Pressure,L2", " \\|p - p_h\\|_{L^2} ");
1493 * convergence_table.set_tex_caption("Pressure,L2-nodal", " \\|Qp - p_h\\|_{L^2} ");
1494 * convergence_table.set_tex_format("cells", "r");
1495 * convergence_table.set_tex_format("dofs", "r");
1497 * convergence_table.evaluate_convergence_rates("Velocity,L2", ConvergenceTable::reduction_rate_log2);
1498 * convergence_table.evaluate_convergence_rates("Velocity,Hdiv", ConvergenceTable::reduction_rate_log2);
1499 * convergence_table.evaluate_convergence_rates("Pressure,L2", ConvergenceTable::reduction_rate_log2);
1500 * convergence_table.evaluate_convergence_rates("Pressure,L2-nodal", ConvergenceTable::reduction_rate_log2);
1502 * std::ofstream error_table_file("error" + std::to_string(dim) + "d.tex");
1504 * if (cycle == refine-1)
1506 * convergence_table.write_text(std::cout);
1507 * convergence_table.write_tex(error_table_file);
1516 * <a name="mfmfe.cc-Runfunction"></a>
1517 * <h3>Run function</h3>
1521 * The driver method <code>run()</code>
1522 * takes care of mesh generation and arranging calls to member methods in
1523 * the right way. It also resets data structures and clear triangulation and
1524 * DOF handler as we run the method on a sequence of refinements in order
1525 * to record convergence rates.
1528 * template <int dim>
1529 * void MultipointMixedDarcyProblem<dim>::run(const unsigned int refine)
1531 * Assert(refine > 0, ExcMessage("Must at least have 1 refinement cycle!"));
1533 * dof_handler.clear();
1534 * triangulation.clear();
1535 * convergence_table.clear();
1537 * for (unsigned int cycle=0; cycle<refine; ++cycle)
1543 * We first generate the hyper cube and refine it twice
1544 * so that we could distort the grid slightly and
1545 * demonstrate the method's ability to work in such a
1557 * make_cell_centered_sp();
1558 * pressure_assembly();
1559 * solve_pressure ();
1560 * velocity_recovery ();
1561 * compute_errors (cycle);
1562 * output_results (cycle, refine);
1563 * reset_data_structures ();
1565 * computing_timer.print_summary ();
1566 * computing_timer.reset ();
1575 * <a name=
"mfmfe.cc-Thecodemaincodefunction"></a>
1576 * <h3>The <code>main</code> function</h3>
1580 * In the main functione we pass the order of the Finite Element as an argument
1581 * to the constructor of the Multipoint Flux Mixed Darcy problem, and the number
1582 * of refinement cycles as an argument
for the
run method.
1589 *
using namespace dealii;
1590 *
using namespace MFMFE;
1594 * MultipointMixedDarcyProblem<2> mfmfe_problem(2);
1595 * mfmfe_problem.run(6);
1597 *
catch (std::exception &exc)
1599 * std::cerr << std::endl << std::endl
1600 * <<
"----------------------------------------------------"
1602 * std::cerr <<
"Exception on processing: " << std::endl
1603 * << exc.what() << std::endl
1604 * <<
"Aborting!" << std::endl
1605 * <<
"----------------------------------------------------"
1612 * std::cerr << std::endl << std::endl
1613 * <<
"----------------------------------------------------"
1615 * std::cerr <<
"Unknown exception!" << std::endl
1616 * <<
"Aborting!" << std::endl
1617 * <<
"----------------------------------------------------"
virtual void vector_gradient(const Point< dim > &p, std::vector< Tensor< 1, dim, RangeNumberType > > &gradients) const
virtual RangeNumberType value(const Point< dim > &p, const unsigned int component=0) const
virtual void vector_value(const Point< dim > &p, Vector< RangeNumberType > &values) const
static void set_thread_limit(const unsigned int max_threads=numbers::invalid_unsigned_int)
virtual void value_list(const std::vector< Point< dim > > &points, std::vector< value_type > &values) const
#define Assert(cond, exc)
typename ActiveSelector::active_cell_iterator active_cell_iterator
@ update_values
Shape function values.
@ update_normal_vectors
Normal vectors.
@ update_JxW_values
Transformed quadrature weights.
@ update_gradients
Shape function gradients.
@ update_quadrature_points
Transformed quadrature points.
std::vector< index_type > data
void component_wise(DoFHandler< dim, spacedim > &dof_handler, const std::vector< unsigned int > &target_component=std::vector< unsigned int >())
void hyper_cube(Triangulation< dim, spacedim > &tria, const double left=0., const double right=1., const bool colorize=false)
@ matrix
Contents is actually a matrix.
SymmetricTensor< 2, dim, Number > C(const Tensor< 2, dim, Number > &F)
SymmetricTensor< 2, dim, Number > d(const Tensor< 2, dim, Number > &F, const Tensor< 2, dim, Number > &dF_dt)
VectorType::value_type * begin(VectorType &V)
constexpr T pow(const T base, const int iexp)
void run(const Iterator &begin, const std_cxx20::type_identity_t< Iterator > &end, Worker worker, Copier copier, const ScratchData &sample_scratch_data, const CopyData &sample_copy_data, const unsigned int queue_length, const unsigned int chunk_size)
void run(const std::vector< std::vector< Iterator > > &colored_iterators, Worker worker, Copier copier, const ScratchData &sample_scratch_data, const CopyData &sample_copy_data, const unsigned int queue_length=2 *MultithreadInfo::n_threads(), const unsigned int chunk_size=8)
unsigned int n_cells(const internal::TriangulationImplementation::NumberCache< 1 > &c)
void copy(const T *begin, const T *end, U *dest)
int(&) functions(const void *v1, const void *v2)
void assemble(const MeshWorker::DoFInfoBox< dim, DOFINFO > &dinfo, A *assembler)
::VectorizedArray< Number, width > cos(const ::VectorizedArray< Number, width > &)
::VectorizedArray< Number, width > sin(const ::VectorizedArray< Number, width > &)
::VectorizedArray< Number, width > pow(const ::VectorizedArray< Number, width > &, const Number p)
::VectorizedArray< Number, width > abs(const ::VectorizedArray< Number, width > &)
const ::parallel::distributed::Triangulation< dim, spacedim > * triangulation