fixed total time issue

This commit is contained in:
Vasco C. B. Ferreira
2026-07-25 17:57:59 +02:00
parent 10a776e2a9
commit 65de1cd0aa
2 changed files with 4 additions and 1 deletions
+2
View File
@@ -375,7 +375,9 @@ template <int dim> void PoissonProblem<dim>::assemble_system() {
Assert(rhs_function, Assert(rhs_function,
ExcMessage("Poisson RHS function has not been initialized.")); ExcMessage("Poisson RHS function has not been initialized."));
std::cout << "Start of full rho eval..." << "\n";
std::vector<double> all_rho = rhs_function(all_q_points); std::vector<double> all_rho = rhs_function(all_q_points);
std::cout << "End of full rho eval..." << "\n";
Assert(all_rho.size() == all_q_points.size(), Assert(all_rho.size() == all_q_points.size(),
ExcMessage("rhs_function returned wrong size")); ExcMessage("rhs_function returned wrong size"));
+2 -1
View File
@@ -214,6 +214,7 @@ void NuFISolver::run() {
std::ofstream time_file("results/simulation_time.dat"); std::ofstream time_file("results/simulation_time.dat");
double total_time = 0; double total_time = 0;
stopwatch<double> total_timer;
time_file << "it " time_file << "it "
<< "step_time " << "step_time "
@@ -322,7 +323,7 @@ void NuFISolver::run() {
plot_time = timer.elapsed() - plot_start; plot_time = timer.elapsed() - plot_start;
std::cout << "Results saved in " << plot_start << "[s]" << "\n"; std::cout << "Results saved in " << plot_start << "[s]" << "\n";
} }
total_time = timer.elapsed(); total_time = total_timer.elapsed();
std::cout << "Time since start = " << total_time << "\n\n"; std::cout << "Time since start = " << total_time << "\n\n";
time_file << it << " " << step_time << " " << total_time << " " time_file << it << " " << step_time << " " << total_time << " "