From: MichaƂ Wichrowski Date: Thu, 1 May 2025 18:14:49 +0000 (+0200) Subject: remove .cc -> template X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=a11593381c675af65d588c2166d4a6283441ff3f;p=dealii.git remove .cc -> template --- diff --git a/scratch/mwichro/dealii/src/numerics/tensor_product_matrix_creator_test.cc b/scratch/mwichro/dealii/src/numerics/tensor_product_matrix_creator_test.cc deleted file mode 100644 index fd1a39ad23..0000000000 --- a/scratch/mwichro/dealii/src/numerics/tensor_product_matrix_creator_test.cc +++ /dev/null @@ -1,70 +0,0 @@ -#include -#include - -#include - -#include - -#include - -#include - - -DEAL_II_NAMESPACE_OPEN - - -namespace TensorProductMatrixCreator -{ - - - FullMatrix - create_1d_cell_mass_matrix(const FiniteElement<1> &fe, - const double &h, - const std::pair include_endpoints, - std::vector numbering) - { - if (dynamic_cast *>(&fe) == nullptr && - numbering.size() == 0) - { - Assert( - include_endpoints.first == true && include_endpoints.second == true, - ExcMessage( - "You tried to generate a 1D mass matrix with excluding boundary " - "dofs for a non-DGQ element without providing a numbering.")); - } - - - if (numbering.size() == 0) - { - numbering.resize(fe.dofs_per_cell); - std::iota(numbering.begin(), numbering.end(), 0); - } - const unsigned int degree = fe.degree; - const unsigned int n_dofs_per_cell = fe.dofs_per_cell; - const double &JxW = h; - QGauss<1> quadrature(degree + 1); - - FullMatrix cell_mass_matrix(n_dofs_per_cell, n_dofs_per_cell); - cell_mass_matrix = 0; - - unsigned int start_dof = include_endpoints.first ? 0 : 1; - unsigned int end_dof = - include_endpoints.second ? n_dofs_per_cell : n_dofs_per_cell - 1; - const unsigned int shift = include_endpoints.first ? 0 : 1; - - for (unsigned int i = start_dof; i < end_dof; ++i) - for (unsigned int j = start_dof; j < end_dof; ++j) - for (unsigned int q = 0; q < quadrature.size(); ++q) - cell_mass_matrix(i - shift, j - shift) += - (fe.shape_value(numbering[i], quadrature.point(q)) * - fe.shape_value(numbering[j], quadrature.point(q))) * - JxW * quadrature.weight(q); - - return cell_mass_matrix; - } - - -} // namespace TensorProductMatrixCreator - - -DEAL_II_NAMESPACE_CLOSE \ No newline at end of file