Flow123d  master-2fe7782
assembly_richards.hh
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 assembly_richards.hh
15  * @brief
16  */
17 
18 #ifndef ASSEMBLY_RICHARDS_HH_
19 #define ASSEMBLY_RICHARDS_HH_
20 
23 #include "flow/assembly_lmh.hh"
24 #include "flow/soil_models.hh"
25 #include "fem/element_cache_map.hh"
26 
27 
28 template <unsigned int dim, class TEqData>
30 {
31 public:
32  typedef typename TEqData::EqFields EqFields;
33  typedef TEqData EqData;
34 
35  static constexpr const char * name() { return "Richards_InitCondPostprocess_Assembly"; }
36 
37  /// Constructor.
39  : AssemblyBasePatch<dim>(0, patch_internals), eq_fields_(eq_data->eq_fields_.get()), eq_data_(eq_data),
41  this->used_fields_ += this->eq_fields_->storativity;
42  this->used_fields_ += this->eq_fields_->extra_storativity;
43  this->used_fields_ += this->eq_fields_->genuchten_n_exponent;
44  this->used_fields_ += this->eq_fields_->genuchten_p_head_scale;
45  this->used_fields_ += this->eq_fields_->water_content_residual;
46  this->used_fields_ += this->eq_fields_->water_content_saturated;
47  this->used_fields_ += this->eq_fields_->conductivity;
48  this->used_fields_ += this->eq_fields_->cross_section;
49  }
50 
51  /// Destructor.
53 
54  /// Initialize auxiliary vectors and other data members
55  void initialize() {}
56 
57  inline void cell_integral(DHCellAccessor cell, unsigned int element_patch_idx) {
58  ASSERT_EQ(cell.dim(), dim).error("Dimension of element mismatch!");
59 
61  cr_disc_dofs_ = cell.cell_with_other_dh(this->eq_data_->dh_cr_disc_.get()).get_loc_dof_indices();
62  const DHCellAccessor dh_cell = cell.cell_with_other_dh(this->eq_data_->dh_.get());
63 
64  auto p = *( bulk_integral_->points(element_patch_idx).begin() );
65  bool genuchten_on = reset_soil_model(cell, p);
66  storativity_ = this->eq_fields_->storativity(p)
67  + this->eq_fields_->extra_storativity(p);
68  VectorMPI water_content_vec = this->eq_fields_->water_content_ptr->vec();
69  double diagonal_coef = cell.elm().measure() * eq_fields_->cross_section(p) / cell.elm()->n_sides();
70 
71  for (unsigned int i=0; i<cell.elm()->n_sides(); i++) {
72  const int local_side = cr_disc_dofs_[i];
73  capacity = 0;
74  water_content = 0;
75  phead = this->eq_data_->p_edge_solution.get( edge_indices_[i] );
76 
77  if (genuchten_on) {
78  fadbad::B<double> x_phead(phead);
79  fadbad::B<double> evaluated( this->eq_data_->soil_model_->water_content_diff(x_phead) );
80  evaluated.diff(0,1);
81  water_content = evaluated.val();
82  capacity = x_phead.d(0);
83  }
84  this->eq_data_->capacity.set( cr_disc_dofs_[i], capacity + storativity_ );
85  water_content_vec.set( cr_disc_dofs_[i], water_content + storativity_ * phead);
86 
87  this->eq_data_->balance_->add_mass_values(eq_data_->water_balance_idx, dh_cell, {local_side},
88  {0.0}, diagonal_coef*(water_content + storativity_ * phead) );
89  }
90  }
91 
92  /// Implements @p AssemblyBase::begin.
93  void begin() override
94  {
95  this->eq_data_->balance_->start_mass_assembly(this->eq_data_->water_balance_idx);
96  }
97 
98 
99  /// Implements @p AssemblyBase::end.
100  void end() override
101  {
102  this->eq_data_->balance_->finish_mass_assembly(this->eq_data_->water_balance_idx);
103  }
104 
105 
106 private:
107  bool reset_soil_model(const DHCellAccessor& cell, BulkPoint &p) {
108  bool genuchten_on = (this->eq_fields_->genuchten_p_head_scale.field_result({cell.elm().region()}) != result_zeros);
109  if (genuchten_on) {
110  SoilData soil_data;
111  soil_data.n = this->eq_fields_->genuchten_n_exponent(p);
112  soil_data.alpha = this->eq_fields_->genuchten_p_head_scale(p);
113  soil_data.Qr = this->eq_fields_->water_content_residual(p);
114  soil_data.Qs = this->eq_fields_->water_content_saturated(p);
115  soil_data.Ks = this->eq_fields_->conductivity(p);
116  //soil_data.cut_fraction = 0.99; // set by model
117 
118  this->eq_data_->soil_model_->reset(soil_data);
119  }
120  return genuchten_on;
121  }
122 
123 
124  /// Sub field set contains fields used in calculation.
126 
127  /// Data objects shared with ConvectionTransport
130 
131  LocDofVec cr_disc_dofs_; ///< Vector of local DOF indices pre-computed on different DOF handlers
132  LocDofVec edge_indices_; ///< Dofs of discontinuous fields on element edges.
133  double storativity_;
135 
136  /// Bulk integral of assembly class
137  std::shared_ptr<BulkIntegralAcc<dim>> bulk_integral_;
138 
139  template < template<IntDim...> class DimAssembly>
140  friend class GenericAssembly;
141 };
142 
143 
144 template <unsigned int dim, class TEqData>
145 class MHMatrixAssemblyRichards : public MHMatrixAssemblyLMH<dim, TEqData>
146 {
147 public:
148  typedef typename TEqData::EqFields EqFields;
149  typedef TEqData EqData;
150 
151  static constexpr const char * name() { return "Richards_MHMatrix_Assembly"; }
152 
153  MHMatrixAssemblyRichards(EqData *eq_data, PatchInternals *patch_internals)
154  : MHMatrixAssemblyLMH<dim, TEqData>(eq_data, patch_internals), eq_fields_(eq_data->eq_fields_.get()), eq_data_(eq_data) {
155  this->used_fields_ += eq_fields_->cross_section;
156  this->used_fields_ += eq_fields_->conductivity;
157  this->used_fields_ += eq_fields_->anisotropy;
158  this->used_fields_ += eq_fields_->sigma;
159  this->used_fields_ += eq_fields_->water_source_density;
160  this->used_fields_ += eq_fields_->water_source_sigma;
161  this->used_fields_ += eq_fields_->water_source_ref_pressure;
162  this->used_fields_ += eq_fields_->extra_source;
163  this->used_fields_ += eq_fields_->storativity;
164  this->used_fields_ += eq_fields_->extra_storativity;
165  this->used_fields_ += eq_fields_->genuchten_n_exponent;
166  this->used_fields_ += eq_fields_->genuchten_p_head_scale;
167  this->used_fields_ += eq_fields_->water_content_residual;
168  this->used_fields_ += eq_fields_->water_content_saturated;
169  this->used_fields_ += eq_fields_->bc_type;
170  this->used_fields_ += eq_fields_->bc_pressure;
171  this->used_fields_ += eq_fields_->bc_flux;
172  this->used_fields_ += eq_fields_->bc_pressure;
173  this->used_fields_ += eq_fields_->bc_robin_sigma;
174  this->used_fields_ += eq_fields_->bc_switch_pressure;
175  }
176 
177  /// Destructor.
179 
180  /// Initialize auxiliary vectors and other data members
181  void initialize() {
182  //this->balance_ = eq_data_->balance_;
184  }
185 
186 
187  /// Integral over element.
188  inline void cell_integral(DHCellAccessor cell, unsigned int element_patch_idx)
189  {
190  ASSERT_EQ(cell.dim(), dim).error("Dimension of element mismatch!");
191 
192  // evaluation point
193  auto p = *( this->bulk_integral_->points(element_patch_idx).begin() );
194  this->bulk_local_idx_ = cell.local_idx();
195 
196  this->asm_sides(p, this->compute_conductivity(cell, p), element_patch_idx);
197  this->asm_element();
198  this->asm_source_term_richards(cell, p);
199  }
200 
201 
202  /// Assembles between boundary element and corresponding side on bulk element.
203  inline void boundary_side_integral(DHCellSide cell_side)
204  {
205  ASSERT_EQ(cell_side.dim(), dim).error("Dimension of element mismatch!");
206  if (!cell_side.cell().is_own()) return;
207 
208  auto p_side = *( this->bdr_integral_->points(cell_side).begin() );
209  auto p_bdr = p_side.point_bdr(cell_side.cond().element_accessor() );
210  ElementAccessor<3> b_ele = cell_side.side().cond().element_accessor(); // ??
211 
212  this->precompute_boundary_side(cell_side, p_side, p_bdr);
213 
214  if (this->type_==DarcyLMH::EqFields::seepage) {
215  this->use_dirichlet_switch(cell_side, b_ele, p_bdr);
216  }
217 
218  this->boundary_side_integral_in(cell_side, b_ele, p_bdr);
219  }
220 
221 
222  /// Implements @p AssemblyBase::begin.
223  void begin() override
224  {
225  this->begin_mh_matrix();
226  }
227 
228 
229  /// Implements @p AssemblyBase::end.
230  void end() override
231  {
232  this->end_mh_matrix();
233  }
234 
235 
236 protected:
237  /// Part of cell_integral method, specialized in Richards equation
238  inline void asm_source_term_richards(const DHCellAccessor& cell, BulkPoint &p)
239  {
240  update_water_content(cell, p);
241  const ElementAccessor<3> ele = cell.elm();
242 
243  // set lumped source
244  diagonal_coef_ = ele.measure() * eq_fields_->cross_section(p) / ele->n_sides();
245  source_diagonal_ = diagonal_coef_ * ( eq_fields_->water_source_density(p) +
246  eq_fields_->water_source_sigma(p)*eq_fields_->water_source_ref_pressure(p) +
247  eq_fields_->extra_source(p));
248 
249  VectorMPI water_content_vec = eq_fields_->water_content_ptr->vec();
250 
251  const DHCellAccessor cr_cell = cell.cell_with_other_dh(eq_data_->dh_cr_.get());
252  auto loc_dof_vec = cr_cell.get_loc_dof_indices();
253 
254  for (unsigned int i=0; i<ele->n_sides(); i++)
255  {
256 
257  const int local_side = cr_disc_dofs_[i];
258  /*if (this->dirichlet_edge[i] == 0)*/ { //TODO Fix condition evaluating dirichlet_edge
259 
260  water_content_diff_ = -water_content_vec.get(local_side) + eq_data_->water_content_previous_time.get(local_side);
261  mass_diagonal_ = diagonal_coef_ * eq_data_->capacity.get(local_side);
262 
263  /*
264  DebugOut().fmt("w diff: {:g} mass: {:g} w prev: {:g} w time: {:g} c: {:g} p: {:g} z: {:g}",
265  water_content_diff,
266  mass_diagonal * eq_data_->p_edge_solution[local_edge],
267  -eq_data_->water_content_previous_it[local_side],
268  eq_data_->water_content_previous_time[local_side],
269  capacity,
270  eq_data_->p_edge_solution[local_edge],
271  ele.centre()[0] );
272  */
273 
274 
275  mass_rhs_ = mass_diagonal_ * eq_data_->p_edge_solution.get( loc_dof_vec[i] ) / eq_data_->time_step_
276  + diagonal_coef_ * water_content_diff_ / eq_data_->time_step_;
277 
278  /*
279  DBGCOUT(<< "source [" << loc_system_.row_dofs[this->loc_edge_dofs[i]] << ", " << loc_system_.row_dofs[this->loc_edge_dofs[i]]
280  << "] mat: " << -mass_diagonal/this->eq_data_->time_step_
281  << " rhs: " << -source_diagonal_ - mass_rhs
282  << "\n");
283  */
284  eq_data_->loc_system_[cell.local_idx()].add_value(eq_data_->loc_edge_dofs[dim-1][i], eq_data_->loc_edge_dofs[dim-1][i],
285  -diagonal_coef_*eq_fields_->water_source_sigma(p)-mass_diagonal_/eq_data_->time_step_,
287  }
288 
289  eq_data_->balance_->add_mass_values(eq_data_->water_balance_idx, cell, {local_side},
290  {0.0}, diagonal_coef_*water_content_vec.get(local_side));
291  eq_data_->balance_->add_source_values(eq_data_->water_balance_idx, ele.region().bulk_idx(),
292  {this->eq_data_->loc_system_[cell.local_idx()].row_dofs[eq_data_->loc_edge_dofs[dim-1][i]]},
293  {-diagonal_coef_*eq_fields_->water_source_sigma(p)},{source_diagonal_});
294  }
295  }
296 
297  bool reset_soil_model(const DHCellAccessor& cell, BulkPoint &p) {
298  bool genuchten_on = (this->eq_fields_->genuchten_p_head_scale.field_result({cell.elm().region()}) != result_zeros);
299  if (genuchten_on) {
300  SoilData soil_data;
301  soil_data.n = this->eq_fields_->genuchten_n_exponent(p);
302  soil_data.alpha = this->eq_fields_->genuchten_p_head_scale(p);
303  soil_data.Qr = this->eq_fields_->water_content_residual(p);
304  soil_data.Qs = this->eq_fields_->water_content_saturated(p);
305  soil_data.Ks = this->eq_fields_->conductivity(p);
306  //soil_data.cut_fraction = 0.99; // set by model
307 
308  this->eq_data_->soil_model_->reset(soil_data);
309  }
310  return genuchten_on;
311  }
312 
313 
315  edge_indices_ = cell.cell_with_other_dh(this->eq_data_->dh_cr_.get()).get_loc_dof_indices();
316  cr_disc_dofs_ = cell.cell_with_other_dh(this->eq_data_->dh_cr_disc_.get()).get_loc_dof_indices();
317 
318  bool genuchten_on = reset_soil_model(cell, p);
319  storativity_ = this->eq_fields_->storativity(p)
320  + this->eq_fields_->extra_storativity(p);
321  VectorMPI water_content_vec = this->eq_fields_->water_content_ptr->vec();
322 
323  for (unsigned int i=0; i<cell.elm()->n_sides(); i++) {
324  capacity = 0;
325  water_content = 0;
326  phead = this->eq_data_->p_edge_solution.get( edge_indices_[i] );
327 
328  if (genuchten_on) {
329  fadbad::B<double> x_phead(phead);
330  fadbad::B<double> evaluated( this->eq_data_->soil_model_->water_content_diff(x_phead) );
331  evaluated.diff(0,1);
332  water_content = evaluated.val();
333  capacity = x_phead.d(0);
334  }
335  this->eq_data_->capacity.set( cr_disc_dofs_[i], capacity + storativity_ );
336  water_content_vec.set( cr_disc_dofs_[i], water_content + storativity_ * phead);
337  }
338  }
339 
340  /// Precompute conductivity on bulk point.
342  {
343  bool genuchten_on = reset_soil_model(cell, p);
344 
345  double conductivity = 0;
346  if (genuchten_on) {
347  const DHCellAccessor cr_cell = cell.cell_with_other_dh(eq_data_->dh_cr_.get());
348  auto loc_dof_vec = cr_cell.get_loc_dof_indices();
349 
350  for (unsigned int i=0; i<cell.elm()->n_sides(); i++)
351  {
352  double phead = eq_data_->p_edge_solution.get( loc_dof_vec[i] );
353  conductivity += eq_data_->soil_model_->conductivity(phead);
354  }
355  conductivity /= cell.elm()->n_sides();
356  }
357  else {
358  conductivity = eq_fields_->conductivity(p);
359  }
360  return conductivity;
361  }
362 
363 
364  /// Postprocess velocity after calculating of cell integral.
366  {
367  this->postprocess_velocity(dh_cell, p);
368 
369  this->update_water_content(dh_cell, p);
370 
371  VectorMPI water_content_vec = eq_fields_->water_content_ptr->vec();
372 
373  for (unsigned int i=0; i<dh_cell.elm()->n_sides(); i++) {
374  water_content = water_content_vec.get( this->cr_disc_dofs_[i] );
375  water_content_previous_time = eq_data_->water_content_previous_time.get( this->cr_disc_dofs_[i] );
376 
377  solution[eq_data_->loc_side_dofs[dim-1][i]]
378  += this->edge_source_term_ - this->edge_scale_ * (water_content - water_content_previous_time) / eq_data_->time_step_;
379  }
380 
381  IntIdx p_dof = dh_cell.cell_with_other_dh(eq_data_->dh_p_.get()).get_loc_dof_indices()(0);
382  eq_fields_->conductivity_ptr->vec().set( p_dof, compute_conductivity(dh_cell, p) );
383  }
384 
385 
386  /// Data objects shared with ConvectionTransport
389 
390  LocDofVec cr_disc_dofs_; ///< Vector of local DOF indices pre-computed on different DOF handlers
391  LocDofVec edge_indices_; ///< Dofs of discontinuous fields on element edges.
392  double storativity_;
393  double capacity, phead;
394  double water_content, water_content_previous_time;
395  double diagonal_coef_, source_diagonal_;
396  double water_content_diff_, mass_diagonal_, mass_rhs_;
397 
398  template < template<IntDim...> class DimAssembly>
399  friend class GenericAssembly;
400 };
401 
402 
403 template <unsigned int dim, class TEqData>
405 {
406 public:
407  typedef typename TEqData::EqFields EqFields;
408  typedef TEqData EqData;
409 
410  static constexpr const char * name() { return "Richards_ReconstructSchur_Assembly"; }
411 
413  : MHMatrixAssemblyRichards<dim, TEqData>(eq_data, patch_internals) {
414  }
415 
416  /// Integral over element.
417  inline void cell_integral(DHCellAccessor cell, unsigned int element_patch_idx)
418  {
419  ASSERT_EQ(cell.dim(), dim).error("Dimension of element mismatch!");
420 
421  // evaluation point
422  auto p = *( this->bulk_integral_->points(element_patch_idx).begin() );
423  this->bulk_local_idx_ = cell.local_idx();
424 
425  { // postprocess the velocity
426  this->eq_data_->postprocess_solution_[this->bulk_local_idx_].zeros(this->eq_data_->schur_offset_[dim-1]);
427  this->postprocess_velocity_richards(cell, p, this->eq_data_->postprocess_solution_[this->bulk_local_idx_]);
428  }
429  }
430 
431 
432  /// Assembles between boundary element and corresponding side on bulk element.
434  {}
435 
436  inline void dimjoin_intergral(FMT_UNUSED DHCellAccessor cell_lower_dim, FMT_UNUSED DHCellSide neighb_side)
437  {}
438 
439 
440  /// Implements @p AssemblyBase::begin.
441  void begin() override
442  {
443  this->begin_reconstruct_schur();
444  }
445 
446 
447  /// Implements @p AssemblyBase::end.
448  void end() override
449  {
450  this->end_reconstruct_schur();
451  }
452 protected:
453  template < template<IntDim...> class DimAssembly>
454  friend class GenericAssembly;
455 };
456 
457 
458 
459 #endif /* ASSEMBLY_RICHARDS_HH_ */
460 
#define ASSERT_EQ(a, b)
Definition of comparative assert macro (EQual) only for debug mode.
Definition: asserts.hh:333
std::shared_ptr< BulkIntegralAcc< dim > > create_bulk_integral(Quadrature *quad)
Quadrature * quad_
Quadrature used in assembling methods.
ElementAccessor< 3 > element_accessor()
Base point accessor class.
Cell accessor allow iterate over DOF handler cells.
bool is_own() const
Return true if accessor represents own element (false for ghost element)
LocDofVec get_loc_dof_indices() const
Returns the local indices of dofs associated to the cell on the local process.
DHCellAccessor cell_with_other_dh(const DOFHandlerMultiDim *dh) const
Create new accessor with same local idx and given DOF handler. Actual and given DOF handler must be c...
unsigned int dim() const
Return dimension of element appropriate to cell.
ElementAccessor< 3 > elm() const
Return ElementAccessor to element of loc_ele_idx_.
unsigned int local_idx() const
Return local index to element (index of DOF handler).
Side accessor allows to iterate over sides of DOF handler cell.
Side side() const
Return Side of given cell and side_idx.
Boundary cond() const
const DHCellAccessor & cell() const
Return DHCellAccessor appropriate to the side.
unsigned int dim() const
Return dimension of element appropriate to the side.
double measure() const
Computes the measure of the element.
Region region() const
Definition: accessors.hh:198
unsigned int n_sides() const
Definition: elements.h:131
Container for various descendants of FieldCommonBase.
Definition: field_set.hh:161
Generic class of assemblation.
InitCondPostprocessAssembly(EqData *eq_data, PatchInternals *patch_internals)
Constructor.
FieldSet used_fields_
Sub field set contains fields used in calculation.
std::shared_ptr< BulkIntegralAcc< dim > > bulk_integral_
Bulk integral of assembly class.
void initialize()
Initialize auxiliary vectors and other data members.
bool reset_soil_model(const DHCellAccessor &cell, BulkPoint &p)
LocDofVec edge_indices_
Dofs of discontinuous fields on element edges.
static constexpr const char * name()
void cell_integral(DHCellAccessor cell, unsigned int element_patch_idx)
LocDofVec cr_disc_dofs_
Vector of local DOF indices pre-computed on different DOF handlers.
EqFields * eq_fields_
Data objects shared with ConvectionTransport.
void end() override
Implements AssemblyBase::end.
void begin() override
Implements AssemblyBase::begin.
void asm_sides(BulkPoint &p, double conductivity, unsigned int element_patch_idx)
Part of cell_integral method, common in all descendants.
void begin_mh_matrix()
Common code of begin method of MH matrix assembly (Darcy and Richards)
void end_reconstruct_schur()
Common code of end method of Reconstruct Schur assembly (Darcy and Richards)
void begin_reconstruct_schur()
Common code of begin method of Reconstruct Schur assembly (Darcy and Richards)
FieldSet used_fields_
Sub field set contains fields used in calculation.
unsigned int bulk_local_idx_
Local idx of bulk element.
void initialize()
Initialize auxiliary vectors and other data members.
void boundary_side_integral_in(DHCellSide cell_side, const ElementAccessor< 3 > &b_ele, BulkPoint &p_bdr)
void asm_element()
Part of cell_integral method, common in all descendants.
DarcyLMH::EqFields::BC_Type type_
Type of boundary condition.
void end_mh_matrix()
Common code of end method of MH matrix assembly (Darcy and Richards)
std::shared_ptr< BulkIntegralAcc< dim > > bulk_integral_
Bulk integral of assembly class.
void use_dirichlet_switch(DHCellSide &cell_side, const ElementAccessor< 3 > &b_ele, BulkPoint &p_bdr)
Update BC switch dirichlet in MH matrix assembly if BC type is seepage.
std::shared_ptr< BoundaryIntegralAcc< dim > > bdr_integral_
Boundary integral of assembly class.
void precompute_boundary_side(DHCellSide &cell_side, BoundaryPoint &p_side, BulkPoint &p_bdr)
Precompute values used in boundary side integral on given DHCellSide.
void boundary_side_integral(DHCellSide cell_side)
Assembles between boundary element and corresponding side on bulk element.
void asm_source_term_richards(const DHCellAccessor &cell, BulkPoint &p)
Part of cell_integral method, specialized in Richards equation.
~MHMatrixAssemblyRichards()
Destructor.
bool reset_soil_model(const DHCellAccessor &cell, BulkPoint &p)
void update_water_content(const DHCellAccessor &cell, BulkPoint &p)
void initialize()
Initialize auxiliary vectors and other data members.
void end() override
Implements AssemblyBase::end.
void cell_integral(DHCellAccessor cell, unsigned int element_patch_idx)
Integral over element.
double compute_conductivity(const DHCellAccessor &cell, BulkPoint &p)
Precompute conductivity on bulk point.
void postprocess_velocity_richards(const DHCellAccessor &dh_cell, BulkPoint &p, arma::vec &solution)
Postprocess velocity after calculating of cell integral.
LocDofVec edge_indices_
Dofs of discontinuous fields on element edges.
EqFields * eq_fields_
Data objects shared with ConvectionTransport.
LocDofVec cr_disc_dofs_
Vector of local DOF indices pre-computed on different DOF handlers.
static constexpr const char * name()
MHMatrixAssemblyRichards(EqData *eq_data, PatchInternals *patch_internals)
void begin() override
Implements AssemblyBase::begin.
void end() override
Implements AssemblyBase::end.
void boundary_side_integral(FMT_UNUSED DHCellSide cell_side)
Assembles between boundary element and corresponding side on bulk element.
ReconstructSchurAssemblyRichards(EqData *eq_data, PatchInternals *patch_internals)
void cell_integral(DHCellAccessor cell, unsigned int element_patch_idx)
Integral over element.
static constexpr const char * name()
void dimjoin_intergral(FMT_UNUSED DHCellAccessor cell_lower_dim, FMT_UNUSED DHCellSide neighb_side)
void begin() override
Implements AssemblyBase::begin.
unsigned int bulk_idx() const
Returns index of the region in the bulk set.
Definition: region.hh:90
Boundary cond() const
double get(unsigned int pos) const
Return value on given position.
Definition: vector_mpi.hh:108
void set(unsigned int pos, double val)
Set value on given position.
Definition: vector_mpi.hh:114
@ result_zeros
int IntIdx
Definition: index_types.hh:25
arma::Col< IntIdx > LocDofVec
Definition: index_types.hh:28
unsigned int IntDim
A dimension index type.
Definition: mixed.hh:19
ArmaVec< double, N > vec
Definition: armor.hh:933
#define FMT_UNUSED
Definition: posix.h:75
Holds common data shared between GenericAssemblz and Assembly<dim> classes.
double Ks
Definition: soil_models.hh:45
double Qr
Definition: soil_models.hh:42
double n
Definition: soil_models.hh:40
double alpha
Definition: soil_models.hh:41
double Qs
Definition: soil_models.hh:43