Flow123d  release_2.1.0-84-g6a13a75
heat_model.cc
Go to the documentation of this file.
1 /*!
2  *
3  * Copyright (C) 2015 Technical University of Liberec. All rights reserved.
4  *
5  * This program is free software; you can redistribute it and/or modify it under
6  * the terms of the GNU General Public License version 3 as published by the
7  * Free Software Foundation. (http://www.gnu.org/licenses/gpl-3.0.en.html)
8  *
9  * This program is distributed in the hope that it will be useful, but WITHOUT
10  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
11  * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
12  *
13  *
14  * @file heat_model.cc
15  * @brief Discontinuous Galerkin method for equation of transport with dispersion.
16  * @author Jan Stebel
17  */
18 
19 #include "input/input_type.hh"
20 #include "mesh/mesh.h"
21 #include "mesh/accessors.hh"
22 //#include "transport/transport_operator_splitting.hh"
23 #include "heat_model.hh"
24 #include "fields/unit_si.hh"
25 #include "coupling/balance.hh"
26 
27 
28 
29 using namespace std;
30 using namespace Input::Type;
31 
32 
33 
34 
35 
36 
37 
38 
40  return Selection("Heat_BC_Type", "Types of boundary conditions for heat transfer model.")
41  .add_value(bc_inflow, "inflow",
42  "Default heat transfer boundary condition.\n"
43  "On water inflow (($(q_w \\le 0)$)), total energy flux is given by the reference temperature 'bc_temperature'. "
44  "On water outflow we prescribe zero diffusive flux, "
45  "i.e. the energy flows out only due to advection.")
46  .add_value(bc_dirichlet, "dirichlet",
47  "Dirichlet boundary condition (($T = T_D $)).\n"
48  "The prescribed temperature (($T_D$)) is specified by the field 'bc_temperature'.")
49  .add_value(bc_total_flux, "total_flux",
50  "Total energy flux boundary condition.\n"
51  "The prescribed incoming total flux can have the general form (($\\delta(f_N+\\sigma_R(T_R-T) )$)), "
52  "where the absolute flux (($f_N$)) is specified by the field 'bc_flux', "
53  "the transition parameter (($\\sigma_R$)) by 'bc_robin_sigma', "
54  "and the reference temperature (($T_R$)) by 'bc_temperature'.")
55  .add_value(bc_diffusive_flux, "diffusive_flux",
56  "Diffusive flux boundary condition.\n"
57  "The prescribed incoming energy flux due to diffusion can have the general form (($\\delta(f_N+\\sigma_R(T_R-T) )$)), "
58  "where the absolute flux (($f_N$)) is specified by the field 'bc_flux', "
59  "the transition parameter (($\\sigma_R$)) by 'bc_robin_sigma', "
60  "and the reference temperature (($T_R$)) by 'bc_temperature'.")
61  .close();
62 }
63 
64 
66 {
67  *this+=bc_type
68  .name("bc_type")
69  .description(
70  "Type of boundary condition.")
71  .units( UnitSI::dimensionless() )
72  .input_default("\"inflow\"")
73  .input_selection( get_bc_type_selection() )
75  *this+=bc_dirichlet_value
76  .name("bc_temperature")
77  .description("Boundary value of temperature.")
78  .units( UnitSI().K() )
79  .input_default("0.0")
80  .flags_add(in_rhs);
81  *this+=bc_flux
82  .disable_where(bc_type, { bc_dirichlet, bc_inflow })
83  .name("bc_flux")
84  .description("Flux in Neumann boundary condition.")
85  .units( UnitSI().kg().m().s(-1).md() )
86  .input_default("0.0")
87  .flags_add(FieldFlag::in_rhs);
88  *this+=bc_robin_sigma
89  .disable_where(bc_type, { bc_dirichlet, bc_inflow })
90  .name("bc_robin_sigma")
91  .description("Conductivity coefficient in Robin boundary condition.")
92  .units( UnitSI().m(4).s(-1).md() )
93  .input_default("0.0")
94  .flags_add(FieldFlag::in_rhs & FieldFlag::in_main_matrix);
95 
96  *this+=init_temperature
97  .name("init_temperature")
98  .description("Initial temperature.")
99  .units( UnitSI().K() )
100  .input_default("0.0");
101 
102  *this+=porosity
103  .name("porosity")
104  .description("Porosity.")
105  .units( UnitSI::dimensionless() )
106  .input_default("1.0")
107  .flags_add(in_main_matrix & in_time_term)
108  .set_limits(0.0);
109 
110  *this+=water_content
111  .name("water_content")
112  .units( UnitSI::dimensionless() )
113  .input_default("1.0")
114  .flags_add(input_copy & in_main_matrix & in_time_term);
115 
116  *this+=fluid_density
117  .name("fluid_density")
118  .description("Density of fluid.")
119  .units( UnitSI().kg().m(-3) )
120  .flags_add(in_main_matrix & in_time_term);
121 
122  *this+=fluid_heat_capacity
123  .name("fluid_heat_capacity")
124  .description("Heat capacity of fluid.")
125  .units( UnitSI::J() * UnitSI().kg(-1).K(-1) )
126  .flags_add(in_main_matrix & in_time_term);
127 
128  *this+=fluid_heat_conductivity
129  .name("fluid_heat_conductivity")
130  .description("Heat conductivity of fluid.")
131  .units( UnitSI::W() * UnitSI().m(-1).K(-1) )
132  .flags_add(in_main_matrix)
133  .set_limits(0.0);
134 
135 
136  *this+=solid_density
137  .name("solid_density")
138  .description("Density of solid (rock).")
139  .units( UnitSI().kg().m(-3) )
140  .flags_add(in_time_term);
141 
142  *this+=solid_heat_capacity
143  .name("solid_heat_capacity")
144  .description("Heat capacity of solid (rock).")
145  .units( UnitSI::J() * UnitSI().kg(-1).K(-1) )
146  .flags_add(in_time_term);
147 
148  *this+=solid_heat_conductivity
149  .name("solid_heat_conductivity")
150  .description("Heat conductivity of solid (rock).")
151  .units( UnitSI::W() * UnitSI().m(-1).K(-1) )
152  .flags_add(in_main_matrix)
153  .set_limits(0.0);
154 
155  *this+=disp_l
156  .name("disp_l")
157  .description("Longitudal heat dispersivity in fluid.")
158  .units( UnitSI().m() )
159  .input_default("0.0")
160  .flags_add(in_main_matrix);
161 
162  *this+=disp_t
163  .name("disp_t")
164  .description("Transversal heat dispersivity in fluid.")
165  .units( UnitSI().m() )
166  .input_default("0.0")
167  .flags_add(in_main_matrix);
168 
169  *this+=fluid_thermal_source
170  .name("fluid_thermal_source")
171  .description("Thermal source density in fluid.")
172  .units( UnitSI::W() * UnitSI().m(-3) )
173  .input_default("0.0")
174  .flags_add(in_rhs);
175 
176  *this+=solid_thermal_source
177  .name("solid_thermal_source")
178  .description("Thermal source density in solid.")
179  .units( UnitSI::W() * UnitSI().m(-3) )
180  .input_default("0.0")
181  .flags_add(in_rhs);
182 
183  *this+=fluid_heat_exchange_rate
184  .name("fluid_heat_exchange_rate")
185  .description("Heat exchange rate in fluid.")
186  .units( UnitSI().s(-1) )
187  .input_default("0.0")
188  .flags_add(in_rhs);
189 
190  *this+=solid_heat_exchange_rate
191  .name("solid_heat_exchange_rate")
192  .description("Heat exchange rate of source in solid.")
193  .units( UnitSI().s(-1) )
194  .input_default("0.0")
195  .flags_add(in_rhs);
196 
197  *this+=fluid_ref_temperature
198  .name("fluid_ref_temperature")
199  .description("Reference temperature of source in fluid.")
200  .units( UnitSI().K() )
201  .input_default("0.0")
202  .flags_add(in_rhs);
203 
204  *this+=solid_ref_temperature
205  .name("solid_ref_temperature")
206  .description("Reference temperature in solid.")
207  .units( UnitSI().K() )
208  .input_default("0.0")
209  .flags_add(in_rhs);
210 
211  *this+=cross_section
212  .name("cross_section")
213  .units( UnitSI().m(3).md() )
214  .flags(input_copy & in_time_term & in_main_matrix);
215 
216  *this+=output_field
217  .name("temperature")
218  .units( UnitSI().K() )
219  .flags(equation_result);
220 }
221 
222 
223 
224 IT::Record HeatTransferModel::get_input_type(const string &implementation, const string &description)
225 {
226  return IT::Record(
227  std::string(ModelEqData::name()) + "_" + implementation,
228  description + " for heat transfer.")
230  .declare_key("time", TimeGovernor::get_input_type(), Default::obligatory(),
231  "Time governor setting for the secondary equation.")
232  .declare_key("balance", Balance::get_input_type(), Default("{}"),
233  "Settings for computing balance.")
234  .declare_key("output_stream", OutputTime::get_input_type(), Default::obligatory(),
235  "Parameters of output stream.");
236 }
237 
238 
240 {
241  // Return empty selection just to provide model specific selection name and description.
242  // The fields are added by TransportDG using an auxiliary selection.
243  return IT::Selection(
244  std::string(ModelEqData::name()) + "_DG_output_fields",
245  "Selection of output fields for Heat Transfer DG model.");
246 }
247 
248 
250  AdvectionProcessBase(mesh, in_rec),
251  flux_changed(true),
252  mh_dh(nullptr)
253 {
254  time_ = new TimeGovernor(in_rec.val<Input::Record>("time"));
255  substances_.initialize({""});
256 
257  output_stream_ = OutputTime::create_output_stream("heat", *mesh_, in_rec.val<Input::Record>("output_stream"));
258  //output_stream_->add_admissible_field_names(in_rec.val<Input::Array>("output_fields"));
259 
260  balance_ = std::make_shared<Balance>("energy", mesh_);
261  balance_->init_from_input(in_rec.val<Input::Record>("balance"), *time_);
262  // initialization of balance object
263  if (balance_)
264  {
265  subst_idx = {balance_->add_quantity("energy")};
266  balance_->units(UnitSI().m(2).kg().s(-2));
267  }
268 }
269 
270 
272 {
273  output_stream_->write_time_frame();
274  if (balance_ != nullptr)
275  {
276  if (balance_->is_current(time_->step())) {
278  balance_->output(time_->t());
279  }
280  }
281 }
282 
283 
285  const ElementAccessor<3> &ele_acc,
286  std::vector<double> &mm_coef)
287 {
288  vector<double> elem_csec(point_list.size()),
289  por(point_list.size()),
290  f_rho(point_list.size()),
291  s_rho(point_list.size()),
292  f_c(point_list.size()),
293  s_c(point_list.size());
294 
295  data().cross_section.value_list(point_list, ele_acc, elem_csec);
296  data().porosity.value_list(point_list, ele_acc, por);
297  data().fluid_density.value_list(point_list, ele_acc, f_rho);
298  data().fluid_heat_capacity.value_list(point_list, ele_acc, f_c);
299  data().solid_density.value_list(point_list, ele_acc, s_rho);
300  data().solid_heat_capacity.value_list(point_list, ele_acc, s_c);
301 
302  for (unsigned int i=0; i<point_list.size(); i++)
303  mm_coef[i] = elem_csec[i]*(por[i]*f_rho[i]*f_c[i] + (1.-por[i])*s_rho[i]*s_c[i]);
304 }
305 
306 
308  const std::vector<arma::vec3> &velocity,
309  const ElementAccessor<3> &ele_acc,
312 {
313  const unsigned int qsize = point_list.size();
314  std::vector<double> f_rho(qsize), f_cap(qsize), f_cond(qsize),
315  s_cond(qsize), por(qsize), csection(qsize), disp_l(qsize), disp_t(qsize);
316 
317  data().fluid_density.value_list(point_list, ele_acc, f_rho);
318  data().fluid_heat_capacity.value_list(point_list, ele_acc, f_cap);
319  data().fluid_heat_conductivity.value_list(point_list, ele_acc, f_cond);
320  data().solid_heat_conductivity.value_list(point_list, ele_acc, s_cond);
321  data().disp_l.value_list(point_list, ele_acc, disp_l);
322  data().disp_t.value_list(point_list, ele_acc, disp_t);
323  data().porosity.value_list(point_list, ele_acc, por);
324  data().cross_section.value_list(point_list, ele_acc, csection);
325 
326  for (unsigned int k=0; k<qsize; k++) {
327  ad_coef[0][k] = velocity[k]*f_rho[k]*f_cap[k];
328 
329  // dispersive part of thermal diffusion
330  // Note that the velocity vector is in fact the Darcian flux,
331  // so to obtain |v| we have to divide vnorm by porosity and cross_section.
332  double vnorm = arma::norm(velocity[k], 2);
333  if (fabs(vnorm) > 0)
334  for (int i=0; i<3; i++)
335  for (int j=0; j<3; j++)
336  dif_coef[0][k](i,j) = ((velocity[k][i]/vnorm)*(velocity[k][j]/vnorm)*(disp_l[k]-disp_t[k]) + disp_t[k]*(i==j?1:0))
337  *vnorm*f_rho[k]*f_cond[k];
338  else
339  dif_coef[0][k].zeros();
340 
341  // conductive part of thermal diffusion
342  dif_coef[0][k] += csection[k]*(por[k]*f_cond[k] + (1.-por[k])*s_cond[k])*arma::eye(3,3);
343  }
344 }
345 
346 
348  const ElementAccessor<3> &ele_acc,
349  std::vector< arma::vec > &init_values)
350 {
351  vector<double> init_value(point_list.size());
352  data().init_temperature.value_list(point_list, ele_acc, init_value);
353  for (unsigned int i=0; i<point_list.size(); i++)
354  init_values[i] = init_value[i];
355 }
356 
357 
359  arma::uvec &bc_types)
360 {
361  // Currently the bc types for HeatTransfer are numbered in the same way as in TransportDG.
362  // In general we should use some map here.
363  bc_types = { data().bc_type.value(ele_acc.centre(), ele_acc) };
364 }
365 
366 
367 void HeatTransferModel::get_flux_bc_data(unsigned int index,
368  const std::vector<arma::vec3> &point_list,
369  const ElementAccessor<3> &ele_acc,
370  std::vector< double > &bc_flux,
371  std::vector< double > &bc_sigma,
372  std::vector< double > &bc_ref_value)
373 {
374  data().bc_flux.value_list(point_list, ele_acc, bc_flux);
375  data().bc_robin_sigma.value_list(point_list, ele_acc, bc_sigma);
376  data().bc_dirichlet_value[index].value_list(point_list, ele_acc, bc_ref_value);
377 
378  // Change sign in bc_flux since internally we work with outgoing fluxes.
379  for (auto f : bc_flux) f = -f;
380 }
381 
382 void HeatTransferModel::get_flux_bc_sigma(unsigned int index,
383  const std::vector<arma::vec3> &point_list,
384  const ElementAccessor<3> &ele_acc,
385  std::vector< double > &bc_sigma)
386 {
387  data().bc_robin_sigma.value_list(point_list, ele_acc, bc_sigma);
388 }
389 
390 
392  const ElementAccessor<3> &ele_acc,
393  std::vector<arma::vec> &sources_value,
394  std::vector<arma::vec> &sources_density,
395  std::vector<arma::vec> &sources_sigma)
396 {
397  const unsigned int qsize = point_list.size();
398  std::vector<double> por(qsize), csection(qsize), f_rho(qsize), s_rho(qsize), f_cap(qsize), s_cap(qsize),
399  f_source(qsize), s_source(qsize), f_sigma(qsize), s_sigma(qsize), f_temp(qsize), s_temp(qsize);
400  data().porosity.value_list(point_list, ele_acc, por);
401  data().cross_section.value_list(point_list, ele_acc, csection);
402  data().fluid_density.value_list(point_list, ele_acc, f_rho);
403  data().solid_density.value_list(point_list, ele_acc, s_rho);
404  data().fluid_heat_capacity.value_list(point_list, ele_acc, f_cap);
405  data().solid_heat_capacity.value_list(point_list, ele_acc, s_cap);
406  data().fluid_thermal_source.value_list(point_list, ele_acc, f_source);
407  data().solid_thermal_source.value_list(point_list, ele_acc, s_source);
408  data().fluid_heat_exchange_rate.value_list(point_list, ele_acc, f_sigma);
409  data().solid_heat_exchange_rate.value_list(point_list, ele_acc, s_sigma);
410  data().fluid_ref_temperature.value_list(point_list, ele_acc, f_temp);
411  data().solid_ref_temperature.value_list(point_list, ele_acc, s_temp);
412 
413  for (unsigned int k=0; k<point_list.size(); k++)
414  {
415  sources_density[k].resize(1);
416  sources_sigma[k].resize(1);
417  sources_value[k].resize(1);
418 
419  sources_density[k][0] = csection[k]*(por[k]*f_source[k] + (1.-por[k])*s_source[k]);
420  sources_sigma[k][0] = csection[k]*(por[k]*f_rho[k]*f_cap[k]*f_sigma[k] + (1.-por[k])*s_rho[k]*s_cap[k]*s_sigma[k]);
421  if (fabs(sources_sigma[k][0]) > numeric_limits<double>::epsilon())
422  sources_value[k][0] = csection[k]*(por[k]*f_rho[k]*f_cap[k]*f_sigma[k]*f_temp[k]
423  + (1.-por[k])*s_rho[k]*s_cap[k]*s_sigma[k]*s_temp[k])/sources_sigma[k][0];
424  else
425  sources_value[k][0] = 0;
426  }
427 }
428 
429 
431  const ElementAccessor<3> &ele_acc,
432  std::vector<arma::vec> &sources_sigma)
433 {
434  const unsigned int qsize = point_list.size();
435  std::vector<double> por(qsize), csection(qsize), f_rho(qsize), s_rho(qsize), f_cap(qsize), s_cap(qsize),
436  f_source(qsize), s_source(qsize), f_sigma(qsize), s_sigma(qsize), f_temp(qsize), s_temp(qsize);
437  data().porosity.value_list(point_list, ele_acc, por);
438  data().cross_section.value_list(point_list, ele_acc, csection);
439  data().fluid_density.value_list(point_list, ele_acc, f_rho);
440  data().solid_density.value_list(point_list, ele_acc, s_rho);
441  data().fluid_heat_capacity.value_list(point_list, ele_acc, f_cap);
442  data().solid_heat_capacity.value_list(point_list, ele_acc, s_cap);
443  data().fluid_heat_exchange_rate.value_list(point_list, ele_acc, f_sigma);
444  data().solid_heat_exchange_rate.value_list(point_list, ele_acc, s_sigma);
445  for (unsigned int k=0; k<point_list.size(); k++)
446  {
447  sources_sigma[k].resize(1);
448  sources_sigma[k][0] = csection[k]*(por[k]*f_rho[k]*f_cap[k]*f_sigma[k] + (1.-por[k])*s_rho[k]*s_cap[k]*s_sigma[k]);
449  }
450 }
451 
452 
454 {}
455 
456 
457 
458 
vector< unsigned int > subst_idx
List of indices used to call balance methods for a set of quantities.
Definition: heat_model.hh:267
Field< 3, FieldValue< 3 >::Scalar > solid_heat_capacity
Heat capacity of solid.
Definition: heat_model.hh:118
void compute_sources_sigma(const std::vector< arma::vec3 > &point_list, const ElementAccessor< 3 > &ele_acc, std::vector< arma::vec > &sources_sigma) override
Definition: heat_model.cc:430
static const Input::Type::Record & get_input_type()
Main balance input record type.
Definition: balance.cc:42
Field< 3, FieldValue< 3 >::Scalar > fluid_density
Density of fluid.
Definition: heat_model.hh:110
static constexpr Mask in_main_matrix
A field is part of main "stiffness matrix" of the equation.
Definition: field_flag.hh:49
Field< 3, FieldValue< 3 >::Scalar > disp_t
Transversal heat dispersivity.
Definition: heat_model.hh:124
Field< 3, FieldValue< 3 >::Scalar > cross_section
Pointer to DarcyFlow field cross_section.
Definition: heat_model.hh:139
static const Input::Type::Record & get_input_type()
The specification of output stream.
Definition: output_time.cc:38
Class Input::Type::Default specifies default value of keys of a Input::Type::Record.
Definition: type_record.hh:56
static IT::Selection get_output_selection()
Definition: heat_model.cc:239
void initialize(const Input::Array &in_array)
Read from input array.
Definition: substance.cc:58
Field< 3, FieldValue< 3 >::Scalar > fluid_heat_exchange_rate
Heat exchange rate in fluid.
Definition: heat_model.hh:130
Field< 3, FieldValue< 3 >::Scalar > solid_heat_exchange_rate
Heat exchange rate in solid.
Definition: heat_model.hh:132
Definition: mesh.h:95
BCMultiField< 3, FieldValue< 3 >::Scalar > bc_dirichlet_value
Dirichlet boundary condition for temperature.
Definition: heat_model.hh:98
void compute_init_cond(const std::vector< arma::vec3 > &point_list, const ElementAccessor< 3 > &ele_acc, std::vector< arma::vec > &init_values) override
Definition: heat_model.cc:347
const TimeStep & step(int index=-1) const
BCField< 3, FieldValue< 3 >::Enum > bc_type
Type of boundary condition (see also BC_Type)
Definition: heat_model.hh:96
static const Input::Type::Selection & get_bc_type_selection()
Definition: heat_model.cc:39
Field< 3, FieldValue< 3 >::Scalar > fluid_heat_capacity
Heat capacity of fluid.
Definition: heat_model.hh:112
double t() const
virtual void calculate_instant_balance()=0
Basic time management functionality for unsteady (and steady) solvers (class Equation).
BCField< 3, FieldValue< 3 >::Scalar > bc_flux
Flux value in total/diffusive flux b.c.
Definition: heat_model.hh:100
void get_bc_type(const ElementAccessor< 3 > &ele_acc, arma::uvec &bc_types) override
Definition: heat_model.cc:358
virtual void value_list(const std::vector< Point > &point_list, const ElementAccessor< spacedim > &elm, std::vector< typename Value::return_type > &value_list) const
Definition: field.hh:364
Field< 3, FieldValue< 3 >::Scalar > porosity
Porosity of solid.
Definition: heat_model.hh:106
Field< 3, FieldValue< 3 >::Scalar > fluid_thermal_source
Thermal source in fluid.
Definition: heat_model.hh:126
virtual Record & derive_from(Abstract &parent)
Method to derive new Record from an AbstractRecord parent.
Definition: type_record.cc:193
Field< 3, FieldValue< 3 >::Scalar > fluid_heat_conductivity
Heat conductivity of fluid.
Definition: heat_model.hh:114
void get_flux_bc_sigma(unsigned int index, const std::vector< arma::vec3 > &point_list, const ElementAccessor< 3 > &ele_acc, std::vector< double > &bc_sigma) override
Return transition coefficient for flux b.c.
Definition: heat_model.cc:382
static Input::Type::Abstract & get_input_type()
Common specification of the input record for secondary equations.
Field< 3, FieldValue< 3 >::Scalar > fluid_ref_temperature
Reference temperature in fluid.
Definition: heat_model.hh:134
void get_flux_bc_data(unsigned int index, const std::vector< arma::vec3 > &point_list, const ElementAccessor< 3 > &ele_acc, std::vector< double > &bc_flux, std::vector< double > &bc_sigma, std::vector< double > &bc_ref_value) override
Return data for diffusive or total flux b.c.
Definition: heat_model.cc:367
Field< 3, FieldValue< 3 >::Scalar > init_temperature
Initial temperature.
Definition: heat_model.hh:104
Field< 3, FieldValue< 3 >::Scalar > solid_thermal_source
Thermal source in solid.
Definition: heat_model.hh:128
void compute_mass_matrix_coefficient(const std::vector< arma::vec3 > &point_list, const ElementAccessor< 3 > &ele_acc, std::vector< double > &mm_coef) override
Definition: heat_model.cc:284
static UnitSI & W()
Returns Watt.
Definition: unit_si.cc:45
Accessor to the data with type Type::Record.
Definition: accessors.hh:286
const Ret val(const string &key) const
static UnitSI & J()
Returns Joule.
Definition: unit_si.cc:40
Mesh * mesh_
Definition: equation.hh:223
Selection & add_value(const int value, const std::string &key, const std::string &description="", TypeBase::attribute_map attributes=TypeBase::attribute_map())
Adds one new value with name given by key to the Selection.
virtual Value::return_type const & value(const Point &p, const ElementAccessor< spacedim > &elm) const
Definition: field.hh:350
std::shared_ptr< Balance > balance_
object for calculation and writing the mass balance to file.
Definition: equation.hh:235
Record & declare_key(const string &key, std::shared_ptr< TypeBase > type, const Default &default_value, const string &description, TypeBase::attribute_map key_attributes=TypeBase::attribute_map())
Declares a new key of the Record.
Definition: type_record.cc:488
Field< 3, FieldValue< 3 >::Scalar > solid_heat_conductivity
Heat conductivity of solid.
Definition: heat_model.hh:120
SubstanceList substances_
Transported substances.
Definition: heat_model.hh:257
static constexpr Mask in_rhs
A field is part of the right hand side of the equation.
Definition: field_flag.hh:51
const double epsilon
Definition: mathfce.h:23
static std::shared_ptr< OutputTime > create_output_stream(const std::string &equation_name, Mesh &mesh, const Input::Record &in_rec)
This method delete all object instances of class OutputTime stored in output_streams vector...
Definition: output_time.cc:191
Field< 3, FieldValue< 3 >::Scalar > solid_ref_temperature
Reference temperature in solid.
Definition: heat_model.hh:136
const Selection & close() const
Close the Selection, no more values can be added.
virtual ModelEqData & data()=0
Derived class should implement getter for ModelEqData instance.
void compute_advection_diffusion_coefficients(const std::vector< arma::vec3 > &point_list, const std::vector< arma::vec3 > &velocity, const ElementAccessor< 3 > &ele_acc, std::vector< std::vector< arma::vec3 > > &ad_coef, std::vector< std::vector< arma::mat33 > > &dif_coef) override
Definition: heat_model.cc:307
static const Input::Type::Record & get_input_type()
~HeatTransferModel() override
Definition: heat_model.cc:453
Field< 3, FieldValue< 3 >::Scalar > solid_density
Density of solid.
Definition: heat_model.hh:116
Discontinuous Galerkin method for equation of transport with dispersion.
arma::vec::fixed< spacedim > centre() const
Definition: accessors.hh:91
HeatTransferModel(Mesh &mesh, const Input::Record in_rec)
Definition: heat_model.cc:249
Record type proxy class.
Definition: type_record.hh:177
void compute_source_coefficients(const std::vector< arma::vec3 > &point_list, const ElementAccessor< 3 > &ele_acc, std::vector< arma::vec > &sources_conc, std::vector< arma::vec > &sources_density, std::vector< arma::vec > &sources_sigma) override
Definition: heat_model.cc:391
BCField< 3, FieldValue< 3 >::Scalar > bc_robin_sigma
Transition coefficient in total/diffusive flux b.c.
Definition: heat_model.hh:102
std::shared_ptr< OutputTime > output_stream_
Definition: heat_model.hh:269
Class for representation SI units of Fields.
Definition: unit_si.hh:40
static UnitSI & dimensionless()
Returns dimensionless unit.
Definition: unit_si.cc:55
Template for classes storing finite set of named values.
void output_data() override
Write computed fields.
Definition: heat_model.cc:271
Field< 3, FieldValue< 3 >::Scalar > disp_l
Longitudal heat dispersivity.
Definition: heat_model.hh:122
virtual void value_list(const std::vector< Point > &point_list, const ElementAccessor< spacedim > &elm, std::vector< typename MultiFieldValue::return_type > &value_list) const
TimeGovernor * time_
Definition: equation.hh:224