29 : density_(density), specific_heat_capacity_(specific_heat_capacity), conductivity_(conductivity)
31 SLIC_ERROR_ROOT_IF(conductivity_ < 0.0,
32 "Conductivity must be positive in the linear isotropic conductor material model.");
34 SLIC_ERROR_ROOT_IF(density_ < 0.0,
"Density must be positive in the linear isotropic conductor material model.");
36 SLIC_ERROR_ROOT_IF(specific_heat_capacity_ < 0.0,
37 "Specific heat capacity must be positive in the linear isotropic conductor material model.");
50 template <
typename T1,
typename T2,
typename T3>
52 const T3& temperature_gradient)
const
54 return serac::tuple{density_ * specific_heat_capacity_, -1.0 * conductivity_ * temperature_gradient};
62 double specific_heat_capacity_;
79 double reference_conductivity = 1.0,
80 double d_conductivity_d_temperature = 0.0)
82 specific_heat_capacity_(specific_heat_capacity),
83 reference_conductivity_(reference_conductivity),
84 d_conductivity_d_temperature_(d_conductivity_d_temperature)
86 SLIC_ERROR_ROOT_IF(density_ < 0.0,
"Density must be positive in the linear isotropic conductor material model.");
87 SLIC_ERROR_ROOT_IF(specific_heat_capacity_ < 0.0,
88 "Specific heat capacity must be positive in the linear isotropic conductor material model.");
101 template <
typename T1,
typename T2,
typename T3>
104 const auto currentConductivity = reference_conductivity_ + d_conductivity_d_temperature_ * temperature;
107 "Conductivity in the IsotropicConductorWithLinearConductivityVsTemperature model has gone negative.");
108 return serac::tuple{density_ * specific_heat_capacity_, -1.0 * currentConductivity * temperature_gradient};
116 double specific_heat_capacity_;
119 double reference_conductivity_;
122 double d_conductivity_d_temperature_;
141 : density_(density), specific_heat_capacity_(specific_heat_capacity), conductivity_(conductivity)
143 SLIC_ERROR_ROOT_IF(density_ < 0.0,
"Density must be positive in the linear conductor material model.");
145 SLIC_ERROR_ROOT_IF(specific_heat_capacity_ < 0.0,
146 "Specific heat capacity must be positive in the linear conductor material model.");
149 "Conductivity tensor must be symmetric and positive definite.");
162 template <
typename T1,
typename T2,
typename T3>
164 const T3& temperature_gradient)
const
166 return serac::tuple{density_ * specific_heat_capacity_, -1.0 * conductivity_ * temperature_gradient};
174 double specific_heat_capacity_;
194 template <
typename T1,
typename T2,
typename T3>
216 template <
typename T1,
typename T2,
typename T3>
#define SERAC_HOST_DEVICE
Macro that evaluates to __host__ __device__ when compiling with nvcc and does nothing on a host compi...
Implementation of the quadrature-function-based functional enabling rapid development of FEM formulat...
HeatTransfer helper structs.
SERAC_HOST_DEVICE bool is_symmetric_and_positive_definite(tensor< double, 2, 2 > A)
Return whether a matrix is symmetric and positive definite This check uses Sylvester's criterion,...
constexpr SERAC_HOST_DEVICE auto get_value(const T &arg)
return the "value" part from a given type. For non-dual types, this is just the identity function
Constant thermal flux boundary model.
double flux_
The constant flux applied to the boundary.
SERAC_HOST_DEVICE auto operator()(const T1 &, const T2 &, const double, const T3 &) const
Evaluation function for the thermal flux on a boundary.
Constant thermal source model.
double source_
The constant source.
SERAC_HOST_DEVICE auto operator()(const T1 &, const double, const T2 &, const T3 &) const
Evaluation function for the constant thermal source model.
Nonlinear isotropic heat transfer material model.
SERAC_HOST_DEVICE auto operator()(const T1 &, const T2 &temperature, const T3 &temperature_gradient) const
Material response call for a linear isotropic material with linear conductivity vs temperature.
IsotropicConductorWithLinearConductivityVsTemperature(double density=1.0, double specific_heat_capacity=1.0, double reference_conductivity=1.0, double d_conductivity_d_temperature=0.0)
Construct a Isotropic Conductor with Conductivity linear with Temparture object.
Linear anisotropic thermal material model.
SERAC_HOST_DEVICE auto operator()(const T1 &, const T2 &, const T3 &temperature_gradient) const
Material response call for a linear anisotropic material.
LinearConductor(double density=1.0, double specific_heat_capacity=1.0, tensor< double, dim, dim > conductivity=Identity< dim >())
Construct a new Linear Isotropic Conductor object.
Linear isotropic heat transfer material model.
LinearIsotropicConductor(double density=1.0, double specific_heat_capacity=1.0, double conductivity=1.0)
Construct a new Linear Isotropic Conductor object.
SERAC_HOST_DEVICE auto operator()(const T1 &, const T2 &, const T3 &temperature_gradient) const
Material response call for a linear isotropic material.
This is a class that mimics most of std::tuple's interface, except that it is usable in CUDA kernels ...