ASPECT
stokes_residual.h
Go to the documentation of this file.
1 // ------------------------------------------------------
2 //
3 // SPDX-License-Identifier: GPL-2.0-or-later
4 //
5 // SPDX-FileCopyrightText: Copyright (C) 2015-2026 by the ASPECT authors.
6 //
7 // This file is part of ASPECT.
8 //
9 // Detailed license information governing the source code and
10 // contributions can be found in the folder LICENSES and in
11 // LICENSE and CONTRIBUTING.md at the top level directory.
12 //
13 // ------------------------------------------------------
14 
15 
16 #ifndef _aspect_postprocess_stokes_residual_h
17 #define _aspect_postprocess_stokes_residual_h
18 
21 
24 
25 namespace aspect
26 {
27  namespace Postprocess
28  {
29 
35  template <int dim>
36  class StokesResidual : public Interface<dim>, public ::aspect::SimulatorAccess<dim>
37  {
38  public:
42  StokesResidual ();
43 
47  void initialize() override;
48 
52  std::pair<std::string,std::string>
53  execute (TableHandler &statistics) override;
54 
58  void save (std::map<std::string, std::string> &status_strings) const override;
59 
63  void load (const std::map<std::string, std::string> &status_strings) override;
64 
69  template <class Archive>
70  void serialize (Archive &ar, const unsigned int version);
71 
72  private:
76  struct DataPoint
77  {
78  double time;
79  unsigned int solve_index;
80  std::vector<double> values;
81 
82  template <class Archive>
83  void serialize (Archive &ar, const unsigned int version);
84  };
85 
89  void stokes_solver_callback (const SolverControl &solver_control_cheap,
90  const SolverControl &solver_control_expensive);
91 
95  std::vector<DataPoint> entries;
96 
97  };
98  }
99 }
100 
101 
102 #endif
void serialize(Archive &ar, const unsigned int version)
void stokes_solver_callback(const SolverControl &solver_control_cheap, const SolverControl &solver_control_expensive)
std::vector< DataPoint > entries
void serialize(Archive &ar, const unsigned int version)
std::pair< std::string, std::string > execute(TableHandler &statistics) override
void save(std::map< std::string, std::string > &status_strings) const override
void load(const std::map< std::string, std::string > &status_strings) override