From: Timo Heister Date: Thu, 10 Dec 2020 23:34:59 +0000 (-0500) Subject: step-47: misc cleanup X-Git-Tag: v9.3.0-rc1~762^2 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=369766137f5b4d32a93c6379d87376ee61261ff5;p=dealii.git step-47: misc cleanup - line up numbers in std::cout messages - minor formatting --- diff --git a/examples/step-47/step-47.cc b/examples/step-47/step-47.cc index a37518416e..5bda3cd333 100644 --- a/examples/step-47/step-47.cc +++ b/examples/step-47/step-47.cc @@ -769,7 +769,7 @@ namespace Step47 VectorTools::compute_global_error(triangulation, norm_per_cell, VectorTools::L2_norm); - std::cout << " Error in the L2 norm : " << error_norm + std::cout << " Error in the L2 norm : " << error_norm << std::endl; } @@ -860,8 +860,9 @@ namespace Step47 data_out.add_data_vector(solution, "solution"); data_out.build_patches(); - std::ofstream output_vtu( - ("output_" + Utilities::int_to_string(iteration, 6) + ".vtu").c_str()); + const std::string filename = + ("output_" + Utilities::int_to_string(iteration, 6) + ".vtu"); + std::ofstream output_vtu(filename); data_out.write_vtu(output_vtu); } @@ -877,7 +878,7 @@ namespace Step47 const unsigned int n_cycles = 4; for (unsigned int cycle = 0; cycle < n_cycles; ++cycle) { - std::cout << "Cycle: " << cycle << " of " << n_cycles << std::endl; + std::cout << "Cycle " << cycle << " of " << n_cycles << std::endl; triangulation.refine_global(1); setup_system();