]> https://gitweb.dealii.org/ - dealii-svn.git/commitdiff
Make more to standard.
authorbangerth <bangerth@0785d39b-7218-0410-832d-ea1e28bc413d>
Tue, 2 Aug 2011 20:20:02 +0000 (20:20 +0000)
committerbangerth <bangerth@0785d39b-7218-0410-832d-ea1e28bc413d>
Tue, 2 Aug 2011 20:20:02 +0000 (20:20 +0000)
git-svn-id: https://svn.dealii.org/trunk@23999 0785d39b-7218-0410-832d-ea1e28bc413d

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

index 05f5d9f531d47376e2d31f433a1f8770fb0d975f..3ca50262888f9c23bfe4a1c1f15cdb98e8c7d97f 100644 (file)
@@ -225,7 +225,7 @@ void LaplaceProblem<dim>::setup_system ()
 
 
   constraints.clear ();
-  DoFTools::make_constraints (dof_handler,
+  DoFTools::make_hanging_node_constraints (dof_handler,
                                           constraints);
   constraints.close ();
 
@@ -376,14 +376,19 @@ void LaplaceProblem<dim>::output_results (const unsigned int cycle) const
 {
   Assert (cycle < 10, ExcNotImplemented());
 
-  std::string filename = "grid-";
+  std::string filename = "solution-";
   filename += ('0' + cycle);
-  filename += ".eps";
+  filename += ".vtk";
 
   std::ofstream output (filename.c_str());
 
-  GridOut grid_out;
-  grid_out.write_eps (triangulation, output);
+  DataOut<dim,hp::DoFHandler<dim> > data_out;
+
+  data_out.attach_dof_handler (dof_handler);
+  data_out.add_data_vector (solution, "solution");
+  data_out.build_patches ();
+
+  data_out.write_vtk (output);
 }
 
 
@@ -423,19 +428,6 @@ void LaplaceProblem<dim>::run ()
       solve ();
       output_results (cycle);
     }
-
-  DataOutBase::EpsFlags eps_flags;
-  eps_flags.z_scaling = 4;
-
-  DataOut<dim,hp::DoFHandler<dim> > data_out;
-  data_out.set_flags (eps_flags);
-
-  data_out.attach_dof_handler (dof_handler);
-  data_out.add_data_vector (solution, "solution");
-  data_out.build_patches ();
-
-  std::ofstream output ("final-solution.eps");
-  data_out.write_eps (output);
 }
 
 

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.