34 using namespace Utilities;
38 using namespace FeatureUtilities;
39 namespace ContinentalPlateModels
45 top_temperature(NaN::
DSNAN),
46 top_heat_flux(NaN::
DSNAN),
47 thermal_conductivity(NaN::
DSNAN),
48 heat_production_per_unit_volume(NaN::
DSNAN),
49 min_depth(NaN::
DSNAN),
50 max_depth(NaN::
DSNAN),
54 this->
name =
"chapman";
65 "Continental geotherm using the steady-state 1-D heat conduction equation from Chapman (1986).");
68 "The temperature at the top surface in K of this feature." 69 "If the value is below zero, then an adiabatic temperature is used.");
72 "The heat flux at the top surface in W m^(-2) of this feature." 73 "The default value is 0.055.");
76 "The thermal conductivity in W m^(-1) K^(-1) of this feature." 77 "The default value is 2.5.");
80 "The heat generation per unit volume in W m^(-3) of this feature." 81 "The default value is 1e-6.");
84 "The depth in m from which the composition of this feature is present.");
87 "The depth in m to which the composition of this feature is present.");
98 WBAssert(max_depth >= min_depth,
"max depth needs to be larger or equal to min depth.");
104 WBAssert(!std::isnan(top_temperature),
"Top surface temperature is not a number: " << top_temperature
105 <<
", based on a temperature model with the name " << this->
name);
113 const double gravity_norm,
115 const double feature_min_depth,
118 if (depth <= max_depth && depth >=
min_depth)
122 if (depth <= max_depth_local && depth >= min_depth_local)
124 const double min_depth_local_local = std::max(feature_min_depth, min_depth_local);
129 if (top_temperature_local < 0)
133 this->world->specific_heat) * min_depth_local_local);
140 WBAssert(!std::isnan(new_temperature),
"Temperature is not a number: " << new_temperature
141 <<
", based on a temperature model with the name " << this->
name);
142 WBAssert(std::isfinite(new_temperature),
"Temperature is not a finite: " << new_temperature
143 <<
", based on a temperature model with the name " << this->
name 144 <<
", top_temperature_local = " << top_temperature_local
145 <<
", depth = " << depth
146 <<
", min_depth_local = " << min_depth_local
149 <<
", min_depth_local_local =" << min_depth_local_local);
double thermal_conductivity
Objects::Surface min_depth_surface
~Chapman() override final
double potential_mantle_temperature
Operations string_operations_to_enum(const std::string &operation)
#define WBAssert(condition, message)
static void declare_entries(Parameters &prm, const std::string &parent_name="")
void parse_entries(Parameters &prm, const std::vector< Point< 2 >> &coordinates) override final
double get_temperature(const Point< 3 > &position, const Objects::NaturalCoordinate &position_in_natural_coordinates, const double depth, const double gravity, double temperature, const double feature_min_depth, const double feature_max_depth) const override final
Point< 2 > get_surface_point() const
double heat_production_per_unit_volume
SurfaceValueInfo local_value(const Point< 2 > &check_point) const
double thermal_expansion_coefficient
double apply_operation(const Operations operation, const double old_value, const double new_value)
void declare_entry(const std::string &name, const Types::Interface &type, const std::string &documentation)
T get(const std::string &name)
Objects::Surface max_depth_surface
#define WB_REGISTER_FEATURE_CONTINENTAL_PLATE_TEMPERATURE_MODEL(classname, name)
WorldBuilder::World * world