Flow123d
last_with_con_2.0.0-4-g42e6930
|
Mixed-hybrid of steady Darcy flow with sources and variable density. More...
#include <darcy_flow_mh.hh>
Classes | |
class | EqData |
Public Types | |
enum | MortarMethod { NoMortar = 0, MortarP0 = 1, MortarP1 = 2 } |
Type of experimental Mortar-like method for non-compatible 1d-2d interaction. More... | |
typedef std::vector< std::shared_ptr< AssemblyBase > > | MultidimAssembler |
Public Types inherited from DarcyFlowInterface | |
typedef DarcyFlowInterface | FactoryBaseType |
Typedef for usage of Input::Factory in child classes. More... | |
Public Member Functions | |
TYPEDEF_ERR_INFO (EI_Reason, string) | |
DECLARE_EXCEPTION (ExcSolverDiverge,<< "Diverged nonlinear solver. Reason: "<< EI_Reason::val) | |
DarcyMH (Mesh &mesh, const Input::Record in_rec) | |
CREATE AND FILL GLOBAL MH MATRIX OF THE WATER MODEL. More... | |
const MH_DofHandler & | get_mh_dofhandler () |
void | init_eq_data () |
void | initialize () override |
virtual void | initialize_specific () |
void | zero_time_step () override |
void | update_solution () override |
void | get_solution_vector (double *&vec, unsigned int &vec_size) override |
void | get_parallel_solution_vector (Vec &vector) override |
virtual void | prepare_new_time_step () |
postprocess velocity field (add sources) More... | |
virtual void | postprocess () |
virtual void | output_data () override |
Write computed fields. More... | |
~DarcyMH () | |
Public Member Functions inherited from DarcyFlowInterface | |
DarcyFlowInterface (Mesh &mesh, const Input::Record in_rec) | |
virtual | ~DarcyFlowInterface () |
Public Member Functions inherited from EquationBase | |
EquationBase () | |
EquationBase (Mesh &mesh, const Input::Record in_rec) | |
virtual | ~EquationBase () |
virtual void | choose_next_time () |
virtual void | set_time_upper_constraint (double dt, std::string message) |
virtual void | set_time_lower_constraint (double dt, std::string message) |
TimeGovernor & | time () |
virtual void | set_time_governor (TimeGovernor &time) |
double | planned_time () |
double | solved_time () |
Mesh & | mesh () |
TimeMark::Type | mark_type () |
FieldSet & | data () |
Static Public Member Functions | |
static const Input::Type::Selection & | get_mh_mortar_selection () |
Selection for enum MortarMethod. More... | |
static const Input::Type::Record & | type_field_descriptor () |
static const Input::Type::Record & | get_input_type () |
Static Public Member Functions inherited from DarcyFlowInterface | |
static Input::Type::Abstract & | get_input_type () |
Protected Member Functions | |
virtual bool | zero_time_term () |
void | solve_nonlinear () |
Solve method common to zero_time_step and update solution. More... | |
void | make_serial_scatter () |
void | modify_system () |
virtual void | setup_time_term () |
void | create_linear_system (Input::AbstractRecord rec) |
Initialize global_row_4_sub_row. More... | |
virtual void | read_initial_condition () |
void | assembly_mh_matrix (MultidimAssembler ma) |
virtual void | assembly_source_term () |
Source term is implemented differently in LMH version. More... | |
virtual void | assembly_linear_system () |
void | set_mesh_data_for_bddc (LinSys_BDDC *bddc_ls) |
virtual double | solution_precision () const |
Protected Attributes | |
bool | solution_changed_for_scatter |
MH_DofHandler | mh_dh |
MortarMethod | mortar_method_ |
std::shared_ptr< Balance > | balance_ |
unsigned int | water_balance_idx_ |
index of water balance within the Balance object. More... | |
DarcyFlowMHOutput * | output_object |
int | size |
int | n_schur_compls |
double * | solution |
int | is_linear_ |
bool | use_steady_assembly_ |
double | tolerance_ |
unsigned int | max_n_it_ |
unsigned int | nonlinear_iteration_ |
LinSys * | schur0 |
std::vector< char > | bc_switch_dirichlet |
Idicator of dirichlet or neumann type of switch boundary conditions. More... | |
Vec | sol_vec |
VecScatter | par_to_all |
Vec | steady_diagonal |
Vec | steady_rhs |
Vec | new_diagonal |
Vec | previous_solution |
std::shared_ptr< EqData > | data_ |
Protected Attributes inherited from EquationBase | |
bool | equation_empty_ |
flag is true if only default constructor was called More... | |
Mesh * | mesh_ |
TimeGovernor * | time_ |
Input::Record | input_record_ |
FieldSet * | eq_data_ |
std::shared_ptr< Balance > | balance_ |
object for calculation and writing the mass balance to file. More... | |
Static Private Attributes | |
static const int | registrar |
Registrar of class to factory. More... | |
Friends | |
class | DarcyFlowMHOutput |
class | P0_CouplingAssembler |
class | P1_CouplingAssembler |
Mixed-hybrid of steady Darcy flow with sources and variable density.
solve equations:
where
where is concentration in .
The time key is optional, when not specified the equation is forced to steady regime. Using Steady TimeGovernor which have no dt constraints.
TODO: Make solution regular field (need FeSeystem and parallel DofHandler for edge pressures), then remove get_solution_vector from Equation interface. Model for transition coefficients due to Martin, Jaffre, Roberts (see manual for full reference)
TODO:
Definition at line 140 of file darcy_flow_mh.hh.
typedef std::vector<std::shared_ptr<AssemblyBase> > DarcyMH::MultidimAssembler |
Definition at line 148 of file darcy_flow_mh.hh.
Type of experimental Mortar-like method for non-compatible 1d-2d interaction.
Enumerator | |
---|---|
NoMortar | |
MortarP0 | |
MortarP1 |
Definition at line 207 of file darcy_flow_mh.hh.
DarcyMH::DarcyMH | ( | Mesh & | mesh_in, |
const Input::Record | in_rec | ||
) |
CREATE AND FILL GLOBAL MH MATRIX OF THE WATER MODEL.
Parameters {Solver,NSchurs} number of performed Schur complements (0,1,2) for water flow MH-system
Definition at line 248 of file darcy_flow_mh.cc.
DarcyMH::~DarcyMH | ( | ) |
Definition at line 1503 of file darcy_flow_mh.cc.
|
protectedvirtual |
Assembly or update whole linear system.
Reimplemented in RichardsLMH.
Definition at line 1292 of file darcy_flow_mh.cc.
|
protected |
Part of per element assembly that is specific for MH and LMH respectively.
This implemnets MH case:
Definition at line 637 of file darcy_flow_mh.cc.
|
protectedvirtual |
Source term is implemented differently in LMH version.
Reimplemented in RichardsLMH.
Definition at line 933 of file darcy_flow_mh.cc.
|
protected |
Initialize global_row_4_sub_row.
Create and preallocate MH linear system (including matrix, rhs and solution vectors)
Definition at line 1194 of file darcy_flow_mh.cc.
DarcyMH::DECLARE_EXCEPTION | ( | ExcSolverDiverge | , |
<< "Diverged nonlinear solver. Reason: "<< EI_Reason::val | |||
) |
|
static |
|
inlinevirtual |
Implements DarcyFlowInterface.
Definition at line 224 of file darcy_flow_mh.hh.
|
static |
Selection for enum MortarMethod.
Definition at line 78 of file darcy_flow_mh.cc.
|
overridevirtual |
Child class have to implement getter for parallel solution vector. DEPRECATED
Reimplemented from EquationBase.
Definition at line 618 of file darcy_flow_mh.cc.
|
overridevirtual |
Child class have to implement getter for sequential solution vector. DEPRECATED
Reimplemented from EquationBase.
Definition at line 601 of file darcy_flow_mh.cc.
void DarcyMH::init_eq_data | ( | ) |
|
overridevirtual |
This method should initialize fields of the equation. All members (e.g. number of components) that are necessary for the field initialization must be set between construction and call of initialize. After this method the upper level coupling may set sharing of some fields between equations.
Reimplemented from EquationBase.
Definition at line 317 of file darcy_flow_mh.cc.
|
virtual |
Reimplemented in RichardsLMH.
Definition at line 365 of file darcy_flow_mh.cc.
|
protected |
Definition at line 1523 of file darcy_flow_mh.cc.
|
protected |
Definition at line 1657 of file darcy_flow_mh.cc.
|
overridevirtual |
Write computed fields.
Reimplemented from EquationBase.
Definition at line 568 of file darcy_flow_mh.cc.
|
virtual |
Reimplemented in RichardsLMH.
Definition at line 543 of file darcy_flow_mh.cc.
|
virtual |
postprocess velocity field (add sources)
Reimplemented in RichardsLMH.
Definition at line 538 of file darcy_flow_mh.cc.
|
protectedvirtual |
Read initial condition into solution vector. Must be called after create_linear_system.
For the LMH scheme we have to be able to save edge pressures in order to restart simulation or use results of one simulation as initial condition for other one.
Reimplemented in RichardsLMH.
Definition at line 1601 of file darcy_flow_mh.cc.
|
protected |
type for storage of global to local map
Definition at line 1346 of file darcy_flow_mh.cc.
|
protectedvirtual |
Reimplemented in RichardsLMH.
Definition at line 1618 of file darcy_flow_mh.cc.
|
protectedvirtual |
Return a norm of residual vector. TODO: Introduce Equation::compute_residual() updating residual field, standard part of EqData.
Definition at line 594 of file darcy_flow_mh.cc.
|
protected |
Solve method common to zero_time_step and update solution.
Definition at line 458 of file darcy_flow_mh.cc.
|
static |
DarcyMH::TYPEDEF_ERR_INFO | ( | EI_Reason | , |
string | |||
) |
|
overridevirtual |
Calculation of the next time step and its output.
Reimplemented from EquationBase.
Definition at line 402 of file darcy_flow_mh.cc.
|
overridevirtual |
Initialization of the solution in the zero time.
There may be fields that can not be initialized in the initialize method as they are provided by the coupling. Fields coming from coupling has to be set after the initialize method and before zero_time_step.
Reimplemented from EquationBase.
Definition at line 368 of file darcy_flow_mh.cc.
|
protectedvirtual |
Reimplemented in RichardsLMH.
Definition at line 453 of file darcy_flow_mh.cc.
|
friend |
Definition at line 375 of file darcy_flow_mh.hh.
|
friend |
Definition at line 376 of file darcy_flow_mh.hh.
|
friend |
Definition at line 377 of file darcy_flow_mh.hh.
|
protected |
Definition at line 333 of file darcy_flow_mh.hh.
|
protected |
Idicator of dirichlet or neumann type of switch boundary conditions.
Definition at line 361 of file darcy_flow_mh.hh.
|
protected |
Definition at line 373 of file darcy_flow_mh.hh.
|
protected |
Definition at line 342 of file darcy_flow_mh.hh.
|
protected |
Definition at line 350 of file darcy_flow_mh.hh.
|
protected |
Definition at line 329 of file darcy_flow_mh.hh.
|
protected |
Definition at line 331 of file darcy_flow_mh.hh.
|
protected |
Definition at line 340 of file darcy_flow_mh.hh.
|
protected |
Definition at line 370 of file darcy_flow_mh.hh.
|
protected |
Definition at line 351 of file darcy_flow_mh.hh.
|
protected |
Definition at line 337 of file darcy_flow_mh.hh.
|
protected |
Definition at line 366 of file darcy_flow_mh.hh.
|
protected |
Definition at line 371 of file darcy_flow_mh.hh.
|
staticprivate |
Registrar of class to factory.
Definition at line 381 of file darcy_flow_mh.hh.
|
protected |
Definition at line 354 of file darcy_flow_mh.hh.
|
protected |
Definition at line 339 of file darcy_flow_mh.hh.
|
protected |
Definition at line 365 of file darcy_flow_mh.hh.
|
protected |
Definition at line 341 of file darcy_flow_mh.hh.
|
protected |
Definition at line 327 of file darcy_flow_mh.hh.
|
protected |
Definition at line 368 of file darcy_flow_mh.hh.
|
protected |
Definition at line 369 of file darcy_flow_mh.hh.
|
protected |
Definition at line 349 of file darcy_flow_mh.hh.
|
protected |
Definition at line 346 of file darcy_flow_mh.hh.
|
protected |
index of water balance within the Balance object.
Definition at line 335 of file darcy_flow_mh.hh.