Flow123d
release_3.0.0-968-gc87a28e79
|
Go to the documentation of this file.
64 "Transport of soluted substances.")
70 return Record(
"Coupling_OperatorSplitting",
71 "Transport by convection and/or diffusion\n"
72 "coupled with reaction and adsorption model (ODE per element)\n"
73 " via operator splitting.")
77 "Time governor settings for the transport equation.")
79 "Settings for computing mass balance.")
81 "Output stream settings.\n Specify file format, precision etc.")
83 "Specification of transported substances.")
86 "Type of the numerical method for the transport equation.")
88 "Reaction model involved in transport.")
98 Input::register_class< TransportOperatorSplitting, Mesh &, const Input::Record>(
"Coupling_OperatorSplitting") +
109 *
this += porosity.name(
"porosity")
110 .description(
"Porosity of the mobile phase.")
111 .input_default(
"1.0")
113 .flags_add(in_main_matrix & in_rhs);
115 *
this += water_content.name(
"water_content")
116 .description(
"INTERNAL. Water content passed from unsaturated Darcy flow model.")
118 .flags_add(input_copy & in_time_term & in_main_matrix & in_rhs);
120 *
this += cross_section.name(
"cross_section")
122 .flags_add(in_time_term & in_main_matrix & in_rhs);
124 *
this += sources_density.name(
"sources_density")
125 .description(
"Density of concentration sources.")
126 .input_default(
"0.0")
127 .units(
UnitSI().kg().m(-3).s(-1) )
130 *
this += sources_sigma.name(
"sources_sigma")
131 .description(
"Concentration flux.")
132 .input_default(
"0.0")
134 .flags_add(in_main_matrix & in_rhs);
136 *
this += sources_conc.name(
"sources_conc")
137 .description(
"Concentration sources threshold.")
138 .input_default(
"0.0")
139 .units(
UnitSI().kg().m(-3) )
156 cfl_convection(numeric_limits<double>::max()),
157 cfl_reaction(numeric_limits<double>::max())
192 this->
eq_data_ = &(convection->data());
194 convection->get_par_info(el_4_loc, el_distribution);
196 if ( reactions_it ) {
206 shared_ptr<DOFHandlerMultiDim> dof_handler = make_shared<DOFHandlerMultiDim>(*
mesh_);
207 shared_ptr<DiscreteSpace> ds = make_shared<EqualOrderDiscreteSpace>(
mesh_, &fe0, &fe1, &fe2, &fe3);
208 dof_handler->distribute_dofs(ds);
211 .concentration_matrix(
convection->get_concentration_matrix(),
212 el_distribution, el_4_loc,
convection->get_row_4_el())
256 convection->output_stream()->write_time_frame();
272 convection->output_stream()->write_time_frame();
297 bool cfl_changed = cfl_convection_changed || cfl_reaction_changed;
299 if (steps == 1 || cfl_changed)
301 convection->time().set_upper_constraint(
cfl_convection,
"Time step constrained by transport CFL condition (including both flow and sources).");
302 convection->time().set_upper_constraint(
cfl_reaction,
"Time step constrained by reaction CFL condition.");
318 for (
unsigned int sbi=0; sbi<
convection->n_substances(); sbi++)
323 source[sbi] -= region_mass[ri];
345 for (
unsigned int sbi=0; sbi<
convection->n_substances(); sbi++)
350 source[sbi] += region_mass[ri];
353 balance_->add_cumulative_source(sbi, source[sbi]);
360 LogOut().fmt(
"CONVECTION: steps: {}\n", steps);
static const int registrar
Registrar of class to factory.
static UnitSI & dimensionless()
Returns dimensionless unit.
Basic time management class.
virtual void set_velocity_field(const MH_DofHandler &dh) override
int LongIdx
Define type that represents indices of large arrays (elements, nodes, dofs etc.)
void zero_time_step() override
Support classes for parallel programing.
Class representing dual porosity model in transport.
Definitions of basic Lagrangean finite elements with polynomial shape functions.
void initialize() override
TransportOperatorSplitting(Mesh &init_mesh, const Input::Record in_rec)
Constructor.
FLOW123D_FORCE_LINK_IN_PARENT(firstOrderReaction)
#define LogOut()
Macro defining 'log' record of log.
std::shared_ptr< Balance > balance_
object for calculation and writing the mass balance to file.
unsigned int bulk_size() const
static const Input::Type::Record & get_input_type()
Declare input record type for the equation TransportOperatorSplittiong.
Basic time management functionality for unsteady (and steady) solvers (class Equation).
void update_solution() override
std::shared_ptr< ReactionTerm > reaction
This file contains classes representing sorption model. Sorption model can be computed both in case t...
void output_data() override
Write computed fields.
Class for representation SI units of Fields.
const RegionDB & region_db() const
static Input::Type::Abstract & get_input_type()
Common specification of the input record for secondary equations.
Abstract base class for equation clasess.
Simple sorption model without dual porosity.
static const Input::Type::Record & get_input_type()
void view(const char *name="") const
static constexpr Mask input_copy
double cfl_convection
Time restriction due to transport.
static const Type none_type
Mark Type with all bits unset.
static const Input::Type::Record & get_input_type()
Input type for a substance.
static const Input::Type::Record & get_input_type()
The specification of output stream.
Class Dual_por_exchange implements the model of dual porosity.
static string subfields_address()
static Input::Type::Abstract & it_abstract_term()
std::shared_ptr< ConcentrationTransportBase > convection
FLOW123D_FORCE_LINK_IN_CHILD(transportOperatorSplitting)
static std::shared_ptr< OutputTime > create_output_stream(const std::string &equation_name, const Input::Record &in_rec, std::string unit_str)
This method delete all object instances of class OutputTime stored in output_streams vector.
static Input::Type::Abstract & get_input_type()
Common specification of the input record for secondary equations.
double cfl_reaction
Time restriction due to reactions.
Class ReactionTerm is an abstract class representing reaction term in transport.
void next_time()
Proceed to the next time according to current estimated time step.
#define START_TIMER(tag)
Starts a timer with specified tag.
virtual ~TransportOperatorSplitting()
Destructor.
static const Input::Type::Record & get_input_type()
Main balance input record type.
#define END_TIMER(tag)
Ends a timer with specified tag.