]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Fix removed exceptions in function.h
authorWolfgang Bangerth <bangerth@math.tamu.edu>
Mon, 29 May 2000 12:17:06 +0000 (12:17 +0000)
committerWolfgang Bangerth <bangerth@math.tamu.edu>
Mon, 29 May 2000 12:17:06 +0000 (12:17 +0000)
git-svn-id: https://svn.dealii.org/trunk@2968 0785d39b-7218-0410-832d-ea1e28bc413d

deal.II/examples/step-9/step-9.cc

index 9b5601347997483a8fca075b20db7a8baf9da8cd..996be16f80273bc55ab0dcbf682af029eade92d6 100644 (file)
@@ -87,7 +87,7 @@ class AdvectionField
                                     /**
                                      * Exception
                                      */
-    DeclException2 (ExcVectorHasWrongSize,
+    DeclException2 (ExcDimensionMismatch,
                    int, int,
                    << "The vector has size " << arg1 << " but should have "
                    << arg2 << " elements.");
@@ -115,7 +115,7 @@ AdvectionField<dim>::value_list (const vector<Point<dim> > &points,
                                 vector<Point<dim> >       &values) const 
 {
   Assert (values.size() == points.size(),
-         ExcVectorHasWrongSize (values.size(), points.size()));
+         ExcDimensionMismatch (values.size(), points.size()));
   
   for (unsigned int i=0; i<points.size(); ++i)
     values[i] = AdvectionField<dim>::value (points[i]);
@@ -156,7 +156,7 @@ double
 RightHandSide<dim>::value (const Point<dim>   &p,
                           const unsigned int  component) const 
 {
-  Assert (component == 0, ExcWrongComponent (component, 1));
+  Assert (component == 0, ExcIndexRange (component, 0, 1));
   const double diameter = 0.1;
   return ( (p-center_point).square() < diameter*diameter ?
           .1/pow(diameter,dim) :
@@ -172,7 +172,7 @@ RightHandSide<dim>::value_list (const vector<Point<dim> > &points,
                                const unsigned int         component) const 
 {
   Assert (values.size() == points.size(),
-         ExcVectorHasWrongSize (values.size(), points.size()));
+         ExcDimensionMismatch (values.size(), points.size()));
   
   for (unsigned int i=0; i<points.size(); ++i)
     values[i] = RightHandSide<dim>::value (points[i], component);
@@ -199,7 +199,7 @@ double
 BoundaryValues<dim>::value (const Point<dim>   &p,
                            const unsigned int  component) const 
 {
-  Assert (component == 0, ExcWrongComponent (component, 1));
+  Assert (component == 0, ExcIndexRange (component, 0, 1));
 
   const double sine_term = sin(16*M_PI*sqrt(p.square()));
   const double weight    = exp(-5*p.square()) / exp(-5.);
@@ -215,7 +215,7 @@ BoundaryValues<dim>::value_list (const vector<Point<dim> > &points,
                                 const unsigned int         component) const 
 {
   Assert (values.size() == points.size(),
-         ExcVectorHasWrongSize (values.size(), points.size()));
+         ExcDimensionMismatch (values.size(), points.size()));
   
   for (unsigned int i=0; i<points.size(); ++i)
     values[i] = BoundaryValues<dim>::value (points[i], component);

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.