Dune::Amg::LevelTransferPolicyCpr< FO, CO > Class Template Referenceabstract

Abstract base class for transfer between levels and creation of the coarse level system. More...

#include <twolevelmethodcpr.hh>

Inheritance diagram for Dune::Amg::LevelTransferPolicyCpr< FO, CO >:
Inheritance graph

Public Types

typedef FO FineOperatorType
 The linear operator of the finel level system. Has to be derived from AssembledLinearOperator. More...
 
typedef FineOperatorType::range_type FineRangeType
 The type of the range of the fine level operator. More...
 
typedef FineOperatorType::domain_type FineDomainType
 The type of the domain of the fine level operator. More...
 
typedef CO CoarseOperatorType
 The linear operator of the finel level system. Has to be derived from AssembledLinearOperator. More...
 
typedef CoarseOperatorType::range_type CoarseRangeType
 The type of the range of the coarse level operator. More...
 
typedef CoarseOperatorType::domain_type CoarseDomainType
 The type of the domain of the coarse level operator. More...
 

Public Member Functions

std::shared_ptr< CoarseOperatorType > & getCoarseLevelOperator ()
 Get the coarse level operator. More...
 
CoarseRangeTypegetCoarseLevelRhs ()
 Get the coarse level right hand side. More...
 
CoarseDomainTypegetCoarseLevelLhs ()
 Get the coarse level left hand side. More...
 
virtual void moveToCoarseLevel (const FineRangeType &fineRhs)=0
 Transfers the data to the coarse level. More...
 
virtual void moveToFineLevel (FineDomainType &fineLhs)=0
 Updates the fine level linear system after the correction of the coarse levels system. More...
 
virtual void createCoarseLevelSystem (const FineOperatorType &fineOperator)=0
 Algebraically creates the coarse level system. More...
 
virtual void calculateCoarseEntries (const FineOperatorType &fineOperator)=0
 ???. More...
 
virtual LevelTransferPolicyCprclone () const =0
 Clone the current object. More...
 
virtual ~LevelTransferPolicyCpr ()
 Destructor. More...
 

Protected Attributes

CoarseRangeType rhs_
 The coarse level rhs. More...
 
CoarseDomainType lhs_
 The coarse level lhs. More...
 
std::shared_ptr< CoarseOperatorTypeoperator_
 the coarse level linear operator. More...
 

Detailed Description

template<class FO, class CO>
class Dune::Amg::LevelTransferPolicyCpr< FO, CO >

Abstract base class for transfer between levels and creation of the coarse level system.

Template Parameters
FOThe type of the linear operator of the finel level system. Has to be derived from AssembledLinearOperator.
COThe type of the linear operator of the coarse level system. Has to be derived from AssembledLinearOperator.

Member Typedef Documentation

◆ CoarseDomainType

template<class FO , class CO >
typedef CoarseOperatorType::domain_type Dune::Amg::LevelTransferPolicyCpr< FO, CO >::CoarseDomainType

The type of the domain of the coarse level operator.

◆ CoarseOperatorType

template<class FO , class CO >
typedef CO Dune::Amg::LevelTransferPolicyCpr< FO, CO >::CoarseOperatorType

The linear operator of the finel level system. Has to be derived from AssembledLinearOperator.

◆ CoarseRangeType

template<class FO , class CO >
typedef CoarseOperatorType::range_type Dune::Amg::LevelTransferPolicyCpr< FO, CO >::CoarseRangeType

The type of the range of the coarse level operator.

◆ FineDomainType

template<class FO , class CO >
typedef FineOperatorType::domain_type Dune::Amg::LevelTransferPolicyCpr< FO, CO >::FineDomainType

The type of the domain of the fine level operator.

◆ FineOperatorType

template<class FO , class CO >
typedef FO Dune::Amg::LevelTransferPolicyCpr< FO, CO >::FineOperatorType

The linear operator of the finel level system. Has to be derived from AssembledLinearOperator.

◆ FineRangeType

template<class FO , class CO >
typedef FineOperatorType::range_type Dune::Amg::LevelTransferPolicyCpr< FO, CO >::FineRangeType

The type of the range of the fine level operator.

Constructor & Destructor Documentation

◆ ~LevelTransferPolicyCpr()

template<class FO , class CO >
virtual Dune::Amg::LevelTransferPolicyCpr< FO, CO >::~LevelTransferPolicyCpr ( )
inlinevirtual

Destructor.

