Class Dune::XT::Common::ConvergenceStudy¶
-
class Dune::XT::Common::ConvergenceStudy¶
Base class for convergence studies that refine a discretization and report experimental orders of convergence.
-
virtual size_t Dune::XT::Common::ConvergenceStudy::num_refinements() const = 0¶
The number of refinements to carry out.
discretiztion_info() and compute() will be called for 0 < = refinement_level < = num_refinements.
-
int Dune::XT::Common::ConvergenceStudy::targets() const¶
The identifiers of the targets with respect to which the EOCs will be computed.
Note
This must not be empty!
Note
Target ids are shortened to length 4 in EOC column headers. This is usually something like “h” or “dt”.
-
int Dune::XT::Common::ConvergenceStudy::norms() const¶
Error norms of which the EOCs will be computed.
-
int Dune::XT::Common::ConvergenceStudy::estimates() const¶
A posteriori error estimates (and corresponding norms) of which the EOCs will be computed.
-
int Dune::XT::Common::ConvergenceStudy::quantities() const¶
Quantities to be displayed.
-
virtual std::string Dune::XT::Common::ConvergenceStudy::discretization_info_title() const = 0¶
Header to be printed in the column which displays discretization_info().
-
virtual std::string Dune::XT::Common::ConvergenceStudy::discretization_info(const size_t refinement_level) = 0¶
Statistics about the discretization, in addition to targets().
This is usually somthing like the number of DoFs or grid elements
Note
This is the first called on a new level and can be used to set the internal current refinemen_level.
-
int Dune::XT::Common::ConvergenceStudy::compute(const size_t refinement_level, const int &actual_norms, const int &actual_estimates, const int &actual_quantities)¶
Carries out the actual computations on this refinement_level. This usually solves the problem and computes various statistics, which are expected to be of the form
-
virtual double Dune::XT::Common::ConvergenceStudy::expected_rate(const std::string &type, const std::string &id) const¶
The expected rates of convergence, merely to be used to color the EOCs.
-
int Dune::XT::Common::ConvergenceStudy::filter(const int &vec, const int &only_these) const¶
No documentation provided.
-
std::string Dune::XT::Common::ConvergenceStudy::lfill(const std::string &id, const size_t len) const¶
No documentation provided.
-
std::string Dune::XT::Common::ConvergenceStudy::cfill(const std::string &id, const size_t len) const¶
No documentation provided.
-
double Dune::XT::Common::ConvergenceStudy::extract(const int &level_data, const std::string &type, const std::string &id) const¶
-
double Dune::XT::Common::ConvergenceStudy::extract(const int &data, const size_t level, const std::string &type, const std::string &id) const¶
No documentation provided.
-
void Dune::XT::Common::ConvergenceStudy::print_eoc(std::ostream &out, const size_t len, const int &data, const size_t level, const std::string &type, const std::string &id, const std::string &target_id) const¶
No documentation provided.
-
int Dune::XT::Common::ConvergenceStudy::run(const int &only_these = {}, std::ostream &out = std::cout)¶
Runs the study and displays a table with all targets, norms, estimates and quantities given by the study (if only_these is empty) or only those which are contained in only_these (else).
:returns: data with data[foo][bar][level] where 0 <= level <= num_refinements(), “foo” is one of {“target”, “norm”, “estimate”, “quantity”} and bar is one of targets(), norms(), estimates() or quantities() (intersected with only_these), respectively.
-
virtual Dune::XT::Common::ConvergenceStudy::~ConvergenceStudy() = default¶
No documentation provided.