From ac7940ad652c348cfd766ce6f46f2ee1751f1902 Mon Sep 17 00:00:00 2001 From: Wolfgang Bangerth Date: Tue, 7 Nov 2017 20:56:39 -0700 Subject: [PATCH] Output both real and imaginary parts of the solution. --- source/numerics/data_out.cc | 29 ++++++++++++++++++++++++++++- 1 file changed, 28 insertions(+), 1 deletion(-) diff --git a/source/numerics/data_out.cc b/source/numerics/data_out.cc index b485c6936f..f8a3a827ae 100644 --- a/source/numerics/data_out.cc +++ b/source/numerics/data_out.cc @@ -226,23 +226,50 @@ build_one_patch // reasons. if (n_components == 1) { + // first output the real part of the solution vector this->dof_data[dataset]->get_function_values (this_fe_patch_values, internal::DataOut::ComponentExtractor::real_part, scratch_data.patch_values_scalar.solution_values); for (unsigned int q=0; qdof_data[dataset]->is_complex_valued() == true) + { + this->dof_data[dataset]->get_function_values (this_fe_patch_values, + internal::DataOut::ComponentExtractor::imaginary_part, + scratch_data.patch_values_scalar.solution_values); + for (unsigned int q=0; qdof_data[dataset]->is_complex_valued() ? 2 : 1); this->dof_data[dataset]->get_function_values (this_fe_patch_values, internal::DataOut::ComponentExtractor::real_part, scratch_data.patch_values_system.solution_values); for (unsigned int component=0; componentdof_data[dataset]->is_complex_valued() == true) + { + this->dof_data[dataset]->get_function_values (this_fe_patch_values, + internal::DataOut::ComponentExtractor::imaginary_part, + scratch_data.patch_values_system.solution_values); + for (unsigned int component=0; component