ASPECT
diffusion_creep.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2019 - 2024 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_diffusion_creep_h
22 #define _aspect_material_model_rheology_diffusion_creep_h
23 
24 #include <aspect/global.h>
28 
29 namespace aspect
30 {
31  namespace MaterialModel
32  {
33  namespace Rheology
34  {
39  {
44  double prefactor;
49 
54  };
55 
56  template <int dim>
58  {
59  public:
64 
68  static
69  void
70  declare_parameters (ParameterHandler &prm);
71 
79  void
80  parse_parameters (ParameterHandler &prm,
81  const std::unique_ptr<std::vector<unsigned int>> &expected_n_phases_per_composition = nullptr);
82 
83 
92  compute_creep_parameters (const unsigned int composition,
93  const std::vector<double> &phase_function_values = std::vector<double>(),
94  const std::vector<unsigned int> &n_phase_transitions_per_composition = std::vector<unsigned int>()) const;
95 
104  double
105  compute_viscosity (const double pressure,
106  const double temperature,
107  const unsigned int composition,
108  const std::vector<double> &phase_function_values = std::vector<double>(),
109  const std::vector<unsigned int> &n_phase_transitions_per_composition = std::vector<unsigned int>()) const;
110 
118  double
119  compute_viscosity (const double pressure,
120  const double temperature,
121  const double grain_size,
122  const unsigned int composition,
123  const std::vector<double> &phase_function_values = std::vector<double>(),
124  const std::vector<unsigned int> &n_phase_transitions_per_composition = std::vector<unsigned int>()) const;
125 
131  std::pair<double, double>
132  compute_strain_rate_and_derivative (const double stress,
133  const double pressure,
134  const double temperature,
135  const DiffusionCreepParameters creep_parameters) const;
136 
141  std::pair<double, double>
142  compute_strain_rate_and_derivative (const double stress,
143  const double pressure,
144  const double temperature,
145  const double grain_size,
146  const DiffusionCreepParameters creep_parameters) const;
147 
153  std::pair<double, double>
154  compute_log_strain_rate_and_derivative (const double log_stress,
155  const double pressure,
156  const double temperature,
157  const DiffusionCreepParameters creep_parameters) const;
158 
164  std::pair<double, double>
165  compute_log_strain_rate_and_derivative (const double log_stress,
166  const double pressure,
167  const double temperature,
168  const double grain_size,
169  const DiffusionCreepParameters creep_parameters) const;
170 
171  private:
172 
176  std::vector<double> prefactors_diffusion;
177 
181  std::vector<double> stress_exponents_diffusion;
182 
186  std::vector<double> grain_size_exponents_diffusion;
187 
191  std::vector<double> activation_energies_diffusion;
192 
196  std::vector<double> activation_volumes_diffusion;
197 
204  };
205  }
206  }
207 }
208 #endif
void declare_parameters(ParameterHandler &prm)
Definition: compat.h:59