MAIA bb96820c
Multiphysics at AIA
Loading...
Searching...
No Matches
CouplingFv< nDim, SysEqn > Class Template Reference

#include <coupling.h>

Inheritance diagram for CouplingFv< nDim, SysEqn >:
[legend]
Collaboration diagram for CouplingFv< nDim, SysEqn >:
[legend]

Public Types

using solverType = FvCartesianSolverXD< nDim, SysEqn >
 

Public Member Functions

 CouplingFv (const MInt couplingId, std::vector< FvCartesianSolverXD< nDim, SysEqn > * > fvSolvers, const MInt noSolvers)
 
 CouplingFv (const MInt couplingId, Solver *solvers)
 
 ~CouplingFv () override=default
 
 CouplingFv (const CouplingFv &)=delete
 
CouplingFvoperator= (const CouplingFv &)=delete
 
- Public Member Functions inherited from Coupling
 Coupling (const MInt couplingId)
 
virtual ~Coupling ()=default
 
 Coupling (const Coupling &)=delete
 
Couplingoperator= (const Coupling &)=delete
 
MInt couplerId () const
 
virtual void init ()=0
 
virtual void finalizeSubCoupleInit (MInt solverId)=0
 
virtual void finalizeCouplerInit ()=0
 
virtual void preCouple (MInt recipeStep)=0
 
virtual void subCouple (MInt recipeStep, MInt solverId, std::vector< MBool > &solverCompleted)=0
 
virtual void postCouple (MInt recipeStep)=0
 
virtual void cleanUp ()=0
 
virtual void balancePre ()
 Load balancing. More...
 
virtual void balancePost ()
 
virtual void reinitAfterBalance ()
 
virtual void prepareAdaptation ()
 
virtual void postAdaptation ()
 
virtual void finalizeAdaptation (const MInt)
 
virtual void writeRestartFile (const MInt)
 
virtual MInt noCellDataDlb () const
 Methods to inquire coupler data during balancing. More...
 
virtual MInt cellDataTypeDlb (const MInt NotUsed(dataId)) const
 
virtual MInt cellDataSizeDlb (const MInt NotUsed(dataId), const MInt NotUsed(cellId))
 
virtual void getCellDataDlb (const MInt NotUsed(dataId), const MInt NotUsed(oldNoCells), const MInt *const NotUsed(bufferIdToCellId), MInt *const NotUsed(data))
 
virtual void getCellDataDlb (const MInt NotUsed(dataId), const MInt NotUsed(oldNoCells), const MInt *const NotUsed(bufferIdToCellId), MLong *const NotUsed(data))
 
virtual void getCellDataDlb (const MInt NotUsed(dataId), const MInt NotUsed(oldNoCells), const MInt *const NotUsed(bufferIdToCellId), MFloat *const NotUsed(data))
 
virtual void setCellDataDlb (const MInt NotUsed(dataId), const MInt *const NotUsed(data))
 
virtual void setCellDataDlb (const MInt NotUsed(dataId), const MLong *const NotUsed(data))
 
virtual void setCellDataDlb (const MInt NotUsed(dataId), const MFloat *const NotUsed(data))
 
virtual void finalizeBalance (const MInt)
 
virtual MInt noCouplingTimers (const MBool NotUsed(allTimings)) const
 Number of coupling timers. More...
 
virtual void getCouplingTimings (std::vector< std::pair< MString, MFloat > > &NotUsed(timings), const MBool NotUsed(allTimings))
 Return coupling timings. More...
 
virtual void getDomainDecompositionInformation (std::vector< std::pair< MString, MInt > > &NotUsed(domainInfo))
 Return information on current domain decomposition (e.g. number of coupled cells/elements/...) More...
 
void setDlbTimer (const MInt timerId)
 
void startLoadTimer (const MString &name) const
 Start the load timer of the coupler. More...
 
void stopLoadTimer (const MString &name) const
 Stop the load timer of the coupler. More...
 

Protected Member Functions

MInt noSolvers () const
 
solverTypefvSolver (const MInt solverId=0) const
 
MInt a_noFvCells () const
 
MInt a_noFvGridCells () const
 
