From 369766137f5b4d32a93c6379d87376ee61261ff5 Mon Sep 17 00:00:00 2001 From: Timo Heister Date: Thu, 10 Dec 2020 18:34:59 -0500 Subject: [PATCH] step-47: misc cleanup - line up numbers in std::cout messages - minor formatting --- examples/step-47/step-47.cc | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) 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(); -- 2.39.5