Plugins
ug::ITimeIntegrator< TDomain, TAlgebra > Class Template Referenceabstract

Integrates over a given time interval [a,b] with step size dt. More...

#include <time_integrator.hpp>

+ Inheritance diagram for ug::ITimeIntegrator< TDomain, TAlgebra >:

Public Types

typedef TAlgebra algebra_type
 
typedef TDomain domain_type
 
typedef GridFunction< TDomain, TAlgebra > grid_function_type
 
typedef TAlgebra::matrix_type matrix_type
 
typedef TAlgebra::vector_type vector_type
 
- Public Types inherited from ug::IOperator< GridFunction< TDomain, TAlgebra > >
typedef Y codomain_function_type
 
typedef X domain_function_type
 
- Public Types inherited from ug::TimeIntegratorSubject< TDomain, TAlgebra >
typedef ITimeIntegratorStageObserver_end< TDomain, TAlgebra > end_observer_type
 
typedef ITimeIntegratorStageObserver_finalize< TDomain, TAlgebra > finalize_observer_type
 
typedef GridFunction< TDomain, TAlgebra > grid_function_type
 
typedef ITimeIntegratorStageObserver_init< TDomain, TAlgebra > init_observer_type
 
enum  observer_group_type
 
typedef ITimeIntegratorStageObserver_postprocess< TDomain, TAlgebra > postprocess_observer_type
 
typedef ITimeIntegratorStageObserver_preprocess< TDomain, TAlgebra > preprocess_observer_type
 
typedef std::vector< SmartPtr< process_observer_type > > process_observer_container_type
 
typedef ITimeIntegratorObserver< TDomain, TAlgebra > process_observer_type
 
typedef ITimeIntegratorStageObserver_rewind< TDomain, TAlgebra > rewind_observer_type
 
typedef ITimeIntegratorStageObserver_start< TDomain, TAlgebra > start_observer_type
 

Public Member Functions

void apply (grid_function_type &u1, const grid_function_type &u0)
 Apply operator. More...
 
virtual bool apply (SmartPtr< grid_function_type > u1, number t1, ConstSmartPtr< grid_function_type > u0, number t0)=0
 
double get_time_step ()
 
void init ()
 init operator More...
 
virtual void init (grid_function_type const &u)
 init operator depending on a function u More...
 
 ITimeIntegrator ()
 
void prepare (grid_function_type &u)
 prepares functions for application More...
 
void set_no_log_out (bool bNoLogOut)
 
void set_precision_bound (double precisionBound)
 
void set_time_step (double dt)
 Set initial time step. More...
 
virtual ~ITimeIntegrator ()
 virtual destructor More...
 
- Public Member Functions inherited from ug::IOperator< GridFunction< TDomain, TAlgebra > >
virtual void apply (Y &d, const X &u)=0
 
virtual void prepare (X &u)=0
 
virtual ~IOperator ()
 
- Public Member Functions inherited from ug::TimeIntegratorSubject< TDomain, TAlgebra >
void attach_end_observer (SmartPtr< process_observer_type > obs)
 
void attach_finalize_observer (SmartPtr< process_observer_type > obs)
 
void attach_init_observer (SmartPtr< process_observer_type > obs)
 
void attach_observer (SmartPtr< process_observer_type > obs)
 
void attach_postprocess_observer (SmartPtr< process_observer_type > obs)
 
void attach_preprocess_observer (SmartPtr< process_observer_type > obs)
 
void attach_rewind_observer (SmartPtr< process_observer_type > obs)
 
void attach_start_observer (SmartPtr< process_observer_type > obs)
 
void reset_observers ()
 

Protected Attributes

bool m_bNoLogOut
 
double m_dt
 
double m_lower_tim
 
double m_precisionBound
 
double m_upper_tim
 
- Protected Attributes inherited from ug::TimeIntegratorSubject< TDomain, TAlgebra >
std::vector< SmartPtr< end_observer_type > > m_vEndObservers
 
std::vector< SmartPtr< finalize_observer_type > > m_vFinalizeObservers
 
std::vector< SmartPtr< init_observer_type > > m_vInitObservers
 
std::vector< SmartPtr< postprocess_observer_type > > m_vPostprocessObservers
 
std::vector< SmartPtr< preprocess_observer_type > > m_vPreprocessObservers
 
process_observer_container_type m_vProcessObservers [TIO_GROUP_SIZE]
 
std::vector< SmartPtr< rewind_observer_type > > m_vRewindObservers
 
std::vector< SmartPtr< start_observer_type > > m_vStartObservers
 

Additional Inherited Members

- Public Attributes inherited from ug::TimeIntegratorSubject< TDomain, TAlgebra >
 TIO_GROUP_END
 
 TIO_GROUP_FINALIZE_STEP
 
 TIO_GROUP_INIT_STEP
 
 TIO_GROUP_POSTPROCESS_STEP
 
 TIO_GROUP_PREPROCESS_STEP
 
 TIO_GROUP_REWIND_STEP
 
 TIO_GROUP_SIZE
 
 TIO_GROUP_START
 
