]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Move a piece of code to a better location.
authorWolfgang Bangerth <bangerth@colostate.edu>
Mon, 18 May 2020 23:50:07 +0000 (17:50 -0600)
committerWolfgang Bangerth <bangerth@colostate.edu>
Tue, 19 May 2020 00:22:46 +0000 (18:22 -0600)
examples/step-70/step-70.cc

index 9ea88cc6e02f03156a8c95c6b962a0057e9e63ba..0c524d61d7ce0af3708decd8ec505f82ddbfdfb0 100644 (file)
@@ -1098,13 +1098,6 @@ namespace Step70
       std_cxx14::make_unique<QGauss<spacedim>>(par.velocity_degree + 1);
     solid_quadrature_formula =
       std_cxx14::make_unique<QGauss<dim>>(par.velocity_degree + 1);
-
-    // Save the current parameter file in the output directory, for
-    // reproducibility
-    par.prm.print_parameters(par.output_directory + "/" + "parameters_" +
-                               std::to_string(dim) + std::to_string(spacedim) +
-                               ".prm",
-                             ParameterHandler::Short);
   }
 
 
@@ -1616,8 +1609,13 @@ namespace Step70
   }
 
 
-  // This function orchestrates the entire simulation. It is very similar
-  // to the other time dependent tutorial programs.
+  // @sect4{The "run" function}
+
+  // This function now orchestrates the entire simulation. It is very similar
+  // to the other time dependent tutorial programs -- take step-26 as an example. At the beginning, we
+  // output some status information and also
+  // save all current parameters to a file in the output directory, for
+  // reproducibility.
   template <int dim, int spacedim>
   void StokesImmersedProblem<dim, spacedim>::run()
   {
@@ -1630,6 +1628,10 @@ namespace Step70
           << Utilities::dim_string(dim, spacedim) << "> using Trilinos."
           << std::endl;
 #endif
+    par.prm.print_parameters(par.output_directory + "/" + "parameters_" +
+                               std::to_string(dim) + std::to_string(spacedim) +
+                               ".prm",
+                             ParameterHandler::Short);
 
     ComponentMask velocity_mask(spacedim + 1, true);
     velocity_mask.set(spacedim, false);

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.