]> https://gitweb.dealii.org/ - dealii-svn.git/commitdiff
get_function_grads asserts number of components
authorguido <guido@0785d39b-7218-0410-832d-ea1e28bc413d>
Tue, 4 May 1999 08:06:45 +0000 (08:06 +0000)
committerguido <guido@0785d39b-7218-0410-832d-ea1e28bc413d>
Tue, 4 May 1999 08:06:45 +0000 (08:06 +0000)
git-svn-id: https://svn.dealii.org/trunk@1258 0785d39b-7218-0410-832d-ea1e28bc413d

deal.II/deal.II/source/fe/fe_values.cc

index 131a7166a9f2b450138682be03513574a4234aff..7b614b4d3d05f6dbd917d4564fd4510a84b2d4fc 100644 (file)
@@ -140,7 +140,10 @@ FEValuesBase<dim>::shape_grad (const unsigned int i,
 
 template <int dim>
 void FEValuesBase<dim>::get_function_grads (const Vector<double>   &fe_function,
-                                           vector<Tensor<1,dim> > &gradients) const {
+                                           vector<Tensor<1,dim> > &gradients) const
+{
+  Assert (fe->n_components == 1,
+         ExcWrongNoOfComponents());
   Assert (gradients.size() == n_quadrature_points,
          ExcWrongVectorSize(gradients.size(), n_quadrature_points));
 

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.