ASPECT
elasticity.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2019 - 2022 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 #ifndef _aspect_material_model_rheology_elasticity_h
22 #define _aspect_material_model_rheology_elasticity_h
23 
24 #include <aspect/global.h>
27 
28 #include <deal.II/matrix_free/fe_point_evaluation.h>
29 
30 namespace aspect
31 {
32  namespace MaterialModel
33  {
34  using namespace dealii;
35 
41  template <int dim>
43  {
44  public:
45  explicit ElasticAdditionalOutputs(const unsigned int n_points);
46 
47  std::vector<double> get_nth_output(const unsigned int idx) const override;
48 
54  std::vector<double> elastic_shear_moduli;
55  };
56 
57 
58 
59  namespace Rheology
60  {
61  template <int dim>
63  {
64  public:
68  static
69  void
70  declare_parameters (ParameterHandler &prm);
71 
75  void
76  parse_parameters (ParameterHandler &prm);
77 
82  void
83  create_elastic_outputs (MaterialModel::MaterialModelOutputs<dim> &out) const;
84 
91  void
92  fill_elastic_force_outputs (const MaterialModel::MaterialModelInputs<dim> &in,
93  const std::vector<double> &average_elastic_shear_moduli,
95 
103  void
104  fill_reaction_outputs (const MaterialModel::MaterialModelInputs<dim> &in,
105  const std::vector<double> &average_elastic_shear_moduli,
107 
112  const std::vector<double> &
113  get_elastic_shear_moduli () const;
114 
119  double
120  calculate_elastic_viscosity (const double shear_modulus) const;
121 
126  double
127  calculate_viscoelastic_viscosity (const double viscosity,
128  const double shear_modulus) const;
129 
134  double
135  calculate_viscoelastic_strain_rate (const SymmetricTensor<2,dim> &strain_rate,
136  const SymmetricTensor<2,dim> &stress,
137  const double shear_modulus) const;
138 
142  double
143  elastic_timestep () const;
144 
145  private:
151 
155  std::vector<double> elastic_shear_moduli;
156 
164 
169 
178 
186  mutable std::unique_ptr<FEPointEvaluation<dim, dim>> evaluator;
187  };
188  }
189  }
190 }
191 #endif
std::vector< double > elastic_shear_moduli
Definition: elasticity.h:155
void declare_parameters(ParameterHandler &prm)
std::unique_ptr< FEPointEvaluation< dim, dim > > evaluator
Definition: elasticity.h:186
Definition: compat.h:88