![]() |
OGS
|
|
A mixin providing assembly functionality to a specific Process.
The process must be derived from this class (CRTP).
Definition at line 94 of file AssemblyMixin.h.
#include <AssemblyMixin.h>
Public Member Functions | |
| void | initializeAssemblyOnSubmeshes (std::vector< std::reference_wrapper< MeshLib::Mesh > > const &submeshes, std::vector< std::vector< std::string > > const &residuum_names) |
| void | updateActiveElements () |
| void | assemble (double const t, double const dt, std::vector< GlobalVector * > const &x, std::vector< GlobalVector * > const &x_prev, int const process_id, GlobalMatrix &M, GlobalMatrix &K, GlobalVector &b, std::vector< std::size_t > const *const sorted_element_subset=nullptr, bool const copy_residua_to_mesh=false) |
| void | assembleWithJacobian (double const t, double const dt, std::vector< GlobalVector * > const &x, std::vector< GlobalVector * > const &x_prev, int const process_id, GlobalVector &b, GlobalMatrix &Jac, std::vector< std::size_t > const *const sorted_element_subset=nullptr, bool const copy_residua_to_mesh=false) |
| void | preOutput (double const t, double const dt, std::vector< GlobalVector * > const &x, std::vector< GlobalVector * > const &x_prev, int const process_id) |
Private Member Functions | |
| Process & | derived () |
| Process const & | derived () const |
| std::exception_ptr | assembleOnBulkMeshOrOnSubmeshCommon (Assembly::CommonAssemblyData const &assembly_data, AssembledMatrixCache &mat_cache, double const t, double const dt, std::vector< GlobalVector * > const &x, std::vector< GlobalVector * > const &x_prev, std::vector< NumLib::LocalToGlobalIndexMap const * > const &dof_tables, int const process_id, GlobalMatrix &M, GlobalMatrix &K, GlobalVector &b, std::vector< std::size_t > const *const sorted_element_subset) |
| Common code for Picard assembly on the bulk mesh or on submeshes. | |
| std::exception_ptr | assembleOnBulkMesh (double const t, double const dt, std::vector< GlobalVector * > const &x, std::vector< GlobalVector * > const &x_prev, std::vector< NumLib::LocalToGlobalIndexMap const * > const &dof_tables, int const process_id, GlobalMatrix &M, GlobalMatrix &K, GlobalVector &b, std::vector< std::size_t > const *const sorted_element_subset) |
| std::exception_ptr | assembleOnSubmeshes (double const t, double const dt, std::vector< GlobalVector * > const &x, std::vector< GlobalVector * > const &x_prev, std::vector< NumLib::LocalToGlobalIndexMap const * > const &dof_tables, int const process_id, GlobalMatrix &M, GlobalMatrix &K, GlobalVector &b, std::vector< std::size_t > const *const sorted_element_subset, bool const copy_residua_to_mesh) |
| std::exception_ptr | assembleWithJacobianOnBulkMeshOrOnSubmeshCommon (Assembly::CommonAssemblyData const &assembly_data, double const t, double const dt, std::vector< GlobalVector * > const &x, std::vector< GlobalVector * > const &x_prev, std::vector< NumLib::LocalToGlobalIndexMap const * > const &dof_tables, int const process_id, GlobalVector &b, GlobalMatrix &Jac, std::vector< std::size_t > const *const sorted_element_subset) |
| std::exception_ptr | assembleWithJacobianOnSubmeshes (double const t, double const dt, std::vector< GlobalVector * > const &x, std::vector< GlobalVector * > const &x_prev, std::vector< NumLib::LocalToGlobalIndexMap const * > const &dof_tables, int const process_id, GlobalVector &b, GlobalMatrix &Jac, std::vector< std::size_t > const *const sorted_element_subset, bool const) |
| void | preOutputPicard (double const t, double const dt, std::vector< GlobalVector * > const &x, std::vector< GlobalVector * > const &x_prev, int const process_id) |
| void | preOutputNewton (double const, double const, std::vector< GlobalVector * > const &, std::vector< GlobalVector * > const &, int const) |
| AssemblyMixinBase (AbstractJacobianAssembler &jacobian_assembler, bool const is_linear, bool const use_monolithic_scheme) | |
| Private Member Functions inherited from ProcessLib::AssemblyMixinBase | |
| AssemblyMixinBase (AbstractJacobianAssembler &jacobian_assembler, bool const is_linear, bool const use_monolithic_scheme) | |
| void | initializeAssemblyOnSubmeshes (MeshLib::Mesh &bulk_mesh, std::vector< std::reference_wrapper< MeshLib::Mesh > > const &submeshes, std::vector< std::vector< std::string > > const &residuum_names, std::vector< std::vector< std::reference_wrapper< ProcessVariable > > > const &pvs) |
| void | updateActiveElements (ProcessLib::Process const &process) |
| bool | isLinear () const |
Private Attributes | |
| friend | Process |
| Private Attributes inherited from ProcessLib::AssemblyMixinBase | |
| std::vector< ProcessLib::Assembly::SubmeshAssemblyData > | submesh_assembly_data_ |
| SubmeshAssemblyData for each submesh. | |
| std::vector< AssembledMatrixCache > | submesh_matrix_cache_ |
| AssembledMatrixCache for each submesh. | |
| std::optional< ProcessLib::Assembly::BulkMeshAssemblyData > | bulk_mesh_assembly_data_ |
| Empty if submesh assembly is used. | |
| AssembledMatrixCache | bulk_mesh_matrix_cache_ |
| Assembly::ParallelVectorMatrixAssembler | pvma_ |
| bool | is_linear_ |
| std::optional< NumLib::NonlinearSolverTag > | last_assembly_was_ |
Additional Inherited Members | |
| Static Private Member Functions inherited from ProcessLib::AssemblyMixinBase | |
| static void | copyResiduumVectorsToBulkMesh (GlobalVector const &rhs, NumLib::LocalToGlobalIndexMap const &local_to_global_index_map, std::vector< std::reference_wrapper< MeshLib::PropertyVector< double > > > residuum_vectors) |
| static void | copyResiduumVectorsToSubmesh (int const process_id, GlobalVector const &rhs, NumLib::LocalToGlobalIndexMap const &local_to_global_index_map, ProcessLib::Assembly::SubmeshAssemblyData const &sad) |
|
inline |
Definition at line 140 of file AssemblyMixin.h.
References BaseLib::MPI::anyOf(), assembleOnBulkMesh(), assembleOnSubmeshes(), ProcessLib::AssemblyMixinBase::bulk_mesh_assembly_data_, ProcessLib::computeResiduum(), ProcessLib::AssemblyMixinBase::copyResiduumVectorsToBulkMesh(), DBUG(), derived(), ProcessLib::Process::getDOFTables(), ProcessLib::AssemblyMixinBase::last_assembly_was_, NumLib::Picard, and ProcessLib::AssemblyMixinBase::submesh_assembly_data_.
Referenced by ProcessLib::ComponentTransport::ComponentTransportProcess::assembleConcreteProcess(), ProcessLib::HeatConduction::HeatConductionProcess::assembleConcreteProcess(), ProcessLib::HeatTransportBHE::HeatTransportBHEProcess::assembleConcreteProcess(), ProcessLib::ThermoRichardsFlow::ThermoRichardsFlowProcess::assembleConcreteProcess(), and preOutputPicard().
|
inlineprivate |
Definition at line 327 of file AssemblyMixin.h.
References assembleOnBulkMeshOrOnSubmeshCommon(), ProcessLib::AssemblyMixinBase::bulk_mesh_assembly_data_, ProcessLib::AssemblyMixinBase::bulk_mesh_matrix_cache_, MathLib::LinAlg::copy(), DBUG(), BaseLib::RunTime::elapsed(), INFO(), and BaseLib::RunTime::start().
Referenced by assemble().
|
inlinenodiscardprivate |
Common code for Picard assembly on the bulk mesh or on submeshes.
Definition at line 281 of file AssemblyMixin.h.
References ProcessLib::Assembly::CommonAssemblyData::activeElementIDsSorted(), DBUG(), derived(), BaseLib::RunTime::elapsed(), MathLib::LinAlg::finalizeAssembly(), INFO(), ProcessLib::AssemblyMixinBase::is_linear_, ProcessLib::AssemblyMixinBase::pvma_, BaseLib::RunTime::start(), and ProcessLib::AssembledMatrixCache::storeMKb().
Referenced by assembleOnBulkMesh(), and assembleOnSubmeshes().
|
inlinenodiscardprivate |
Definition at line 357 of file AssemblyMixin.h.
References assembleOnBulkMeshOrOnSubmeshCommon(), MathLib::LinAlg::axpy(), ProcessLib::computeResiduum(), ProcessLib::AssemblyMixinBase::copyResiduumVectorsToSubmesh(), derived(), ProcessLib::Process::getMatrixSpecifications(), ProcessLib::AssemblyMixinBase::submesh_assembly_data_, and ProcessLib::AssemblyMixinBase::submesh_matrix_cache_.
Referenced by assemble().
|
inline |
Definition at line 189 of file AssemblyMixin.h.
References BaseLib::MPI::anyOf(), assembleWithJacobianOnBulkMeshOrOnSubmeshCommon(), assembleWithJacobianOnSubmeshes(), ProcessLib::AssemblyMixinBase::bulk_mesh_assembly_data_, ProcessLib::AssemblyMixinBase::copyResiduumVectorsToBulkMesh(), DBUG(), derived(), MathLib::LinAlg::finalizeAssembly(), ProcessLib::Process::getDOFTables(), ProcessLib::AssemblyMixinBase::is_linear_, ProcessLib::AssemblyMixinBase::last_assembly_was_, NumLib::Newton, and ProcessLib::AssemblyMixinBase::submesh_assembly_data_.
Referenced by ProcessLib::ComponentTransport::ComponentTransportProcess::assembleWithJacobianConcreteProcess(), ProcessLib::HeatConduction::HeatConductionProcess::assembleWithJacobianConcreteProcess(), ProcessLib::HeatTransportBHE::HeatTransportBHEProcess::assembleWithJacobianConcreteProcess(), ProcessLib::ThermoRichardsFlow::ThermoRichardsFlowProcess::assembleWithJacobianConcreteProcess(), and preOutputNewton().
|
inlinenodiscardprivate |
Common code for the Newton-Raphson assembly on the bulk mesh or on submeshes.
Definition at line 439 of file AssemblyMixin.h.
References ProcessLib::Assembly::CommonAssemblyData::activeElementIDsSorted(), derived(), MathLib::LinAlg::finalizeAssembly(), and ProcessLib::AssemblyMixinBase::pvma_.
Referenced by assembleWithJacobian(), and assembleWithJacobianOnSubmeshes().
|
inlinenodiscardprivate |
Definition at line 468 of file AssemblyMixin.h.
References assembleWithJacobianOnBulkMeshOrOnSubmeshCommon(), MathLib::LinAlg::axpy(), ProcessLib::AssemblyMixinBase::copyResiduumVectorsToSubmesh(), derived(), ProcessLib::Process::getMatrixSpecifications(), and ProcessLib::AssemblyMixinBase::submesh_assembly_data_.
Referenced by assembleWithJacobian().
|
explicitprivate |
Definition at line 32 of file AssemblyMixin.cpp.
References OGS_FATAL.
|
inlineprivate |
Definition at line 274 of file AssemblyMixin.h.
References Process.
Referenced by assemble(), assembleOnBulkMeshOrOnSubmeshCommon(), assembleOnSubmeshes(), assembleWithJacobian(), assembleWithJacobianOnBulkMeshOrOnSubmeshCommon(), assembleWithJacobianOnSubmeshes(), initializeAssemblyOnSubmeshes(), preOutputNewton(), preOutputPicard(), and updateActiveElements().
|
inlineprivate |
Definition at line 275 of file AssemblyMixin.h.
References Process.
|
inline |
Specifies that the assembly of the process should take place on the passed submeshes.
residuum_names matters and must match the order of the residuum vectors in the process. Otherwise residuum output on submeshes will be wrong.Definition at line 123 of file AssemblyMixin.h.
References derived(), and ProcessLib::AssemblyMixinBase::initializeAssemblyOnSubmeshes().
Referenced by ProcessLib::ComponentTransport::ComponentTransportProcess::initializeAssemblyOnSubmeshes(), ProcessLib::HeatConduction::HeatConductionProcess::initializeAssemblyOnSubmeshes(), ProcessLib::HeatTransportBHE::HeatTransportBHEProcess::initializeAssemblyOnSubmeshes(), and ProcessLib::ThermoRichardsFlow::ThermoRichardsFlowProcess::initializeAssemblyOnSubmeshes().
|
inline |
Definition at line 250 of file AssemblyMixin.h.
References ProcessLib::AssemblyMixinBase::last_assembly_was_, NumLib::Newton, NumLib::Picard, preOutputNewton(), preOutputPicard(), and WARN().
Referenced by ProcessLib::ComponentTransport::ComponentTransportProcess::preOutputConcreteProcess(), and ProcessLib::HeatConduction::HeatConductionProcess::preOutputConcreteProcess().
|
inlineprivate |
Definition at line 527 of file AssemblyMixin.h.
References assembleWithJacobian(), derived(), and ProcessLib::Process::getMatrixSpecifications().
Referenced by preOutput().
|
inlineprivate |
Definition at line 504 of file AssemblyMixin.h.
References assemble(), derived(), and ProcessLib::Process::getMatrixSpecifications().
Referenced by preOutput().
|
inline |
Definition at line 132 of file AssemblyMixin.h.
References derived(), and ProcessLib::AssemblyMixinBase::updateActiveElements().
Referenced by ProcessLib::ComponentTransport::ComponentTransportProcess::preTimestepConcreteProcess(), ProcessLib::HeatConduction::HeatConductionProcess::preTimestepConcreteProcess(), ProcessLib::HeatTransportBHE::HeatTransportBHEProcess::preTimestepConcreteProcess(), and ProcessLib::ThermoRichardsFlow::ThermoRichardsFlowProcess::preTimestepConcreteProcess().
|
private |
Definition at line 99 of file AssemblyMixin.h.