8 #ifndef SRC_FLOW_ASSEMBLY_LMH_HH_
9 #define SRC_FLOW_ASSEMBLY_LMH_HH_
82 double water_content = 0;
86 fadbad::B<double> x_phead(phead);
87 fadbad::B<double> evaluated(
soil_model->water_content_diff(x_phead) );
89 water_content = evaluated.val();
90 capacity = x_phead.d(0);
93 ad_->water_content_previous_it[ele.
side_local_idx(i)] = water_content + storativity * phead;
103 double conductivity, head;
110 double phead =
ad_->phead_edge_[local_edge];
111 conductivity +=
soil_model->conductivity(phead);
112 head +=
ad_->phead_edge_[local_edge];
144 if (this->dirichlet_edge[i] == 0) {
146 double capacity = this->
ad_->capacity[local_side];
147 double water_content_diff = -
ad_->water_content_previous_it[local_side] +
ad_->water_content_previous_time[local_side];
148 double mass_diagonal = diagonal_coef * capacity;
162 double mass_rhs = mass_diagonal *
ad_->phead_edge_[local_edge] / this->
ad_->time_step_
163 + diagonal_coef * water_content_diff / this->
ad_->time_step_;
169 this->loc_system_.add_value(this->loc_edge_dofs[i], this->loc_edge_dofs[i],
170 -mass_diagonal/this->
ad_->time_step_,
171 -source_diagonal - mass_rhs);
174 if (
ad_->balance !=
nullptr) {
176 diagonal_coef*
ad_->water_content_previous_it[local_side]);
177 ad_->balance->add_source_vec_values(
ad_->water_balance_idx, ele.
region().
bulk_idx(), {(LongIdx)edge_row}, {source_diagonal});