ASPECT
sphere.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) 2014-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 #ifndef _aspect_geometry_model_sphere_h
15 #define _aspect_geometry_model_sphere_h
16 
19 
20 namespace aspect
21 {
22  namespace GeometryModel
23  {
24  template <int dim>
25  class Sphere : public Interface<dim>, public SimulatorAccess<dim>
26  {
27  public:
31  Sphere() = default;
32 
36  void create_coarse_mesh (parallel::distributed::Triangulation<dim> &coarse_grid) const override;
37 
45  double length_scale () const override;
46 
60  double depth(const Point<dim> &position) const override;
61 
66  double height_above_reference_surface(const Point<dim> &position) const override;
67 
71  Point<dim> representative_point(const double depth) const override;
72 
76  double maximal_depth() const override;
77 
85  std::set<types::boundary_id>
86  get_used_boundary_indicators () const override;
87 
93  std::map<std::string,types::boundary_id>
94  get_symbolic_boundary_names_map () const override;
95 
101  bool
102  has_curved_elements() const override;
103 
109 
115  bool
116  point_is_in_domain(const Point<dim> &point) const override;
117 
123  std::array<double,dim> cartesian_to_natural_coordinates(const Point<dim> &position) const override;
124 
130  Point<dim> natural_to_cartesian_coordinates(const std::array<double,dim> &position) const override;
131 
132 
133  static
134  void
136 
137  void
138  parse_parameters (ParameterHandler &prm) override;
139 
143  double
144  radius () const;
145 
146  private:
152  double R;
153  };
154  }
155 }
156 
157 
158 #endif
void parse_parameters(ParameterHandler &prm) override
double height_above_reference_surface(const Point< dim > &position) const override
std::set< types::boundary_id > get_used_boundary_indicators() const override
bool has_curved_elements() const override
double maximal_depth() const override
static void declare_parameters(ParameterHandler &prm)
std::map< std::string, types::boundary_id > get_symbolic_boundary_names_map() const override
double depth(const Point< dim > &position) const override
aspect::Utilities::Coordinates::CoordinateSystem natural_coordinate_system() const override
Point< dim > representative_point(const double depth) const override
double length_scale() const override
Point< dim > natural_to_cartesian_coordinates(const std::array< double, dim > &position) const override
std::array< double, dim > cartesian_to_natural_coordinates(const Point< dim > &position) const override
void create_coarse_mesh(parallel::distributed::Triangulation< dim > &coarse_grid) const override
bool point_is_in_domain(const Point< dim > &point) const override