- Protected Member Functions inherited from ug::TimeIntegratorSubject< TDomain, TAlgebra >
void attach_to_group (int tGroup, SmartPtr< process_observer_type > obs)
 
void attach_to_group (SmartPtr< process_observer_type > obs)
 
bool notify_group (SmartPtr< grid_function_type > u, int step, number time, number dt)
 

Detailed Description

template<class TDomain, class TAlgebra>
class ug::ITimeIntegrator< TDomain, TAlgebra >

Integrates over a given time interval [a,b] with step size dt.

Member Typedef Documentation

◆ algebra_type

template<class TDomain , class TAlgebra >
typedef TAlgebra ug::ITimeIntegrator< TDomain, TAlgebra >::algebra_type

◆ domain_type

template<class TDomain , class TAlgebra >
typedef TDomain ug::ITimeIntegrator< TDomain, TAlgebra >::domain_type

◆ grid_function_type

template<class TDomain , class TAlgebra >
typedef GridFunction<TDomain, TAlgebra> ug::ITimeIntegrator< TDomain, TAlgebra >::grid_function_type

◆ matrix_type

template<class TDomain , class TAlgebra >
typedef TAlgebra::matrix_type ug::ITimeIntegrator< TDomain, TAlgebra >::matrix_type

◆ vector_type

template<class TDomain , class TAlgebra >
typedef TAlgebra::vector_type ug::ITimeIntegrator< TDomain, TAlgebra >::vector_type

Constructor & Destructor Documentation

◆ ITimeIntegrator()

template<class TDomain , class TAlgebra >
ug::ITimeIntegrator< TDomain, TAlgebra >::ITimeIntegrator ( )
inline

◆ ~ITimeIntegrator()

template<class TDomain , class TAlgebra >
virtual ug::ITimeIntegrator< TDomain, TAlgebra >::~ITimeIntegrator ( )
inlinevirtual

virtual destructor

Member Function Documentation

◆ apply() [1/2]

template<class TDomain , class TAlgebra >
void ug::ITimeIntegrator< TDomain, TAlgebra >::apply ( grid_function_type u1,
const grid_function_type u0 
)
inline

Apply operator.

This method applies the operator, i.e, advances the time step

References UG_THROW.

◆ apply() [2/2]

◆ get_time_step()

template<class TDomain , class TAlgebra >
double ug::ITimeIntegrator< TDomain, TAlgebra >::get_time_step ( )
inline

◆ init() [1/2]

template<class TDomain , class TAlgebra >
void ug::ITimeIntegrator< TDomain, TAlgebra >::init ( )
inlinevirtual

init operator

This method initializes the operator. Once initialized the 'apply'-method can be called.

Returns
bool success flag

Implements ug::IOperator< GridFunction< TDomain, TAlgebra > >.

References UG_THROW.

◆ init() [2/2]

template<class TDomain , class TAlgebra >
virtual void ug::ITimeIntegrator< TDomain, TAlgebra >::init ( grid_function_type const &  u)
inlinevirtual

init operator depending on a function u

This method initializes the operator. Once initialized the 'apply'-method can be called. The function u is passed here, since the linear operator may be the linearization of some non-linear operator. Thus, the operator depends on the linearization point. If the operator is not a linearization, this method can be implemented by simply calling init() and forgetting about the linearization point.

Parameters
[in]ufunction (linearization point)
Returns
bool success flag

Reimplemented in ug::TimeIntegratorLinearAdaptive< TDomain, TAlgebra >.

◆ prepare()

template<class TDomain , class TAlgebra >
void ug::ITimeIntegrator< TDomain, TAlgebra >::prepare ( grid_function_type u)
inline

prepares functions for application

◆ set_no_log_out()

template<class TDomain , class TAlgebra >
void ug::ITimeIntegrator< TDomain, TAlgebra >::set_no_log_out ( bool  bNoLogOut)
inline

◆ set_precision_bound()

template<class TDomain , class TAlgebra >
void ug::ITimeIntegrator< TDomain, TAlgebra >::set_precision_bound ( double  precisionBound)
inline

◆ set_time_step()

template<class TDomain , class TAlgebra >
void ug::ITimeIntegrator< TDomain, TAlgebra >::set_time_step ( double  dt)
inline

Member Data Documentation

◆ m_bNoLogOut

template<class TDomain , class TAlgebra >
bool ug::ITimeIntegrator< TDomain, TAlgebra >::m_bNoLogOut
protected

◆ m_dt

template<class TDomain , class TAlgebra >
double ug::ITimeIntegrator< TDomain, TAlgebra >::m_dt
protected

◆ m_lower_tim

template<class TDomain , class TAlgebra >
double ug::ITimeIntegrator< TDomain, TAlgebra >::m_lower_tim
protected

◆ m_precisionBound

template<class TDomain , class TAlgebra >
double ug::ITimeIntegrator< TDomain, TAlgebra >::m_precisionBound
protected

◆ m_upper_tim

template<class TDomain , class TAlgebra >
double ug::ITimeIntegrator< TDomain, TAlgebra >::m_upper_tim
protected

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