- Protected Member Functions inherited from Coupling
MFloat returnLoadRecord () const
 
MFloat returnIdleRecord () const
 

Protected Attributes

std::vector< solverType * > m_fvSolvers {}
 

Detailed Description

template<MInt nDim, class SysEqn>
class CouplingFv< nDim, SysEqn >

Definition at line 361 of file coupling.h.

Member Typedef Documentation

◆ solverType

template<MInt nDim, class SysEqn >
using CouplingFv< nDim, SysEqn >::solverType = FvCartesianSolverXD<nDim, SysEqn>

Definition at line 363 of file coupling.h.

Constructor & Destructor Documentation

◆ CouplingFv() [1/3]

template<MInt nDim, class SysEqn >
CouplingFv< nDim, SysEqn >::CouplingFv ( const MInt  couplingId,
std::vector< FvCartesianSolverXD< nDim, SysEqn > * >  fvSolvers,
const MInt  noSolvers 
)
inline

Definition at line 365 of file coupling.h.

366 : Coupling(couplingId), m_fvSolvers(fvSolvers) {
367 TRACE();
368
369 // Store solver pointers
370 ASSERT(noSolvers == static_cast<MInt>(fvSolvers.size()), "Currently only works using this assumption...");
371 }
std::vector< solverType * > m_fvSolvers
Definition: coupling.h:395
MInt noSolvers() const
Definition: coupling.h:385
int32_t MInt
Definition: maiatypes.h:62

◆ CouplingFv() [2/3]

template<MInt nDim, class SysEqn >
CouplingFv< nDim, SysEqn >::CouplingFv ( const MInt  couplingId,
Solver solvers 
)
inline

Definition at line 373 of file coupling.h.

373 : Coupling(couplingId) {
374 TRACE();
375
376 // Store solver pointers
377 m_fvSolvers.push_back(static_cast<solverType*>(solvers));
378 }
FvCartesianSolverXD< nDim, SysEqn > solverType
Definition: coupling.h:363
MInt * solvers
Definition: maiatypes.h:72

◆ ~CouplingFv()

template<MInt nDim, class SysEqn >
CouplingFv< nDim, SysEqn >::~CouplingFv ( )
overridedefault

◆ CouplingFv() [3/3]

template<MInt nDim, class SysEqn >
CouplingFv< nDim, SysEqn >::CouplingFv ( const CouplingFv< nDim, SysEqn > &  )
delete

Member Function Documentation

◆ a_noFvCells()

template<MInt nDim, class SysEqn >
MInt CouplingFv< nDim, SysEqn >::a_noFvCells ( ) const
inlineprotected

Definition at line 391 of file coupling.h.

391{ return m_fvSolvers[0]->a_noCells(); }

◆ a_noFvGridCells()

template<MInt nDim, class SysEqn >
MInt CouplingFv< nDim, SysEqn >::a_noFvGridCells ( ) const
inlineprotected

Definition at line 392 of file coupling.h.

392{ return m_fvSolvers[0]->c_noCells(); }

◆ fvSolver()

template<MInt nDim, class SysEqn >
solverType & CouplingFv< nDim, SysEqn >::fvSolver ( const MInt  solverId = 0) const
inlineprotected

Definition at line 386 of file coupling.h.

386 {
387 ASSERT(solverId < noSolvers(), "Invalid solverId " + std::to_string(solverId) + "/" + std::to_string(noSolvers()));
388 return *m_fvSolvers[solverId];
389 }

◆ noSolvers()

template<MInt nDim, class SysEqn >
MInt CouplingFv< nDim, SysEqn >::noSolvers ( ) const
inlineprotected

Definition at line 385 of file coupling.h.

385{ return m_fvSolvers.size(); }

◆ operator=()

template<MInt nDim, class SysEqn >
CouplingFv & CouplingFv< nDim, SysEqn >::operator= ( const CouplingFv< nDim, SysEqn > &  )
delete

Member Data Documentation

◆ m_fvSolvers

template<MInt nDim, class SysEqn >
std::vector<solverType*> CouplingFv< nDim, SysEqn >::m_fvSolvers {}
protected

Definition at line 395 of file coupling.h.


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