Flow123d
master-a7f2151e0
|
Go to the documentation of this file.
18 #ifndef ASSEMBLY_REACTION_HH_
19 #define ASSEMBLY_REACTION_HH_
33 template <
unsigned int dim>
40 static constexpr
const char *
name() {
return "InitConditionAssemblyDp"; }
62 ASSERT_EQ(cell.
dim(), dim).error(
"Dimension of element mismatch!");
65 auto p = *( this->
bulk_points(element_patch_idx).begin() );
85 template <
template<
IntDim...>
class DimAssembly>
89 template <
unsigned int dim>
96 static constexpr
const char *
name() {
return "InitConditionAssemblyDp"; }
120 ASSERT_EQ(cell.
dim(), dim).error(
"Dimension of element mismatch!");
122 auto p = *( this->
bulk_points(element_patch_idx).begin() );
197 template <
template<
IntDim...>
class DimAssembly>
201 template <
unsigned int dim>
208 static constexpr
const char *
name() {
return "InitConditionAssemblySorp"; }
230 ASSERT_EQ(cell.
dim(), dim).error(
"Dimension of element mismatch!");
233 auto p = *( this->
bulk_points(element_patch_idx).begin() );
253 template <
template<
IntDim...>
class DimAssembly>
257 template <
unsigned int dim>
264 static constexpr
const char *
name() {
return "ReactionAssemblySorp"; }
291 ASSERT_EQ(cell.
dim(), dim).error(
"Dimension of element mismatch!");
293 unsigned int i_subst, subst_id;
294 auto p = *( this->
bulk_points(element_patch_idx).begin() );
312 if( no_sorbing_surface_cond <= std::numeric_limits<double>::epsilon())
315 scale_aqua, scale_sorbed,
318 if ( scale_sorbed <= 0.0)
319 THROW( SorptionBase::ExcNotPositiveScaling() << SorptionBase::EI_Subst(i_subst) );
323 scale_aqua, scale_sorbed,
331 isotherm.
compute(c_aqua, c_sorbed);
355 template <
template<
IntDim...>
class DimAssembly>
MultiField< 3, FieldValue< 3 >::Enum > sorption_type
Discrete need Selection for initialization.
~ReactionAssemblySorp()
Destructor.
MultiField< 3, FieldValue< 3 >::Scalar > diffusion_rate_immobile
Mass transfer coefficients between mobile and immobile pores.
FieldSet used_fields_
Sub field set contains fields used in calculation.
unsigned int sbi_
Index of substance.
DualPorosity::EqData EqData
FieldSet used_fields_
Sub field set contains fields used in calculation.
static constexpr const char * name()
FieldFEScalarVec conc_solid_fe
Underlaying FieldFE for each substance of conc_solid.
DualPorosity::EqFields EqFields
Field< 3, FieldValue< 3 >::Scalar > no_sorbing_surface_cond
IntIdx dof_p0_
Index of local DOF.
void initialize(ElementCacheMap *element_cache_map)
Initialize auxiliary vectors and other data members.
MultiField< 3, FieldValue< 3 >::Scalar > distribution_coefficient
Multiplication coefficients (k, omega) for all types of isotherms.
double previous_conc_mob_
std::vector< std::vector< Isotherm > > isotherms
void cell_integral(DHCellAccessor cell, unsigned int element_patch_idx)
Assemble integral over element.
double scheme_tolerance_
Dual porosity computational scheme tolerance.
unsigned int size() const
void cell_integral(DHCellAccessor cell, unsigned int element_patch_idx)
Assemble integral over element.
unsigned int n_substances_
number of substances that take part in the sorption mode
ReactionAssemblySorp(EqFields *eq_fields, EqData *eq_data)
Constructor.
EqFields * eq_fields_
Data objects shared with Elasticity.
Directing class of FieldValueCache.
IntIdx dof_p0_
Index of local DOF.
Class FEValues calculates finite element data on the actual cells such as shape function values,...
EqFields * eq_fields_
Data objects shared with Elasticity.
#define THROW(whole_exception_expr)
Wrapper for throw. Saves the throwing point.
void initialize(ElementCacheMap *element_cache_map)
Initialize auxiliary vectors and other data members.
MultiField< 3, FieldValue< 3 >::Scalar > init_conc_immobile
Initial concentrations in the immobile zone.
unsigned int dim() const
Return dimension of element appropriate to cell.
FieldFEScalarVec conc_immobile_fe
Underlaying FieldFE for each substance of conc_immobile.
void initialize(ElementCacheMap *element_cache_map)
Initialize auxiliary vectors and other data members.
EqFields * eq_fields_
Data objects shared with Elasticity.
Definitions of basic Lagrangean finite elements with polynomial shape functions.
void compute(double &c_aqua, double &c_sorbed)
MultiField< 3, FieldValue< 3 >::Scalar > isotherm_other
Langmuir sorption coeficients alpha (in fraction c_s = omega * (alpha*c_a)/(1- alpha*c_a)).
SorptionType
Type of adsorption isotherm.
MultiField< 3, FieldValue< 3 >::Scalar > init_conc_solid
Initial sorbed concentrations.
TimeGovernor * time_
TimeGovernor object shared with assembly classes.
static constexpr const char * name()
std::vector< double > table_limit_
double conc_max_
difference between concentration and average concentration
InitConditionAssemblyDp(EqFields *eq_fields, EqData *eq_data)
Constructor.
SorptionBase::EqFields EqFields
EqFields * eq_fields_
Data objects shared with Elasticity.
Definitions of particular quadrature rules on simplices.
ReactionAssemblyDp(EqFields *eq_fields, EqData *eq_data)
Constructor.
double por_immob_
mobile and immobile porosity
double previous_conc_immob_
mobile and immobile concentration in previous time step
std::vector< unsigned int > substance_global_idx_
Mapping from local indexing of substances to global.
const ElementAccessor< 3 > elm() const
Return ElementAccessor to element of loc_ele_idx_.
~ReactionAssemblyDp()
Destructor.
Field< 3, FieldValue< 3 >::Scalar > porosity_immobile
Immobile porosity field.
void initialize(ElementCacheMap *element_cache_map)
Initialize auxiliary vectors and other data members.
#define ASSERT_EQ(a, b)
Definition of comparative assert macro (EQual) only for debug mode.
static constexpr const char * name()
Container for various descendants of FieldCommonBase.
Field< 3, FieldValue< 3 >::Scalar > porosity
Porosity field.
InitConditionAssemblySorp(EqFields *eq_fields, EqData *eq_data)
Constructor.
std::vector< double > solubility_vec_
std::vector< std::vector< double > > max_conc
int reg_idx_
Bulk region idx.
DualPorosity::EqFields EqFields
Range< BulkPoint > bulk_points(unsigned int element_patch_idx) const
Return BulkPoint range of appropriate dimension.
SorptionBase::EqData EqData
Class Dual_por_exchange implements the model of dual porosity.
Cell accessor allow iterate over DOF handler cells.
double conc_average_
weighted (by porosity) average of concentration
~InitConditionAssemblyDp()
Destructor.
IntIdx dof_p0_
Index of local DOF.
int active_integrals_
Holds mask of active integrals.
Field< 3, FieldValue< 3 >::Scalar > scale_aqua
Instances of FieldModel used in assembly methods.
LocDofVec get_loc_dof_indices() const
Returns the local indices of dofs associated to the cell on the local process.
SubstanceList substances_
IntIdx dof_p0_
Index of local DOF.
double conc_immob_
new mobile and immobile concentration
FieldFEScalarVec conc_mobile_fe
FieldFEs representing P0 interpolation of mobile concentration (passed from transport).
FieldSet used_fields_
Sub field set contains fields used in calculation.
void cell_integral(DHCellAccessor cell, unsigned int element_patch_idx)
Assemble integral over element.
double temp_
Precomputed values.
static constexpr const char * name()
unsigned int bulk_idx() const
Returns index of the region in the bulk set.
Generic class of assemblation.
Field< 3, FieldValue< 3 >::Scalar > scale_sorbed
SorptionBase::EqData EqData
ElementCacheMap * element_cache_map_
ElementCacheMap shared with GenericAssembly object.
void reinit(enum SorptionType sorption_type, bool limited_solubility_on, double aqua_density, double scale_aqua, double scale_sorbed, double c_aqua_limit, double mult_coef, double second_coef)
FieldSet used_fields_
Sub field set contains fields used in calculation.
void cell_integral(DHCellAccessor cell, unsigned int element_patch_idx)
Assemble integral over element.
~InitConditionAssemblySorp()
Destructor.
SorptionBase::EqFields EqFields
DualPorosity::EqData EqData
unsigned int IntDim
A dimension index type.