ASPECT
isosurfaces.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2014 - 2021 by the authors of the ASPECT code.
3 
4  This file is part of ASPECT.
5 
6  ASPECT is free software; you can redistribute it and/or modify
7  it under the terms of the GNU General Public License as published by
8  the Free Software Foundation; either version 2, or (at your option)
9  any later version.
10 
11  ASPECT is distributed in the hope that it will be useful,
12  but WITHOUT ANY WARRANTY; without even the implied warranty of
13  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14  GNU General Public License for more details.
15 
16  You should have received a copy of the GNU General Public License
17  along with ASPECT; see the file LICENSE. If not see
18  <http://www.gnu.org/licenses/>.
19 */
20 
21 
22 
23 #ifndef _aspect_mesh_refinement_isosurfaces_h
24 #define _aspect_mesh_refinement_isosurfaces_h
25 
28 #include <aspect/utilities.h>
29 #include <deal.II/base/parsed_function.h>
30 
31 namespace aspect
32 {
33  namespace MeshRefinement
34  {
35  namespace internal
36  {
37  enum class PropertyType
38  {
41  };
42 
43  struct Property
44  {
45  public:
54  Property(const std::string &property_name,
55  const std::vector<std::string> &available_compositions);
56 
61 
67  unsigned int index;
68  };
69 
70  struct Isosurface
71  {
72  public:
81  bool are_all_values_in_range(const std::vector<double> &values) const;
82 
83  std::vector<double> min_values;
84  std::vector<double> max_values;
87  std::vector<Property> properties;
88  };
89 
90  }
91 
101  template <int dim>
102  class Isosurfaces : public Interface<dim>,
103  public SimulatorAccess<dim>
104  {
105  public:
110  void
111  update () override;
112 
118  void
119  tag_additional_cells () const override;
120 
124  static
125  void
126  declare_parameters (ParameterHandler &prm);
127 
131  void
132  parse_parameters (ParameterHandler &prm) override;
133 
134 
135  private:
139  std::vector<internal::Isosurface> isosurfaces;
140 
141  };
142  }
143 }
144 
145 #endif
std::vector< internal::Isosurface > isosurfaces
Definition: isosurfaces.h:139
void declare_parameters(ParameterHandler &prm)