KratosMultiphysics
KRATOS Multiphysics (Kratos) is a framework for building parallel, multi-disciplinary simulation software, aiming at modularity, extensibility, and high performance. Kratos is written in C++, and counts with an extensive Python interface.
List of all members
Kratos::ButcherTableau< Derived, TOrder, TSubstepCount > Class Template Referenceabstract

Butcher tableau for Runge-Kutta method. More...

#include <butcher_tableau.h>

Collaboration diagram for Kratos::ButcherTableau< Derived, TOrder, TSubstepCount >:

Public Member Functions

Life Cycle
virtual ~ButcherTableau ()=default
 Destructor. More...
 
Operations
std::tuple< RowType::const_iterator, RowType::const_iterator > GetMatrixRow (const unsigned int SubStepIndex) const
 
RowType::const_iterator GetMatrixRowBegin (const unsigned int SubStepIndex) const
 
RowType::const_iterator GetMatrixRowEnd (const unsigned int SubStepIndex) const
 
constexpr const VectorTypeGetWeights () const
 
constexpr double GetIntegrationTheta (const unsigned int SubStepIndex) const
 

Protected Attributes

Protected member Variables
const MatrixType mA = Derived::GenerateRKMatrix()
 
const VectorType mB = Derived::GenerateWeights()
 
const VectorType mC = Derived::GenerateThetasVector()
 

Type Definitions

using VectorType = std::vector< double >
 
using RowType = std::vector< double >
 
using MatrixType = std::vector< RowType >
 
static constexpr unsigned int Order ()
 
static constexpr unsigned int SubstepCount ()
 

Input and output

static std::string Name ()
 
virtual std::string Info () const =0
 

Detailed Description

template<typename Derived, unsigned int TOrder, unsigned int TSubstepCount>
class Kratos::ButcherTableau< Derived, TOrder, TSubstepCount >

Butcher tableau for Runge-Kutta method.

Contains all info necessary of a particular RK method. It specifies the coefficients of the particular Runge-Kutta method.

Template Parameters

Member Typedef Documentation

◆ MatrixType

template<typename Derived , unsigned int TOrder, unsigned int TSubstepCount>
using Kratos::ButcherTableau< Derived, TOrder, TSubstepCount >::MatrixType = std::vector<RowType>

◆ RowType

template<typename Derived , unsigned int TOrder, unsigned int TSubstepCount>
using Kratos::ButcherTableau< Derived, TOrder, TSubstepCount >::RowType = std::vector<double>

◆ VectorType

template<typename Derived , unsigned int TOrder, unsigned int TSubstepCount>
using Kratos::ButcherTableau< Derived, TOrder, TSubstepCount >::VectorType = std::vector<double>

Constructor & Destructor Documentation

◆ ~ButcherTableau()

template<typename Derived , unsigned int TOrder, unsigned int TSubstepCount>
virtual Kratos::ButcherTableau< Derived, TOrder, TSubstepCount >::~ButcherTableau ( )
virtualdefault

Destructor.

Member Function Documentation

◆ GetIntegrationTheta()

template<typename Derived , unsigned int TOrder, unsigned int TSubstepCount>
constexpr double Kratos::ButcherTableau< Derived, TOrder, TSubstepCount >::GetIntegrationTheta ( const unsigned int  SubStepIndex) const
inlineconstexpr

◆ GetMatrixRow()

template<typename Derived , unsigned int TOrder, unsigned int TSubstepCount>
std::tuple<RowType::const_iterator, RowType::const_iterator> Kratos::ButcherTableau< Derived, TOrder, TSubstepCount >::GetMatrixRow ( const unsigned int  SubStepIndex) const
inline

The runge kutta must perform for all substeps 1...N-1:

du^(i) = dt * A_ij*k_j

This method return the coefficients A_i[1...i]. The rest of coefficients A_i[i+1...n] are skipped. This is they are always zero for explicit Runge-Kutta.

Parameters
SubstepIndexThe i in the formula (the row of the matrix). Note that it counts from 1 to n.
rKThe k in the formula (the reaction)
Returns
: A struct with iterators pointing to A_i1 (.begin) and A_ii (.end) intended to be used with std::inner_product.

◆ GetMatrixRowBegin()

template<typename Derived , unsigned int TOrder, unsigned int TSubstepCount>
RowType::const_iterator Kratos::ButcherTableau< Derived, TOrder, TSubstepCount >::GetMatrixRowBegin ( const unsigned int  SubStepIndex) const
inline

◆ GetMatrixRowEnd()

template<typename Derived , unsigned int TOrder, unsigned int TSubstepCount>
RowType::const_iterator Kratos::ButcherTableau< Derived, TOrder, TSubstepCount >::GetMatrixRowEnd ( const unsigned int  SubStepIndex) const
inline

◆ GetWeights()

template<typename Derived , unsigned int TOrder, unsigned int TSubstepCount>
constexpr const VectorType& Kratos::ButcherTableau< Derived, TOrder, TSubstepCount >::GetWeights ( ) const
inlineconstexpr

◆ Info()

template<typename Derived , unsigned int TOrder, unsigned int TSubstepCount>
virtual std::string Kratos::ButcherTableau< Derived, TOrder, TSubstepCount >::Info ( ) const
pure virtual

◆ Name()

template<typename Derived , unsigned int TOrder, unsigned int TSubstepCount>
static std::string Kratos::ButcherTableau< Derived, TOrder, TSubstepCount >::Name ( )
inlinestatic

◆ Order()

template<typename Derived , unsigned int TOrder, unsigned int TSubstepCount>
static constexpr unsigned int Kratos::ButcherTableau< Derived, TOrder, TSubstepCount >::Order ( )
inlinestaticconstexpr

◆ SubstepCount()

template<typename Derived , unsigned int TOrder, unsigned int TSubstepCount>
static constexpr unsigned int Kratos::ButcherTableau< Derived, TOrder, TSubstepCount >::SubstepCount ( )
inlinestaticconstexpr

Member Data Documentation

◆ mA

template<typename Derived , unsigned int TOrder, unsigned int TSubstepCount>
const MatrixType Kratos::ButcherTableau< Derived, TOrder, TSubstepCount >::mA = Derived::GenerateRKMatrix()
protected

◆ mB

template<typename Derived , unsigned int TOrder, unsigned int TSubstepCount>
const VectorType Kratos::ButcherTableau< Derived, TOrder, TSubstepCount >::mB = Derived::GenerateWeights()
protected

◆ mC

template<typename Derived , unsigned int TOrder, unsigned int TSubstepCount>
const VectorType Kratos::ButcherTableau< Derived, TOrder, TSubstepCount >::mC = Derived::GenerateThetasVector()
protected

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