ryujin 2.5.0 revision c64172211cf21344cb9b9b0f3a1266aa6400d392
Loading...
Searching...
No Matches
error_evaluation.h
Go to the documentation of this file.
1//
2// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
3// Copyright (C) 2026 by the ryujin authors
4//
5
6#pragma once
7
8#include <ryujin/base/compile_time_options.h>
16
17#include <deal.II/base/parameter_acceptor.h>
18
19#include <string>
20#include <vector>
21
22namespace ryujin
23{
46 template <int dim, typename Number = double>
47 class ErrorEvaluation final : public dealii::ParameterAcceptor,
48 public Interface::Task<Number>
49 {
50 public:
55
60 const std::string &subsection = "/ErrorEvaluation");
61
63
67
76 void initialize(TaskContext<Number> &context) override;
77
82 void execute(TaskContext<Number> &context) override;
83
87 void finalize(TaskContext<Number> &context) override;
88
90
91 private:
96
97 std::vector<std::string> error_quantities_;
98
99 bool error_normalize_;
100
101 std::vector<std::string> error_norms_;
102
104
108
109 Trigger<Number> trigger_;
110
111 const Interface::Simulation<dim, Number> &simulation_;
112 const MPIEnsemble &mpi_ensemble_;
113
114 dealii::ObserverPointer<const OfflineData<dim, Number>> offline_data_;
115
116 const Interface::Postprocessor<dim, Number> &postprocessor_;
117
119
120 std::string base_name_;
121
123
127
138 std::vector<Number> compute(const StateVector<Number> &state_vector,
139 const StateVector<Number> &analytic) const;
140
141 std::string description() const;
142
144 };
145
146} // namespace ryujin
void finalize(TaskContext< Number > &context) override
void initialize(TaskContext< Number > &context) override
ErrorEvaluation(const Interface::Simulation< dim, Number > &simulation, const std::string &subsection="/ErrorEvaluation")
void execute(TaskContext< Number > &context) override