Member Function Documentation

◆ calculateCoarseEntries()

◆ clone()

◆ createCoarseLevelSystem()

template<class FO , class CO >
virtual void Dune::Amg::LevelTransferPolicyCpr< FO, CO >::createCoarseLevelSystem ( const FineOperatorType fineOperator)
pure virtual

Algebraically creates the coarse level system.

After returning from this function the coarse level operator can be accessed using getCoarseLevelOperator().

Parameters
fineOperatorThe operator of the fine level system.

Implemented in Opm::PressureBhpTransferPolicy< FineOperator, Communication, transpose >, Opm::PressureTransferPolicy< FineOperator, Communication, transpose >, and Dune::Amg::AggregationLevelTransferPolicyCpr< O, C >.

Referenced by Dune::Amg::TwoLevelMethodCpr< FO, CSP, S >::TwoLevelMethodCpr(), and Dune::Amg::TwoLevelMethodCpr< FO, CSP, S >::updatePreconditioner().

◆ getCoarseLevelLhs()

template<class FO , class CO >
CoarseDomainType & Dune::Amg::LevelTransferPolicyCpr< FO, CO >::getCoarseLevelLhs ( )
inline

Get the coarse level left hand side.

Returns
The coarse level leftt hand side.

References Dune::Amg::LevelTransferPolicyCpr< FO, CO >::lhs_.

Referenced by Dune::Amg::TwoLevelMethodCpr< FO, CSP, S >::apply().

◆ getCoarseLevelOperator()

template<class FO , class CO >
std::shared_ptr< CoarseOperatorType > & Dune::Amg::LevelTransferPolicyCpr< FO, CO >::getCoarseLevelOperator ( )
inline

Get the coarse level operator.

Returns
A shared pointer to the coarse level system.

References Dune::Amg::LevelTransferPolicyCpr< FO, CO >::operator_.

◆ getCoarseLevelRhs()

template<class FO , class CO >
CoarseRangeType & Dune::Amg::LevelTransferPolicyCpr< FO, CO >::getCoarseLevelRhs ( )
inline

Get the coarse level right hand side.

Returns
The coarse level right hand side.

References Dune::Amg::LevelTransferPolicyCpr< FO, CO >::rhs_.

Referenced by Dune::Amg::TwoLevelMethodCpr< FO, CSP, S >::apply().

◆ moveToCoarseLevel()

template<class FO , class CO >
virtual void Dune::Amg::LevelTransferPolicyCpr< FO, CO >::moveToCoarseLevel ( const FineRangeType fineRhs)
pure virtual

Transfers the data to the coarse level.

Restricts the residual to the right hand side of the coarse level system and initialies the left hand side of the coarse level system. These can afterwards be accessed usinf getCoarseLevelRhs() and getCoarseLevelLhs().

Parameters
fineDefectThe current residual of the fine level system.

Referenced by Dune::Amg::TwoLevelMethodCpr< FO, CSP, S >::apply().

◆ moveToFineLevel()

template<class FO , class CO >
virtual void Dune::Amg::LevelTransferPolicyCpr< FO, CO >::moveToFineLevel ( FineDomainType fineLhs)
pure virtual

Updates the fine level linear system after the correction of the coarse levels system.

After returning from this function the coarse level correction will have been added to fine level system.

Parameters
[in,out]fineLhsThe left hand side of the fine level to update with the coarse level correction.

Implemented in Dune::Amg::AggregationLevelTransferPolicyCpr< O, C >, Opm::PressureBhpTransferPolicy< FineOperator, Communication, transpose >, and Opm::PressureTransferPolicy< FineOperator, Communication, transpose >.

Referenced by Dune::Amg::TwoLevelMethodCpr< FO, CSP, S >::apply().

Member Data Documentation

◆ lhs_

template<class FO , class CO >
CoarseDomainType Dune::Amg::LevelTransferPolicyCpr< FO, CO >::lhs_
protected

◆ operator_

template<class FO , class CO >
std::shared_ptr<CoarseOperatorType> Dune::Amg::LevelTransferPolicyCpr< FO, CO >::operator_
protected

the coarse level linear operator.

Referenced by Dune::Amg::LevelTransferPolicyCpr< FO, CO >::getCoarseLevelOperator().

◆ rhs_

template<class FO , class CO >
CoarseRangeType Dune::Amg::LevelTransferPolicyCpr< FO, CO >::rhs_
protected

The documentation for this class was generated from the following file: