ExaDG
Loading...
Searching...
No Matches
postprocessor.h
1/* ______________________________________________________________________
2 *
3 * ExaDG - High-Order Discontinuous Galerkin for the Exa-Scale
4 *
5 * Copyright (C) 2021 by the ExaDG authors
6 *
7 * This program is free software: you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License as published by
9 * the Free Software Foundation, either version 3 of the License, or
10 * (at your option) any later version.
11 *
12 * This program is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
16 *
17 * You should have received a copy of the GNU General Public License
18 * along with this program. If not, see <https://www.gnu.org/licenses/>.
19 * ______________________________________________________________________
20 */
21
22#ifndef EXADG_COMPRESSIBLE_NAVIER_STOKES_POSTPROCESSOR_POSTPROCESSOR_H_
23#define EXADG_COMPRESSIBLE_NAVIER_STOKES_POSTPROCESSOR_POSTPROCESSOR_H_
24
25// ExaDG
26#include <exadg/compressible_navier_stokes/postprocessor/output_generator.h>
27#include <exadg/compressible_navier_stokes/postprocessor/pointwise_output_generator.h>
28#include <exadg/compressible_navier_stokes/postprocessor/postprocessor_base.h>
29#include <exadg/postprocessor/error_calculation.h>
30#include <exadg/postprocessor/kinetic_energy_calculation.h>
31#include <exadg/postprocessor/kinetic_energy_spectrum.h>
32#include <exadg/postprocessor/lift_and_drag_calculation.h>
33#include <exadg/postprocessor/pressure_difference_calculation.h>
34
35namespace ExaDG
36{
37namespace CompNS
38{
39template<int dim>
41{
42 OutputData output_data;
43 PointwiseOutputData<dim> pointwise_output_data;
45 LiftAndDragData lift_and_drag_data;
46 PressureDifferenceData<dim> pressure_difference_data;
47 KineticEnergyData kinetic_energy_data;
48 KineticEnergySpectrumData kinetic_energy_spectrum_data;
49};
50
51template<int dim, typename Number>
52class PostProcessor : public PostProcessorBase<dim, Number>
53{
54public:
55 typedef dealii::LinearAlgebra::distributed::Vector<Number> VectorType;
56
57 PostProcessor(PostProcessorData<dim> const & postprocessor_data, MPI_Comm const & comm);
58
59 virtual ~PostProcessor();
60
61 void
62 setup(Operator<dim, Number> const & pde_operator) override;
63
64 void
65 do_postprocessing(VectorType const & solution,
66 double const time,
67 types::time_step const time_step_number) override;
68
69protected:
76
77private:
78 void
79 initialize_derived_fields();
80
81 void
82 invalidate_derived_fields();
83
84 MPI_Comm const mpi_comm;
85
87
88 dealii::ObserverPointer<Operator<dim, Number> const> navier_stokes_operator;
89
90 OutputGenerator<dim, Number> output_generator;
91 PointwiseOutputGenerator<dim, Number> pointwise_output_generator;
92 ErrorCalculator<dim, Number> error_calculator;
93 LiftAndDragCalculator<dim, Number> lift_and_drag_calculator;
94 PressureDifferenceCalculator<dim, Number> pressure_difference_calculator;
95 KineticEnergyCalculator<dim, Number> kinetic_energy_calculator;
96 KineticEnergySpectrumCalculator<dim, Number> kinetic_energy_spectrum_calculator;
97};
98
99} // namespace CompNS
100} // namespace ExaDG
101
102#endif /* EXADG_COMPRESSIBLE_NAVIER_STOKES_POSTPROCESSOR_POSTPROCESSOR_H_ */
Definition operator.h:48
Definition output_generator.h:89
Definition pointwise_output_generator.h:50
Definition postprocessor_base.h:60
Definition error_calculation.h:98
Definition kinetic_energy_calculation.h:81
Definition kinetic_energy_spectrum.h:113
Definition lift_and_drag_calculation.h:79
Definition pressure_difference_calculation.h:69
Definition solution_field.h:40
Definition driver.cpp:33
Definition output_generator.h:38
Definition pointwise_output_generator.h:37
Definition postprocessor.h:41
Definition error_calculation.h:39
Definition kinetic_energy_calculation.h:37
Definition kinetic_energy_spectrum.h:40
Definition lift_and_drag_calculation.h:35
Definition pressure_difference_calculation.h:40