TimeStepperSUNDIALS_IDA_impl< VectorType, SparseMatrixType, dim, LinearSolver > Class Template Reference#

DiFfRG: DiFfRG::TimeStepperSUNDIALS_IDA_impl< VectorType, SparseMatrixType, dim, LinearSolver > Class Template Reference
DiFfRG
Discretization Framework for functional Renormalization Group flows
DiFfRG::TimeStepperSUNDIALS_IDA_impl< VectorType, SparseMatrixType, dim, LinearSolver > Class Template Reference

A class to perform time stepping using the SUNDIALS IDA solver. This stepper uses adaptive time steps and is fully implicit. Furthermore, IDA allows for the solution of DAEs. More...

#include <sundials_ida.hh>

Inheritance diagram for DiFfRG::TimeStepperSUNDIALS_IDA_impl< VectorType, SparseMatrixType, dim, LinearSolver >:
DiFfRG::AbstractTimestepper< VectorType, SparseMatrixType, dim >

Public Types

using NumberType = typename Base::NumberType
 
using BlockVectorType = typename Base::BlockVectorType
 
using IDAErrorDofCallback = std::function<void(const IDAErrorDofDiagnostics &)>
 

Public Member Functions

 TimeStepperSUNDIALS_IDA_impl (const ConfigTree &config, AbstractAssembler< VectorType, SparseMatrixType, dim > &assembler, OutputSession_impl< dim, VectorType > &data_out)
 
 TimeStepperSUNDIALS_IDA_impl (const ConfigTree &config, AbstractAssembler< VectorType, SparseMatrixType, dim > &assembler, OutputSession_impl< dim, VectorType > &data_out, AbstractAdaptor< VectorType > &adaptor)
 
virtual void run (AbstractFlowingVariables< NumberType, VectorType > &initial_condition, const double t_start, const double t_stop) override
 Any derived class must implement this method to run the timestepping algorithm.
 
void set_ida_error_dof_callback (IDAErrorDofCallback callback)
 
- Public Member Functions inherited from DiFfRG::AbstractTimestepper< VectorType, SparseMatrixType, dim >
 AbstractTimestepper (const ConfigTree &config, AbstractAssembler< VectorType, SparseMatrixType, dim > &assembler, OutputSession_impl< dim, VectorType > &data_out, const bool implicit_stepper, const bool explicit_stepper)
 Construct a new Abstract Timestepper object.
 
 AbstractTimestepper (const ConfigTree &config, AbstractAssembler< VectorType, SparseMatrixType, dim > &assembler, OutputSession_impl< dim, VectorType > &data_out, AbstractAdaptor< VectorType > &adaptor, const bool implicit_stepper, const bool explicit_stepper)
 

Private Types

using Base = AbstractTimestepper<VectorType, SparseMatrixType, dim>
 

Private Member Functions

void run (VectorType &initial_data, const double t_start, const double t_stop)
 
void run (BlockVectorType &initial_data, const double t_start, const double t_stop)
 
void run_vars (VectorType &initial_data, const double t_start, const double t_stop)
 

Private Attributes

IDAErrorDofCallback ida_error_dof_callback
 

Additional Inherited Members

- Protected Types inherited from DiFfRG::AbstractTimestepper< VectorType, SparseMatrixType, dim >
using VectorType
 
using NumberType
 
using SparseMatrixType
 
using BlockVectorType
 
- Protected Member Functions inherited from DiFfRG::AbstractTimestepper< VectorType, SparseMatrixType, dim >
void drain_output ()
 
void finalize_output_after_failure (EmitFinalFrame &&emit_final_frame)
 Best-effort output cleanup while a timestepping failure is being reported.
 
bool is_implicit () const
 
bool is_explicit () const
 
- Protected Attributes inherited from DiFfRG::AbstractTimestepper< VectorType, SparseMatrixType, dim >
const ConfigTree config
 
NoAdaptivity< VectorType > adaptor_default
 
AbstractAssembler< VectorType, SparseMatrixType, dim > & assembler
 
OutputSession_impl< dim, VectorType > & data_out
 
AbstractAdaptor< VectorType > & adaptor
 
ReportPort log
 
const bool m_is_implicit
 
const bool m_is_explicit
 
double output_dt
 
struct DiFfRG::AbstractTimestepper::ImplicitParameters impl
 
struct DiFfRG::AbstractTimestepper::ExplicitParameters expl
 
std::size_t next_jacobian_build_id
 
TimestepperJacobianDiagnosticsState jacobian_diagnostics_state
 
- Static Protected Attributes inherited from DiFfRG::AbstractTimestepper< VectorType, SparseMatrixType, dim >
static constexpr uint dim
 

Detailed Description

template<typename VectorType, typename SparseMatrixType, uint dim, template< typename... > typename LinearSolver>
class DiFfRG::TimeStepperSUNDIALS_IDA_impl< VectorType, SparseMatrixType, dim, LinearSolver >

A class to perform time stepping using the SUNDIALS IDA solver. This stepper uses adaptive time steps and is fully implicit. Furthermore, IDA allows for the solution of DAEs.

Template Parameters
VectorTypeType of the vector
dimDimension of the problem

Member Typedef Documentation

◆ Base

