From 1ff1697850014462e82afcb8fae60c3346a1a6e9 Mon Sep 17 00:00:00 2001 From: bangerth Date: Wed, 29 Oct 2008 00:00:24 +0000 Subject: [PATCH] Specify a few template arguments explicitly to help IBM's xlC. git-svn-id: https://svn.dealii.org/trunk@17385 0785d39b-7218-0410-832d-ea1e28bc413d --- .../deal.II/include/numerics/vectors.templates.h | 14 +++++++++++--- deal.II/deal.II/source/fe/fe_raviart_thomas.cc | 4 +++- .../deal.II/source/fe/fe_raviart_thomas_nodal.cc | 2 +- deal.II/deal.II/source/fe/fe_tools.cc | 2 +- 4 files changed, 16 insertions(+), 6 deletions(-) diff --git a/deal.II/deal.II/include/numerics/vectors.templates.h b/deal.II/deal.II/include/numerics/vectors.templates.h index 90890d3212..f3d3193eca 100644 --- a/deal.II/deal.II/include/numerics/vectors.templates.h +++ b/deal.II/deal.II/include/numerics/vectors.templates.h @@ -2536,7 +2536,15 @@ VectorTools::compute_no_normal_flux_constraints (const DH &dof_hand switch (dim) { case 3: - cross_product (tangent, normals[0], normals[1]); + // take cross product between normals[0] and + // normals[1]. write it in the current form to + // make sure that compilers don't warn about + // out-of-bounds accesses -- the warnings are + // bogus since we get here only for dim==3, but + // at least one isn't quite smart enough to + // notice this and warns when compiling the + // function in 2d + cross_product (tangent, normals[0], normals[dim-2]); break; default: Assert (false, ExcNotImplemented()); @@ -2587,8 +2595,8 @@ VectorTools::compute_no_normal_flux_constraints (const DH &dof_hand // is to be constrained Tensor<1,dim> constraining_normals[dim-1]; internal::VectorTools:: - compute_orthonormal_vectors (average_tangent, - constraining_normals); + compute_orthonormal_vectors (average_tangent, + constraining_normals); // now all that is left // is that we add the diff --git a/deal.II/deal.II/source/fe/fe_raviart_thomas.cc b/deal.II/deal.II/source/fe/fe_raviart_thomas.cc index c8a90c80ce..6b0b24da4e 100644 --- a/deal.II/deal.II/source/fe/fe_raviart_thomas.cc +++ b/deal.II/deal.II/source/fe/fe_raviart_thomas.cc @@ -82,7 +82,9 @@ FE_RaviartThomas::FE_RaviartThomas (const unsigned int deg) FullMatrix face_embeddings[GeometryInfo::max_children_per_face]; for (unsigned int i=0; i::max_children_per_face; ++i) face_embeddings[i].reinit (this->dofs_per_face, this->dofs_per_face); - FETools::compute_face_embedding_matrices(*this, face_embeddings, 0, 0); + FETools::compute_face_embedding_matrices(*this, + face_embeddings, + 0, 0); this->interface_constraints.reinit((1<<(dim-1)) * this->dofs_per_face, this->dofs_per_face); unsigned int target_row=0; diff --git a/deal.II/deal.II/source/fe/fe_raviart_thomas_nodal.cc b/deal.II/deal.II/source/fe/fe_raviart_thomas_nodal.cc index 7948173b86..bf20b13275 100644 --- a/deal.II/deal.II/source/fe/fe_raviart_thomas_nodal.cc +++ b/deal.II/deal.II/source/fe/fe_raviart_thomas_nodal.cc @@ -86,7 +86,7 @@ FE_RaviartThomasNodal::FE_RaviartThomasNodal (const unsigned int deg) FullMatrix face_embeddings[GeometryInfo::max_children_per_face]; for (unsigned int i=0; i::max_children_per_face; ++i) face_embeddings[i].reinit (this->dofs_per_face, this->dofs_per_face); - FETools::compute_face_embedding_matrices(*this, face_embeddings, 0, 0); + FETools::compute_face_embedding_matrices(*this, face_embeddings, 0, 0); this->interface_constraints.reinit((1<<(dim-1)) * this->dofs_per_face, this->dofs_per_face); unsigned int target_row=0; diff --git a/deal.II/deal.II/source/fe/fe_tools.cc b/deal.II/deal.II/source/fe/fe_tools.cc index 98152efbea..a61bbd0677 100644 --- a/deal.II/deal.II/source/fe/fe_tools.cc +++ b/deal.II/deal.II/source/fe/fe_tools.cc @@ -1924,7 +1924,7 @@ void FETools::compute_embedding_matrices (const FiniteElement &, std::vector > >&); template -void FETools::compute_face_embedding_matrices +void FETools::compute_face_embedding_matrices (const FiniteElement &, FullMatrix (&matrices)[GeometryInfo::max_children_per_face], unsigned int, unsigned int); -- 2.39.5