From 03116b9e61b34bcb113e4227fc5f6a70d16dc8ea Mon Sep 17 00:00:00 2001 From: kanschat Date: Mon, 13 Sep 2010 14:34:28 +0000 Subject: [PATCH] eliminate compiler warnings git-svn-id: https://svn.dealii.org/trunk@21945 0785d39b-7218-0410-832d-ea1e28bc413d --- deal.II/deal.II/include/fe/fe_nedelec.h | 7 +++-- deal.II/deal.II/source/fe/fe_nedelec.cc | 41 ++++++++++++------------- 2 files changed, 25 insertions(+), 23 deletions(-) diff --git a/deal.II/deal.II/include/fe/fe_nedelec.h b/deal.II/deal.II/include/fe/fe_nedelec.h index 133a505240..c3b038c6ce 100644 --- a/deal.II/deal.II/include/fe/fe_nedelec.h +++ b/deal.II/deal.II/include/fe/fe_nedelec.h @@ -165,7 +165,8 @@ class FE_Nedelec : public FE_PolyTensor, dim> { * element, then they must throw an exception of type * FiniteElement::ExcInterpolationNotImplemented. */ - virtual void get_face_interpolation_matrix (const FiniteElement& source, FullMatrix& matrix) const; + virtual void get_face_interpolation_matrix (const FiniteElement& source, + FullMatrix& matrix) const; /** * Return the matrix interpolating from a face of one element @@ -180,7 +181,9 @@ class FE_Nedelec : public FE_PolyTensor, dim> { * element, then they must throw an exception of type * ExcInterpolationNotImplemented. */ - virtual void get_subface_interpolation_matrix (const FiniteElement& source, const unsigned int subface, FullMatrix& matrix) const; + virtual void get_subface_interpolation_matrix (const FiniteElement& source, + const unsigned int subface, + FullMatrix& matrix) const; virtual void interpolate (std::vector& local_dofs, const std::vector& values) const; diff --git a/deal.II/deal.II/source/fe/fe_nedelec.cc b/deal.II/deal.II/source/fe/fe_nedelec.cc index e55feaa170..d0bb20cd78 100644 --- a/deal.II/deal.II/source/fe/fe_nedelec.cc +++ b/deal.II/deal.II/source/fe/fe_nedelec.cc @@ -141,7 +141,7 @@ FiniteElement // function. template void -FE_Nedelec::initialize_support_points (const unsigned int degree) +FE_Nedelec::initialize_support_points (const unsigned int) { Assert (false, ExcNotImplemented ()); } @@ -1580,7 +1580,7 @@ FE_Nedelec::hp_constraints_are_implemented () const template std::vector > -FE_Nedelec::hp_vertex_dof_identities (const FiniteElement& fe_other) +FE_Nedelec::hp_vertex_dof_identities (const FiniteElement&) const { // Nedelec elements do not have any dofs @@ -1743,7 +1743,7 @@ const if (dim == 3) for (unsigned int i = 0; i <= deg; ++i) { - for (unsigned int j = 1; j < GeometryInfo::lines_per_face; ++j) + for (int j = 1; j < (int) GeometryInfo::lines_per_face; ++j) interpolation_matrix (j * source_fe.degree + i, j * this->degree + i) = 1.0; @@ -1766,9 +1766,9 @@ const template void -FE_Nedelec::get_subface_interpolation_matrix - (const FiniteElement& source, const unsigned int subface, - FullMatrix& interpolation_matrix) const +FE_Nedelec::get_subface_interpolation_matrix( + const FiniteElement&, const unsigned int, + FullMatrix&) const { Assert (false, ExcNotImplemented ()); } @@ -2341,8 +2341,8 @@ FE_Nedelec::get_subface_interpolation_matrix for (unsigned int q_point = 0; q_point < n_edge_points; ++q_point) { - const double weight - = 2.0 * edge_quadrature_x.weight (q_point); +// const double weight +// = 2.0 * edge_quadrature_x.weight (q_point); for (unsigned int i = 0; i < 2; ++i) for (unsigned int dof = 0; dof < this->dofs_per_face; @@ -2735,8 +2735,8 @@ FE_Nedelec::get_subface_interpolation_matrix for (unsigned int q_point = 0; q_point < n_edge_points; ++q_point) { - const double weight - = 2.0 * edge_quadrature_x.weight (q_point); +// const double weight +// = 2.0 * edge_quadrature_x.weight (q_point); for (unsigned int i = 0; i < 2; ++i) for (unsigned int dof = 0; dof < this->dofs_per_face; @@ -3115,8 +3115,8 @@ FE_Nedelec::get_subface_interpolation_matrix for (unsigned int q_point = 0; q_point < n_edge_points; ++q_point) { - const double weight - = 2.0 * edge_quadrature.weight (q_point); +// const double weight +// = 2.0 * edge_quadrature.weight (q_point); for (unsigned int i = 0; i < 2; ++i) for (unsigned int dof = 0; dof < this->dofs_per_face; @@ -3825,7 +3825,7 @@ FE_Nedelec::interpolate (std::vector& local_dofs, local_dofs[(i + 8) * this->degree] = 0.0; } - if (offset < dim - 1) + if (offset+1 < dim) { for (unsigned int i = 0; i < 2; ++i) for (unsigned int j = 0; j < 2; ++j) @@ -3923,7 +3923,7 @@ FE_Nedelec::interpolate (std::vector& local_dofs, system_rhs = 0; if ((((line == 0) || (line == 1) || (line == 4) || - (line == 5)) && (offset < dim - 1)) || + (line == 5)) && (offset+1 < dim)) || (((line == 2) || (line == 3) || (line == 6) || (line == 7)) && (offset == 0)) || (line > 7)) { @@ -4010,7 +4010,7 @@ FE_Nedelec::interpolate (std::vector& local_dofs, { case 0: { - if (offset < dim - 1) + if (offset+1 < dim) { // Set up the right hand side // for the horizontal shape @@ -4114,7 +4114,7 @@ FE_Nedelec::interpolate (std::vector& local_dofs, case 1: { - if (offset < dim - 1) + if (offset+1 < dim) { // Set up the right hand side // for the horizontal shape @@ -4437,7 +4437,7 @@ FE_Nedelec::interpolate (std::vector& local_dofs, case 4: { - if (offset < dim - 1) + if (offset+1 < dim) { // Set up the right hand side // for the horizontal shape @@ -4550,7 +4550,7 @@ FE_Nedelec::interpolate (std::vector& local_dofs, } default: - if (offset < dim - 1) + if (offset+1 < dim) { // Set up the right hand side // for the horizontal shape @@ -4733,7 +4733,7 @@ FE_Nedelec::interpolate (std::vector& local_dofs, system_rhs.reinit (system_matrix_inv.m ()); solution.reinit (system_matrix.m ()); - if (offset < dim - 1) + if (offset+1 < dim) { if (offset == 0) { @@ -5569,8 +5569,7 @@ const + GeometryInfo::lines_per_cell * n_edge_points]; - for (unsigned int i = 2; - i < GeometryInfo::lines_per_face; ++i) + for (int i = 2;i < (int) GeometryInfo::lines_per_face; ++i) for (unsigned int j = 0; j <= deg; ++j) tmp -= local_dofs[edge_indices[face][i] * this->degree + j] -- 2.39.5