]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Compute the time step the correct way.
authorWolfgang Bangerth <bangerth@math.tamu.edu>
Wed, 17 Oct 2007 19:48:48 +0000 (19:48 +0000)
committerWolfgang Bangerth <bangerth@math.tamu.edu>
Wed, 17 Oct 2007 19:48:48 +0000 (19:48 +0000)
git-svn-id: https://svn.dealii.org/trunk@15341 0785d39b-7218-0410-832d-ea1e28bc413d

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

index c08c0d5f14c6f2a77056b4b3a0bd2db895a4e654..5dfb2cbad33c7ea4927c9360736eeae3b5f85711 100644 (file)
@@ -788,7 +788,7 @@ void BoussinesqFlowProblem<dim>::solve ()
     A_inverse.vmult (solution.block(0), tmp);
   }
 
-  time_step = std::pow(0.5, double(n_refinement_steps)) /
+  time_step = GridTools::minimal_cell_diameter(triangulation) /
               std::max(get_maximal_velocity(),1.);
 
   assemble_rhs_T ();

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.