28 #include "petscviewer.h"
29 #include "petscerror.h"
85 .
add_value(
MortarP1,
"P1",
"Mortar space: P1 on intersections, using non-conforming pressures.")
95 "Boundary piezometric head for BC types: dirichlet, robin, and river." )
97 "Boundary switch piezometric head for BC types: seepage, river." )
99 "Initial condition for the pressure given as the piezometric head." )
101 return field_descriptor;
107 "Linear solver for MH problem.")
109 "Residual tolerance.")
111 "Minimum number of iterations (linear solutions) to use.\nThis is usefull if the convergence criteria "
112 "does not characterize your goal well enough so it converges prematurely, possibly even without a single linear solution."
113 "If greater then 'max_it' the value is set to 'max_it'.")
115 "Maximum number of iterations (linear solutions) of the non-linear solver.")
117 "If a stagnation of the nonlinear solver is detected the solver stops. "
118 "A divergence is reported by default, forcing the end of the simulation. By setting this flag to 'true', the solver "
119 "ends with convergence success on stagnation, but it reports warning about it.")
129 "Vector of the gravity force. Dimensionless.")
131 "Input data for Darcy flow model.")
133 "Non-linear solver for MH problem.")
135 "Output stream settings.\n Specify file format, precision etc.")
138 IT::Default(
"{ \"fields\": [ \"pressure_p0\", \"velocity_p0\" ] }"),
139 "Specification of output fields and output times.")
141 "Output settings specific to Darcy flow model.\n"
142 "Includes raw output and some experimental functionality.")
144 "Settings for computing mass balance.")
146 "Method for coupling Darcy flow between dimensions on incompatible meshes. [Experimental]" )
152 Input::register_class< DarcyLMH, Mesh &, const Input::Record >(equation_name()) +
162 .
description(
"Pressure solution - P0 interpolation.");
167 .
description(
"Pressure solution - Crouzeix-Raviart interpolation.");
172 .
description(
"Piezo head solution - P0 interpolation.");
177 .
description(
"Velocity solution - P0 interpolation.");
185 .
description(
"Anisotropy of the conductivity tensor.")
190 .
description(
"Complement dimension parameter (cross section for 1D, thickness for 2D).")
201 .
description(
"Transition coefficient between dimensions.")
211 .
description(
"Water source transition coefficient.")
229 .description(
"Prescribed pressure value on the boundary. Used for all values of ``bc_type`` except ``none`` and ``seepage``. "
230 "See documentation of ``bc_type`` for exact meaning of ``bc_pressure`` in individual boundary condition types.")
231 .input_default(
"0.0")
237 .description(
"Incoming water boundary flux. Used for bc_types : ``total_flux``, ``seepage``, ``river``.")
238 .input_default(
"0.0")
239 .units(
UnitSI().m().s(-1) );
243 .name(
"bc_robin_sigma")
244 .description(
"Conductivity coefficient in the ``total_flux`` or the ``river`` boundary condition type.")
245 .input_default(
"0.0")
250 .name(
"bc_switch_pressure")
251 .description(
"Critical switch pressure for ``seepage`` and ``river`` boundary conditions.")
252 .input_default(
"0.0")
258 .
description(
"Initial condition for pressure in time dependent problems.")
263 .
description(
"Storativity (in time dependent problems).")
268 .
description(
"Storativity added from upstream equation.")
274 .
description(
"Water source density added from upstream equation.")
308 .
description(
"Precomputed pressure of l2 difference output.");
314 .
description(
"Precomputed velocity of l2 difference output.");
320 .
description(
"Precomputed divergence of l2 difference output.");
333 "Homogeneous Neumann boundary condition\n(zero normal flux over the boundary).")
335 "Dirichlet boundary condition. "
336 "Specify the pressure head through the ``bc_pressure`` field "
337 "or the piezometric head through the ``bc_piezo_head`` field.")
338 .
add_value(total_flux,
"total_flux",
"Flux boundary condition (combines Neumann and Robin type). "
339 "Water inflow equal to (($ \\delta_d(q_d^N + \\sigma_d (h_d^R - h_d) )$)). "
340 "Specify the water inflow by the ``bc_flux`` field, the transition coefficient by ``bc_robin_sigma`` "
341 "and the reference pressure head or piezometric head through ``bc_pressure`` or ``bc_piezo_head`` respectively.")
343 "Seepage face boundary condition. Pressure and inflow bounded from above. Boundary with potential seepage flow "
344 "is described by the pair of inequalities: "
345 "(($h_d \\le h_d^D$)) and (($ -\\boldsymbol q_d\\cdot\\boldsymbol n \\le \\delta q_d^N$)), where the equality holds in at least one of them. "
346 "Caution: setting (($q_d^N$)) strictly negative "
347 "may lead to an ill posed problem since a positive outflow is enforced. "
348 "Parameters (($h_d^D$)) and (($q_d^N$)) are given by the fields ``bc_switch_pressure`` (or ``bc_switch_piezo_head``) and ``bc_flux`` respectively."
351 "River boundary condition. For the water level above the bedrock, (($H_d > H_d^S$)), the Robin boundary condition is used with the inflow given by: "
352 "(( $ \\delta_d(q_d^N + \\sigma_d(H_d^D - H_d) )$)). For the water level under the bedrock, constant infiltration is used: "
353 "(( $ \\delta_d(q_d^N + \\sigma_d(H_d^D - H_d^S) )$)). Parameters: ``bc_pressure``, ``bc_switch_pressure``, "
354 " ``bc_sigma``, ``bc_flux``."
369 auto size = dh_p_->get_local_to_global_map().size();
370 save_local_system_.resize(
size);
371 bc_fluxes_reconstruted.resize(
size);
372 loc_system_.resize(
size);
373 postprocess_solution_.resize(
size);
379 std::fill(save_local_system_.begin(), save_local_system_.end(),
false);
380 std::fill(bc_fluxes_reconstruted.begin(), bc_fluxes_reconstruted.end(),
false);
421 MessageOut() <<
"Duplicate key 'time', time in flow equation is already initialized from parent class!";
461 return next_t * (1 - 2*std::numeric_limits<double>::epsilon());
482 gravity_array.copy_to(gvec);
488 auto field_algo=std::make_shared<FieldConstant<3, FieldValue<3>::VectorFixed>>();
489 field_algo->set_value(gvalue);
490 eq_fields_->gravity_field.set(field_algo, 0.0);
510 MessageOut() <<
"Missing the key 'time', obligatory for the transient problems." << endl;
521 std::shared_ptr< FiniteElement<1> > fe1_rt = std::make_shared<FE_RT0_disc<1>>();
522 std::shared_ptr< FiniteElement<2> > fe2_rt = std::make_shared<FE_RT0_disc<2>>();
523 std::shared_ptr< FiniteElement<3> > fe3_rt = std::make_shared<FE_RT0_disc<3>>();
524 std::shared_ptr< FiniteElement<0> > fe0_disc = std::make_shared<FE_P_disc<0>>(0);
525 std::shared_ptr< FiniteElement<1> > fe1_disc = std::make_shared<FE_P_disc<1>>(0);
526 std::shared_ptr< FiniteElement<2> > fe2_disc = std::make_shared<FE_P_disc<2>>(0);
527 std::shared_ptr< FiniteElement<3> > fe3_disc = std::make_shared<FE_P_disc<3>>(0);
528 std::shared_ptr< FiniteElement<0> > fe0_cr = std::make_shared<FE_CR<0>>();
529 std::shared_ptr< FiniteElement<1> > fe1_cr = std::make_shared<FE_CR<1>>();
530 std::shared_ptr< FiniteElement<2> > fe2_cr = std::make_shared<FE_CR<2>>();
531 std::shared_ptr< FiniteElement<3> > fe3_cr = std::make_shared<FE_CR<3>>();
533 FESystem<0> fe0_sys( {fe0_disc, fe0_disc, fe0_cr} );
539 std::shared_ptr<DiscreteSpace> ds = std::make_shared<EqualOrderDiscreteSpace>(
mesh_, fe_sys);
540 eq_data_->dh_ = std::make_shared<DOFHandlerMultiDim>(*
mesh_);
550 uint rt_component = 0;
552 auto ele_flux_ptr = create_field_fe<3, FieldValue<3>::VectorFixed>(
eq_data_->dh_, &
eq_data_->full_solution, rt_component);
557 uint p_ele_component = 1;
559 eq_fields_->field_ele_pressure.set(ele_pressure_ptr, 0.0);
561 uint p_edge_component = 2;
563 eq_fields_->field_edge_pressure.set(edge_pressure_ptr, 0.0);
572 uint p_element_component = 1;
573 eq_data_->dh_p_ = std::make_shared<SubDOFHandlerMultiDim>(
eq_data_->dh_,p_element_component);
577 uint p_edge_component = 2;
578 eq_data_->dh_cr_ = std::make_shared<SubDOFHandlerMultiDim>(
eq_data_->dh_,p_edge_component);
583 std::shared_ptr<DiscreteSpace> ds_cr_disc = std::make_shared<EqualOrderDiscreteSpace>(
mesh_, fe_cr_disc);
584 eq_data_->dh_cr_disc_ = std::make_shared<DOFHandlerMultiDim>(*
mesh_);
585 eq_data_->dh_cr_disc_->distribute_dofs(ds_cr_disc);
596 eq_data_->p_edge_solution_previous_time =
eq_data_->dh_cr_->create_vector();
605 .val<Input::AbstractRecord>(
"linear_solver");
684 eq_data_->p_edge_solution.zero_entries();
686 if (
eq_data_->use_steady_assembly_) {
687 MessageOut() <<
"Flow zero time step - steady case\n";
691 MessageOut() <<
"Flow zero time step - unsteady case\n";
723 eq_data_->full_solution.local_to_ghost_begin();
724 eq_data_->full_solution.local_to_ghost_end();
732 bool jump_time =
eq_fields_->storativity.is_jump_time();
733 if (! zero_time_term_from_left) {
734 MessageOut() <<
"Flow time step - unsteady case\n";
739 eq_data_->use_steady_assembly_ =
false;
745 WarningOut() <<
"Output of solution discontinuous in time not supported yet.\n";
754 if (! zero_time_term_from_left && ! jump_time && output)
761 if (zero_time_term_from_right) {
762 MessageOut() <<
"Flow time step - steady case\n";
764 eq_data_->use_steady_assembly_ =
true;
769 }
else if (! zero_time_term_from_left && jump_time) {
770 WarningOut() <<
"Discontinuous time term not supported yet.\n";
781 return (
eq_fields_->storativity.input_list_size() == 0);
794 MessageOut().fmt(
"[nonlinear solver] norm of initial residual: {}\n", residual_norm);
797 int is_linear_common;
802 this->
max_n_it_ = nl_solver_rec.
val<
unsigned int>(
"max_it");
803 this->
min_n_it_ = nl_solver_rec.
val<
unsigned int>(
"min_it");
804 if (this->min_n_it_ > this->max_n_it_) this->min_n_it_ = this->
max_n_it_;
806 if (! is_linear_common) {
812 while (
eq_data_->nonlinear_iteration_ < this->min_n_it_ ||
813 (residual_norm > this->tolerance_ &&
eq_data_->nonlinear_iteration_ < this->max_n_it_ )) {
815 convergence_history.push_back(residual_norm);
819 if (convergence_history.size() >= 5 &&
820 convergence_history[ convergence_history.size() - 1]/convergence_history[ convergence_history.size() - 2] > 0.9 &&
821 convergence_history[ convergence_history.size() - 1]/convergence_history[ convergence_history.size() - 5] > 0.8) {
824 WarningOut().fmt(
"Accept solution on stagnation. Its: {} Residual: {}\n",
eq_data_->nonlinear_iteration_, residual_norm);
827 THROW(ExcSolverDiverge() << EI_Reason(
"Stagnation."));
831 if (! is_linear_common){
833 eq_data_->p_edge_solution_previous.local_to_ghost_begin();
834 eq_data_->p_edge_solution_previous.local_to_ghost_end();
838 MessageOut().fmt(
"[schur solver] lin. it: {}, reason: {}, residual: {}\n",
844 if (is_linear_common){
847 MessageOut().fmt(
"[nonlinear solver] lin. it: {}, reason: {}, residual: {}\n",
854 VecAXPBY(
eq_data_->p_edge_solution.petsc_vec(), (1-alpha), alpha,
eq_data_->p_edge_solution_previous.petsc_vec());
861 MessageOut().fmt(
"[nonlinear solver] it: {} lin. it: {}, reason: {}, residual: {}\n",
871 if (
eq_data_->nonlinear_iteration_ < 3) mult = 1.6;
872 if (
eq_data_->nonlinear_iteration_ > 7) mult = 0.7;
882 eq_data_->p_edge_solution_previous_time.copy_from(
eq_data_->p_edge_solution);
883 eq_data_->p_edge_solution_previous_time.local_to_ghost_begin();
884 eq_data_->p_edge_solution_previous_time.local_to_ghost_end();
949 double zeros[100000];
950 for(
int i=0; i<100000; i++) zeros[i] = 0.0;
953 tmp_rows.reserve(200);
956 dofs.reserve(
eq_data_->dh_cr_->max_elem_dofs());
957 dofs_ngh.reserve(
eq_data_->dh_cr_->max_elem_dofs());
963 const uint ndofs = dh_cell.n_dofs();
964 dofs.resize(dh_cell.n_dofs());
965 dh_cell.get_dof_indices(dofs);
967 int* dofs_ptr = dofs.
data();
974 for (
DHCellSide neighb_side : dh_cell.neighb_sides() ) {
982 const uint ndofs_ngh = dh_neighb_cell.
n_dofs();
983 dofs_ngh.resize(ndofs_ngh);
987 tmp_rows.push_back(dofs_ngh[neighb_side.side().side_idx()]);
1147 eq_data_->lin_sys_schur = std::make_shared<LinSys_PETSC>( &(*
eq_data_->dh_cr_->distr()) );
1221 eq_data_->full_solution.zero_entries();
1222 eq_data_->p_edge_solution.zero_entries();
1226 THROW( ExcUnknownSolver() );
1264 eq_data_->p_edge_solution.local_to_ghost_begin();
1265 eq_data_->p_edge_solution.local_to_ghost_end();
1299 std::string output_file;
1302 double d_max = std::numeric_limits<double>::max();
1303 double h1 = d_max, h2 = d_max, h3 = d_max;
1304 double he2 = d_max, he3 = d_max;
1307 case 1: h1 = std::min(h1,ele.measure());
break;
1308 case 2: h2 = std::min(h2,ele.measure());
break;
1309 case 3: h3 = std::min(h3,ele.measure());
break;
1312 for (
unsigned int j=0; j<ele->n_sides(); j++) {
1314 case 2: he2 = std::min(he2, ele.side(j)->measure());
break;
1315 case 3: he3 = std::min(he3, ele.side(j)->measure());
break;
1319 if(h1 == d_max) h1 = 0;
1320 if(h2 == d_max) h2 = 0;
1321 if(h3 == d_max) h3 = 0;
1322 if(he2 == d_max) he2 = 0;
1323 if(he3 == d_max) he3 = 0;
1326 file = fopen(output_file.c_str(),
"a");
1328 fprintf(file,
"nB = %d;\n",
eq_data_->dh_->mesh()->get_el_ds()->size());
1330 fprintf(file,
"h1 = %e;\nh2 = %e;\nh3 = %e;\n", h1, h2, h3);
1331 fprintf(file,
"he2 = %e;\nhe3 = %e;\n", he2, he3);
1337 PetscViewerASCIIOpen(PETSC_COMM_WORLD, output_file.c_str(), &viewer);
1338 PetscViewerSetFormat(viewer, PETSC_VIEWER_ASCII_MATLAB);
1339 MatView( *
const_cast<Mat*
>(
lin_sys_schur().get_matrix()), viewer);
1340 VecView( *
const_cast<Vec*
>(
lin_sys_schur().get_rhs()), viewer);
1341 VecView( *
const_cast<Vec*
>(&(
lin_sys_schur().get_solution())), viewer);
1342 VecView( *
const_cast<Vec*
>(&(
eq_data_->full_solution.petsc_vec())), viewer);
1539 if(
time_ !=
nullptr)
1558 void dofs_range(
unsigned int n_dofs,
unsigned int &min,
unsigned int &max,
unsigned int component) {
1562 }
else if (component==1) {
1573 ASSERT_LT(component, 3).error(
"Invalid component!");
1574 unsigned int i, n_dofs, min, max;
1578 n_dofs = dh_cell.get_dof_indices(dof_indices);
1580 for (i=min; i<max; ++i) dof_vec.push_back(dof_indices[i]);
Functors of FieldModels used in Darcy flow module.
#define ASSERT_PERMANENT(expr)
Allow use shorter versions of macro names if these names is not used with external library.
#define ASSERT_LT(a, b)
Definition of comparative assert macro (Less Than) only for debug mode.
#define ASSERT_EQ(a, b)
Definition of comparative assert macro (EQual) only for debug mode.
static const Input::Type::Record & get_input_type()
Main balance input record type.
Cell accessor allow iterate over DOF handler cells.
unsigned int n_dofs() const
Return number of dofs on given cell.
unsigned int get_dof_indices(std::vector< LongIdx > &indices) const
Fill vector of the global indices of dofs associated to the cell.
Side accessor allows to iterate over sides of DOF handler cell.
static Input::Type::Abstract & get_input_type()
MortarMethod
Type of experimental Mortar-like method for non-compatible 1d-2d interaction.
static const Input::Type::Instance & get_input_type_specific()
void output()
Calculate values for output.
static const Input::Type::Instance & get_input_type(FieldSet &eq_data, const std::string &equation_name)
EqData(shared_ptr< EqFields > eq_fields)
void reset()
Reset data members.
MortarMethod mortar_method_
void init()
Initialize vectors, ...
Field< 3, FieldValue< 3 >::Scalar > water_source_density
Field< 3, FieldValue< 3 >::Scalar > ref_divergence
Field< 3, FieldValue< 3 >::Scalar > extra_storativity
Field< 3, FieldValue< 3 >::Scalar > field_ele_pressure
Externally added water source.
BCField< 3, FieldValue< 3 >::Enum > bc_type
Field< 3, FieldValue< 3 >::VectorFixed > gravity_field
Field< 3, FieldValue< 3 >::Scalar > sigma
Field< 3, FieldValue< 3 >::Scalar > init_pressure
Field< 3, FieldValue< 3 >::Scalar > storativity
BCField< 3, FieldValue< 3 >::Scalar > bc_pressure
BCField< 3, FieldValue< 3 >::Scalar > bc_flux
Field< 3, FieldValue< 3 >::TensorFixed > anisotropy
Field< 3, FieldValue< 3 >::Scalar > water_source_sigma
Field< 3, FieldValue< 3 >::Scalar > cross_section
Field< 3, FieldValue< 3 >::Scalar > conductivity
Field< 3, FieldValue< 3 >::VectorFixed > field_ele_velocity
Field< 3, FieldValue< 3 >::Scalar > field_edge_pressure
BCField< 3, FieldValue< 3 >::Scalar > bc_switch_piezo_head
Field< 3, FieldValue< 3 >::Scalar > field_ele_piezo_head
Field< 3, FieldValue< 3 >::Scalar > init_piezo_head
Same as previous but used in boundary fields.
Field< 3, FieldValue< 3 >::Scalar > water_source_ref_pressure
BCField< 3, FieldValue< 3 >::Scalar > bc_robin_sigma
static const Input::Type::Selection & get_bc_type_selection()
Return a Selection corresponding to enum BC_Type.
Field< 3, FieldValue< 3 >::Scalar > extra_source
Externally added storativity.
Field< 3, FieldValue< 3 >::VectorFixed > ref_velocity
Precompute l2 difference outputs.
Field< 3, FieldValue< 3 >::VectorFixed > flux
EqFields()
Creation of all fields.
BCField< 3, FieldValue< 3 >::Scalar > bc_switch_pressure
BCField< 3, FieldValue< 3 >::VectorFixed > bc_gravity
Holds gravity vector acceptable in FieldModel.
BCField< 3, FieldValue< 3 >::Scalar > bc_piezo_head
Field< 3, FieldValue< 3 >::Scalar > ref_pressure
GenericAssemblyBase * mh_matrix_assembly_
void initialize() override
void print_matlab_matrix(string matlab_file)
Print darcy flow matrix in matlab format into a file.
virtual double solved_time() override
void zero_time_step() override
virtual void postprocess()
void solve_nonlinear()
Solve method common to zero_time_step and update solution.
static std::string equation_name()
virtual void initialize_specific()
static const int registrar
Registrar of class to factory.
DarcyFlowMHOutput * output_object
std::shared_ptr< EqData > eq_data_
GenericAssemblyBase * reconstruct_schur_assembly_
virtual void initialize_asm()
Create and initialize assembly objects.
void update_solution() override
void allocate_mh_matrix()
void solve_time_step(bool output=true)
Solve the problem without moving to next time and without output.
std::vector< int > get_component_indices_vec(unsigned int component) const
Get vector of all DOF indices of given component (0..side, 1..element, 2..edge)
static const Input::Type::Record & type_field_descriptor()
void create_linear_system(Input::AbstractRecord rec)
static const Input::Type::Record & get_input_type()
DarcyLMH(Mesh &mesh, const Input::Record in_rec, TimeGovernor *tm=nullptr)
CREATE AND FILL GLOBAL MH MATRIX OF THE WATER MODEL.
friend class DarcyFlowMHOutput
virtual bool zero_time_term(bool time_global=false)
std::shared_ptr< EqFields > eq_fields_
static const Input::Type::Selection & get_mh_mortar_selection()
Selection for enum MortarMethod.
std::shared_ptr< Balance > balance_
virtual void accept_time_step()
postprocess velocity field (add sources)
virtual ~DarcyLMH() override
virtual void output_data() override
Write computed fields.
GenericAssembly< ReadInitCondAssemblyLMHDim > * read_init_cond_assembly_
general assembly objects, hold assembly objects of appropriate dimension
LinSys & lin_sys_schur()
Getter for the linear system of the 2. Schur complement.
virtual void assembly_linear_system()
virtual void read_init_cond_asm()
Call assemble of read_init_cond_assembly_.
unsigned int n_neighs_vb() const
Return number of neighbours.
Input::Record input_record_
static Input::Type::Record & record_template()
Template Record with common keys for derived equations.
std::shared_ptr< FieldSet > eq_fieldset_
static Input::Type::Record & user_fields_template(std::string equation_name)
Template Record with common key user_fields for derived equations.
Compound finite element on dim dimensional simplex.
static const std::string field_descriptor_record_description(const string &record_name)
FieldCommon & input_selection(Input::Type::Selection element_selection)
FieldCommon & description(const string &description)
FieldCommon & flags(FieldFlag::Flags::Mask mask)
FieldCommon & name(const string &name)
FieldCommon & set_limits(double min, double max=std::numeric_limits< double >::max())
FieldCommon & units(const UnitSI &units)
Set basic units of the field.
FieldCommon & input_default(const string &input_default)
static constexpr Mask input_copy
static constexpr Mask equation_result
Match result fields. These are never given by input or copy of input.
void set_default_fieldset()
auto disable_where(const Field< spacedim, typename FieldValue< spacedim >::Enum > &control_field, const vector< FieldEnum > &value_list) -> Field &
Dedicated class for storing path to input and output files.
virtual void assemble(std::shared_ptr< DOFHandlerMultiDim > dh)=0
Generic class of assemblation.
static const Input::Type::Record & get_input_type()
void set_solution(Vec sol_vec)
void set_matrix_changed()
virtual void set_from_input(const Input::Record in_rec)
virtual void start_add_assembly()
virtual void finish_assembly()=0
virtual void set_tolerances(double r_tol, double a_tol, double d_tol, unsigned int max_it)=0
virtual void mat_set_values(int nrow, int *rows, int ncol, int *cols, double *vals)=0
virtual double compute_residual()=0
void set_symmetric(bool flag=true)
virtual PetscErrorCode rhs_zero_entries()
virtual void start_allocation()
virtual SolveInfo solve()=0
void set_positive_definite(bool flag=true)
virtual PetscErrorCode mat_zero_entries()
static Input::Type::Abstract & get_input_type()
const RegionDB & region_db() const
unsigned int n_edges() const
unsigned int n_elements() const
Range< ElementAccessor< 3 > > elements_range() const
Returns range of mesh elements.
BCMesh * bc_mesh() const override
Implement MeshBase::bc_mesh(), getter of boundary mesh.
MixedMeshIntersections & mixed_intersections()
unsigned int n_sides() const
static const Input::Type::Record & get_input_type()
The specification of output stream.
RegionSet get_region_set(const std::string &set_name) const
Basic time management functionality for unsteady (and steady) solvers (class Equation).
bool is_end() const
Returns true if the actual time is greater than or equal to the end time.
int set_upper_constraint(double upper, std::string message)
Sets upper constraint for the next time step estimating.
void view(const char *name="") const
double estimate_dt() const
Estimate choice of next time step according to actual setting of constraints.
const TimeStep & step(int index=-1) const
void next_time()
Proceed to the next time according to current estimated time step.
Class for representation SI units of Fields.
static UnitSI & dimensionless()
Returns dimensionless unit.
void dofs_range(unsigned int n_dofs, unsigned int &min, unsigned int &max, unsigned int component)
Helper method fills range (min and max) of given component.
Lumped mixed-hybrid model of linear Darcy flow, possibly unsteady.
Output class for darcy_flow_mh model.
Support classes for parallel programing.
Definitions of basic Lagrangean finite elements with polynomial shape functions.
#define FLOW123D_FORCE_LINK_IN_CHILD(x)
#define THROW(whole_exception_expr)
Wrapper for throw. Saves the throwing point.
Classes with algorithms for computation of intersections of meshes.
Wrappers for linear systems based on MPIAIJ and MATIS format.
Solver based on the original PETSc solver using MPIAIJ matrix and succesive Schur complement construc...
#define WarningOut()
Macro defining 'warning' record of log.
#define MessageOut()
Macro defining 'message' record of log.
#define MPI_Allreduce(sendbuf, recvbuf, count, datatype, op, comm)
FMT_FUNC int fprintf(std::ostream &os, CStringRef format, ArgList args)
Implementation of range helper class.
Assembly explicit Schur complement for the given linear system. Provides method for resolution of the...
#define END_TIMER(tag)
Ends a timer with specified tag.
#define START_TIMER(tag)
Starts a timer with specified tag.
Basic time management class.