]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Make condition work also if
authorWolfgang Bangerth <bangerth@math.tamu.edu>
Sun, 13 Feb 2011 23:10:30 +0000 (23:10 +0000)
committerWolfgang Bangerth <bangerth@math.tamu.edu>
Sun, 13 Feb 2011 23:10:30 +0000 (23:10 +0000)
parameters.graphical_output_interval==1. Fix possible range for this parameter.

git-svn-id: https://svn.dealii.org/trunk@23353 0785d39b-7218-0410-832d-ea1e28bc413d

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

index 22f48f9a1ba63a28e19329c7ff2784684cc76626..d48e639048c03dd6582b8c66e4ada89bd21934d4 100644 (file)
@@ -999,7 +999,7 @@ declare_parameters (ParameterHandler &prm)
                     "The number of adaptive refinement steps performed after "
                     "initial global refinement.");
   prm.declare_entry ("Time steps between mesh refinement", "10",
-                    Patterns::Integer (10),
+                    Patterns::Integer (1),
                     "The number of time steps after which the mesh is to be "
                     "adapted based on computed error indicators.");
   prm.declare_entry ("Generate graphical output", "false",
@@ -3601,7 +3601,7 @@ void BoussinesqFlowProblem<dim>::run (const std::string parameter_filename)
                                   // do-while loop
   if ((parameters.generate_graphical_output == true)
       &&
-      (timestep_number % parameters.graphical_output_interval != 1))
+      !((timestep_number-1) % parameters.graphical_output_interval == 0))
     output_results ();
 }
 

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.