template<typename VectorType , typename SparseMatrixType , uint dim, template< typename... > typename LinearSolver>
using DiFfRG::TimeStepperSUNDIALS_IDA_impl< VectorType, SparseMatrixType, dim, LinearSolver >::Base = AbstractTimestepper<VectorType, SparseMatrixType, dim>
private

◆ BlockVectorType

template<typename VectorType , typename SparseMatrixType , uint dim, template< typename... > typename LinearSolver>
using DiFfRG::TimeStepperSUNDIALS_IDA_impl< VectorType, SparseMatrixType, dim, LinearSolver >::BlockVectorType = typename Base::BlockVectorType

◆ IDAErrorDofCallback

template<typename VectorType , typename SparseMatrixType , uint dim, template< typename... > typename LinearSolver>
using DiFfRG::TimeStepperSUNDIALS_IDA_impl< VectorType, SparseMatrixType, dim, LinearSolver >::IDAErrorDofCallback = std::function<void(const IDAErrorDofDiagnostics &)>

◆ NumberType

template<typename VectorType , typename SparseMatrixType , uint dim, template< typename... > typename LinearSolver>
using DiFfRG::TimeStepperSUNDIALS_IDA_impl< VectorType, SparseMatrixType, dim, LinearSolver >::NumberType = typename Base::NumberType

Constructor & Destructor Documentation

◆ TimeStepperSUNDIALS_IDA_impl() [1/2]

template<typename VectorType , typename SparseMatrixType , uint dim, template< typename... > typename LinearSolver>
DiFfRG::TimeStepperSUNDIALS_IDA_impl< VectorType, SparseMatrixType, dim, LinearSolver >::TimeStepperSUNDIALS_IDA_impl ( const ConfigTree & config,
AbstractAssembler< VectorType, SparseMatrixType, dim > & assembler,
OutputSession_impl< dim, VectorType > & data_out )
inline

Forwards to the base with this stepper's kind. Not using Base::Base;: the base needs to know which /timestepping/ section to read, and it cannot ask a virtual function for that from inside its own constructor.

◆ TimeStepperSUNDIALS_IDA_impl() [2/2]

template<typename VectorType , typename SparseMatrixType , uint dim, template< typename... > typename LinearSolver>
DiFfRG::TimeStepperSUNDIALS_IDA_impl< VectorType, SparseMatrixType, dim, LinearSolver >::TimeStepperSUNDIALS_IDA_impl ( const ConfigTree & config,
AbstractAssembler< VectorType, SparseMatrixType, dim > & assembler,
OutputSession_impl< dim, VectorType > & data_out,
AbstractAdaptor< VectorType > & adaptor )
inline

Member Function Documentation

◆ run() [1/3]

template<typename VectorType , typename SparseMatrixType , uint dim, template< typename... > typename LinearSolver>
virtual void DiFfRG::TimeStepperSUNDIALS_IDA_impl< VectorType, SparseMatrixType, dim, LinearSolver >::run ( AbstractFlowingVariables< NumberType, VectorType > & initial_condition,
const double t_start,
const double t_stop )
overridevirtual

Any derived class must implement this method to run the timestepping algorithm.

Parameters
initial_conditionThe flowing variables object that contains the initial condition.
t_startThe start time of the simulation.
t_stopThe run method will evolve the system from t_start to t_stop.

Implements DiFfRG::AbstractTimestepper< VectorType, SparseMatrixType, dim >.

◆ run() [2/3]

template<typename VectorType , typename SparseMatrixType , uint dim, template< typename... > typename LinearSolver>
void DiFfRG::TimeStepperSUNDIALS_IDA_impl< VectorType, SparseMatrixType, dim, LinearSolver >::run ( BlockVectorType & initial_data,
const double t_start,
const double t_stop )
private

◆ run() [3/3]

template<typename VectorType , typename SparseMatrixType , uint dim, template< typename... > typename LinearSolver>
void DiFfRG::TimeStepperSUNDIALS_IDA_impl< VectorType, SparseMatrixType, dim, LinearSolver >::run ( VectorType & initial_data,
const double t_start,
const double t_stop )
private

◆ run_vars()

template<typename VectorType , typename SparseMatrixType , uint dim, template< typename... > typename LinearSolver>
void DiFfRG::TimeStepperSUNDIALS_IDA_impl< VectorType, SparseMatrixType, dim, LinearSolver >::run_vars ( VectorType & initial_data,
const double t_start,
const double t_stop )
private

◆ set_ida_error_dof_callback()

template<typename VectorType , typename SparseMatrixType , uint dim, template< typename... > typename LinearSolver>
void DiFfRG::TimeStepperSUNDIALS_IDA_impl< VectorType, SparseMatrixType, dim, LinearSolver >::set_ida_error_dof_callback ( IDAErrorDofCallback callback)
inline

Member Data Documentation

◆ ida_error_dof_callback

template<typename VectorType , typename SparseMatrixType , uint dim, template< typename... > typename LinearSolver>
IDAErrorDofCallback DiFfRG::TimeStepperSUNDIALS_IDA_impl< VectorType, SparseMatrixType, dim, LinearSolver >::ida_error_dof_callback
private

The documentation for this class was generated from the following file:
  • /home/runner/work/DiFfRG_current/DiFfRG_current/DiFfRG/include/DiFfRG/timestepping/sundials_ida.hh