20 #include "pism/rheology/GPBLD.hh"
21 #include "pism/util/ConfigInterface.hh"
33 m_name =
"Glen-Paterson-Budd-Lliboutry-Duval";
35 m_T_0 = config.
get_number(
"constants.fresh_water.melting_point_temperature");
50 const double E_s =
m_EC->enthalpy_cts(pressure);
52 double T_pa =
m_EC->pressure_adjusted_temperature(enthalpy, pressure);
55 double omega =
m_EC->water_fraction(enthalpy, pressure);
64 const double *pressure,
const double *grainsize,
65 unsigned int n,
double *result)
const {
68 for (
unsigned int k = 0;
k <
n; ++
k) {
69 result[
k] = this->
softness(enthalpy[
k], pressure[
k]) * (stress[
k] * stress[
k]);
75 for (
unsigned int k = 0;
k <
n; ++
k) {
76 result[
k] = this->
flow(stress[
k], enthalpy[
k], pressure[
k], grainsize[
k]);
double get_number(const std::string &name, UseFlag flag=REMEMBER_THIS_USE) const
A class for storing and accessing PISM configuration flags and parameters.
std::shared_ptr< EnthalpyConverter > Ptr
double softness_paterson_budd(double T_pa) const
Return the softness parameter A(T) for a given temperature T.
double softness(double E, double p) const
double flow(double stress, double enthalpy, double pressure, double grain_size) const
The flow law itself.
double m_n
power law exponent
EnthalpyConverter::Ptr m_EC
double m_water_frac_observed_limit
double softness_impl(double enthalpy, double pressure) const
The softness factor in the Glen-Paterson-Budd-Lliboutry-Duval flow law. For constitutive law form.
void flow_n_impl(const double *stress, const double *enthalpy, const double *pressure, const double *grainsize, unsigned int n, double *result) const
double m_water_frac_coeff
GPBLD(const std::string &prefix, const Config &config, EnthalpyConverter::Ptr EC)
double min(const array::Scalar &input)
Finds minimum over all the values in an array::Scalar object. Ignores ghosts.