|
| template<typename MaterialType > |
| void | setMaterial (const MaterialType &material, const std::string &domain_name) |
| | Set the thermal material model for a domain. More...
|
| |
| template<typename MaterialType > |
| void | setMaterialAndHeatSource (const MaterialType &material, const std::string &domain_name) |
| | Set thermal material and a coincident body heat source from a single callable. More...
|
| |
| template<typename HeatSourceType > |
| void | addHeatSource (const std::string &domain_name, HeatSourceType source_function) |
| | Add a body heat source that depends on all state and parameter fields. More...
|
| |
| template<typename HeatFluxType > |
| void | addHeatFlux (const std::string &boundary_name, HeatFluxType flux_function) |
| | Add a boundary heat flux that depends on all state and parameter fields. More...
|
| |
|
void | setTemperatureBC (const Domain &domain) |
| | Set zero-temperature Dirichlet BC.
|
| |
|
template<typename AppliedTemperatureFunction > |
| void | setTemperatureBC (const Domain &domain, AppliedTemperatureFunction f) |
| | Set temperature BC with a prescribed function.
|
| |
|
| SystemBase ()=default |
| | Construct an empty system shell.
|
| |
| | SystemBase (std::shared_ptr< FieldStore > fs, std::shared_ptr< SystemSolver > sol=nullptr, std::vector< std::shared_ptr< WeakForm >> wfs={}) |
| | Construct a system from a field store, solver, and weak forms. More...
|
| |
|
| SystemBase ()=default |
| | Construct an empty system shell.
|
| |
| | SystemBase (std::shared_ptr< FieldStore > fs, std::shared_ptr< SystemSolver > sol=nullptr, std::vector< std::shared_ptr< WeakForm >> wfs={}) |
| | Construct a system from a field store, solver, and weak forms. More...
|
| |
| virtual std::vector< FieldState > | solve (const TimeInfo &time_info) const |
| | Solve the system using the internal weak_forms and solver. More...
|
| |
| virtual std::vector< ReactionState > | computeReactions (const TimeInfo &time_info, const std::vector< FieldState > &states_for_reactions) const |
| | Compute reactions after solving the main state. More...
|
| |
template<int dim, int temp_order, typename TemperatureTimeRule = QuasiStaticFirstOrderTimeIntegrationRule, typename Coupling = std::tuple<>>
struct smith::ThermalSystem< dim, temp_order, TemperatureTimeRule, Coupling >
Container for a thermal system with configurable time integration.
Always uses a 2-state field layout (temperature_solve_state, temperature). Use QuasiStaticFirstOrderTimeIntegrationRule for steady-state problems, or BackwardEulerFirstOrderTimeIntegrationRule for transient problems.
- Template Parameters
-
| dim | Spatial dimension. |
| temp_order | Order of the temperature basis. |
| TemperatureTimeRule | Time integration rule type (must have num_states == 2). |
| Coupling | Tuple of coupling and parameter packs (default: none). Coupling fields occupy leading positions in the tail after the 2 time-rule state fields, before user parameter_space fields. |
Definition at line 43 of file thermal_system.hpp.
template<int dim, int temp_order, typename TemperatureTimeRule = QuasiStaticFirstOrderTimeIntegrationRule, typename Coupling = std::tuple<>>
template<typename HeatFluxType >
| void smith::ThermalSystem< dim, temp_order, TemperatureTimeRule, Coupling >::addHeatFlux |
( |
const std::string & |
boundary_name, |
|
|
HeatFluxType |
flux_function |
|
) |
| |
|
inline |
Add a boundary heat flux that depends on all state and parameter fields.
- Parameters
-
| boundary_name | The name of the boundary where the heat flux is applied. |
| flux_function | (t_info, X, n, T, params...) -> heat_flux. |
Definition at line 146 of file thermal_system.hpp.
template<int dim, int temp_order, typename TemperatureTimeRule = QuasiStaticFirstOrderTimeIntegrationRule, typename Coupling = std::tuple<>>
template<typename HeatSourceType >
| void smith::ThermalSystem< dim, temp_order, TemperatureTimeRule, Coupling >::addHeatSource |
( |
const std::string & |
domain_name, |
|
|
HeatSourceType |
source_function |
|
) |
| |
|
inline |
Add a body heat source that depends on all state and parameter fields.
- Parameters
-
| domain_name | The name of the domain where the heat source is applied. |
| source_function | (t_info, X, T, params...) -> heat_source. |
Definition at line 126 of file thermal_system.hpp.
template<int dim, int temp_order, typename TemperatureTimeRule = QuasiStaticFirstOrderTimeIntegrationRule, typename Coupling = std::tuple<>>
template<typename MaterialType >
| void smith::ThermalSystem< dim, temp_order, TemperatureTimeRule, Coupling >::setMaterial |
( |
const MaterialType & |
material, |
|
|
const std::string & |
domain_name |
|
) |
| |
|
inline |
Set the thermal material model for a domain.
Material is called as material(t_info, temperature, grad_temperature, params...) and must return smith::tuple{heat_capacity, heat_flux}. Consistent with heat_transfer.hpp convention.
The system forms the residual as: heat_capacity * dT/dt for the source term, and -heat_flux for the flux term.
- Template Parameters
-
| MaterialType | The thermal material type. |
- Parameters
-
| material | The material model instance. |
| domain_name | The name of the domain to apply the material to. |
Definition at line 71 of file thermal_system.hpp.
template<int dim, int temp_order, typename TemperatureTimeRule = QuasiStaticFirstOrderTimeIntegrationRule, typename Coupling = std::tuple<>>
template<typename MaterialType >
| void smith::ThermalSystem< dim, temp_order, TemperatureTimeRule, Coupling >::setMaterialAndHeatSource |
( |
const MaterialType & |
material, |
|
|
const std::string & |
domain_name |
|
) |
| |
|
inline |
Set thermal material and a coincident body heat source from a single callable.
The callable is invoked once per quadrature point and must return smith::tuple{heat_capacity, heat_flux, heat_source}. Used by coupled physics (e.g. thermo-mechanics) where one material evaluation produces all three contributions and we want to avoid re-evaluating the material for each piece.
Residual contribution: (heat_capacity * dT/dt - heat_source, -heat_flux).
- Template Parameters
-
| MaterialType | The thermal material type. |
- Parameters
-
| material | The material model instance returning {C_v, q, s}. |
| domain_name | The name of the domain to apply the material to. |
Definition at line 103 of file thermal_system.hpp.
template<int dim, int temp_order, typename TemperatureTimeRule = QuasiStaticFirstOrderTimeIntegrationRule, typename Coupling = std::tuple<>>
| smith::SystemBase::SystemBase |
|
inlineexplicit |
Construct a system from a field store, solver, and weak forms.
- Parameters
-
| fs | Field store shared by all weak forms. |
| sol | Solver used for solve. |
| wfs | Weak forms owned by this system. |
Definition at line 76 of file system_base.hpp.