ASPECT
sphere.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2014 - 2023 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 #ifndef _aspect_geometry_model_sphere_h
21 #define _aspect_geometry_model_sphere_h
22 
25 
26 namespace aspect
27 {
28  namespace GeometryModel
29  {
30  using namespace dealii;
31 
32  template <int dim>
33  class Sphere : public Interface<dim>, public SimulatorAccess<dim>
34  {
35  public:
39  Sphere() = default;
40 
44  void create_coarse_mesh (parallel::distributed::Triangulation<dim> &coarse_grid) const override;
45 
53  double length_scale () const override;
54 
68  double depth(const Point<dim> &position) const override;
69 
74  double height_above_reference_surface(const Point<dim> &position) const override;
75 
79  Point<dim> representative_point(const double depth) const override;
80 
84  double maximal_depth() const override;
85 
93  std::set<types::boundary_id>
94  get_used_boundary_indicators () const override;
95 
101  std::map<std::string,types::boundary_id>
102  get_symbolic_boundary_names_map () const override;
103 
109  bool
110  has_curved_elements() const override;
111 
116  aspect::Utilities::Coordinates::CoordinateSystem natural_coordinate_system() const override;
117 
123  bool
124  point_is_in_domain(const Point<dim> &point) const override;
125 
131  std::array<double,dim> cartesian_to_natural_coordinates(const Point<dim> &position) const override;
132 
138  Point<dim> natural_to_cartesian_coordinates(const std::array<double,dim> &position) const override;
139 
140 
141  static
142  void
143  declare_parameters (ParameterHandler &prm);
144 
145  void
146  parse_parameters (ParameterHandler &prm) override;
147 
151  double
152  radius () const;
153 
154  private:
158  double R;
159  };
160  }
161 }
162 
163 
164 #endif
void declare_parameters(ParameterHandler &prm)
Definition: compat.h:59
Definition: compat.h:42