]> https://gitweb.dealii.org/ - dealii-svn.git/commitdiff
update.
authorwolf <wolf@0785d39b-7218-0410-832d-ea1e28bc413d>
Thu, 23 Dec 1999 11:09:31 +0000 (11:09 +0000)
committerwolf <wolf@0785d39b-7218-0410-832d-ea1e28bc413d>
Thu, 23 Dec 1999 11:09:31 +0000 (11:09 +0000)
git-svn-id: https://svn.dealii.org/trunk@2119 0785d39b-7218-0410-832d-ea1e28bc413d

deal.II/deal.II/Attic/examples/step-by-step/step-4/step-4.cc
deal.II/examples/step-4/step-4.cc

index 1e09267f8ebf11b02c74414b971d09379854e221..74ec87d055e1c6be85127a7495b714cec913db46 100644 (file)
@@ -128,7 +128,7 @@ class RightHandSide : public Function<dim>
 {
   public:
     virtual double value (const Point<dim>   &p,
-                         const unsigned int  component) const;
+                         const unsigned int  component = 0) const;
 };
 
 
@@ -138,7 +138,7 @@ class BoundaryValues : public Function<dim>
 {
   public:
     virtual double value (const Point<dim>   &p,
-                         const unsigned int  component) const;
+                         const unsigned int  component = 0) const;
 };
 
 
@@ -510,9 +510,9 @@ void LaplaceProblem<dim>::output_results ()
                                   // other values than 2 or 3, but we
                                   // neglect this here for the sake
                                   // of brevity).
-  ofstream output ((dim == 2 ?
-                   "solution-2d.gmv" :
-                   "solution-3d.gmv");
+  ofstream output (dim == 2 ?
+                  "solution-2d.gmv" :
+                  "solution-3d.gmv");
   data_out.write_gmv (output);
 };
 
@@ -580,10 +580,11 @@ int main ()
                                   // on just as before: define one of
                                   // these top-level objects and
                                   // transfer control to it:
-//  LaplaceProblem<2> laplace_problem_2d;
-//  laplace_problem_2d.run ();
+  LaplaceProblem<2> laplace_problem_2d;
+  laplace_problem_2d.run ();
 
-    LaplaceProblem<3> laplace_problem_3d;
-    laplace_problem_3d.run ();
+  LaplaceProblem<3> laplace_problem_3d;
+  laplace_problem_3d.run ();
+  
   return 0;
 };
index 1e09267f8ebf11b02c74414b971d09379854e221..74ec87d055e1c6be85127a7495b714cec913db46 100644 (file)
@@ -128,7 +128,7 @@ class RightHandSide : public Function<dim>
 {
   public:
     virtual double value (const Point<dim>   &p,
-                         const unsigned int  component) const;
+                         const unsigned int  component = 0) const;
 };
 
 
@@ -138,7 +138,7 @@ class BoundaryValues : public Function<dim>
 {
   public:
     virtual double value (const Point<dim>   &p,
-                         const unsigned int  component) const;
+                         const unsigned int  component = 0) const;
 };
 
 
@@ -510,9 +510,9 @@ void LaplaceProblem<dim>::output_results ()
                                   // other values than 2 or 3, but we
                                   // neglect this here for the sake
                                   // of brevity).
-  ofstream output ((dim == 2 ?
-                   "solution-2d.gmv" :
-                   "solution-3d.gmv");
+  ofstream output (dim == 2 ?
+                  "solution-2d.gmv" :
+                  "solution-3d.gmv");
   data_out.write_gmv (output);
 };
 
@@ -580,10 +580,11 @@ int main ()
                                   // on just as before: define one of
                                   // these top-level objects and
                                   // transfer control to it:
-//  LaplaceProblem<2> laplace_problem_2d;
-//  laplace_problem_2d.run ();
+  LaplaceProblem<2> laplace_problem_2d;
+  laplace_problem_2d.run ();
 
-    LaplaceProblem<3> laplace_problem_3d;
-    laplace_problem_3d.run ();
+  LaplaceProblem<3> laplace_problem_3d;
+  laplace_problem_3d.run ();
+  
   return 0;
 };

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.