Rythmos - Transient Integration for Differential Equations Version of the Day
Related Functions
Rythmos::LoggingIntegrationObserver< Scalar > Class Template Reference

Logging IntegrationOberserver that counts calls to observer functions and lists their order. More...

#include <Rythmos_LoggingIntegrationObserver.hpp>

Inheritance diagram for Rythmos::LoggingIntegrationObserver< Scalar >:
Inheritance graph
[legend]

List of all members.

Related Functions

(Note that these are not member functions.)

template<class Scalar >
Teuchos::RCP
< LoggingIntegrationObserver
< Scalar > > 
createLoggingIntegrationObserver ()
 Nonmember constructor.

Overridden from IntegrationObserverBase

RCP< IntegrationObserverBase
< Scalar > > 
cloneIntegrationObserver () const
 Clone this integration observer if supported .
void resetIntegrationObserver (const TimeRange< Scalar > &integrationTimeDomain)
 Reset the observer to prepair it to observe another integration.
void observeStartTimeIntegration (const StepperBase< Scalar > &stepper)
 Observe the beginning of a time integration loop.
void observeEndTimeIntegration (const StepperBase< Scalar > &stepper)
 Observe the end of a time integration loop.
void observeStartTimeStep (const StepperBase< Scalar > &stepper, const StepControlInfo< Scalar > &stepCtrlInfo, const int timeStepIter)
 Observer the beginning of an integration step.
void observeCompletedTimeStep (const StepperBase< Scalar > &stepper, const StepControlInfo< Scalar > &stepCtrlInfo, const int timeStepIter)
 Observe a successfully completed integration step.
void observeFailedTimeStep (const StepperBase< Scalar > &stepper, const StepControlInfo< Scalar > &stepCtrlInfo, const int timeStepIter)
 Observer a failed integration step.

string names logged in map

Use these strings to validate a call stack with this observer

const std::string nameCloneIntegrationObserver_
const std::string nameResetIntegrationObserver_
const std::string nameObserveStartTimeIntegration_
const std::string nameObserveEndTimeIntegration_
const std::string nameObserveStartTimeStep_
const std::string nameObserveCompletedTimeStep_
const std::string nameObserveFailedTimeStep_

Detailed Description

template<class Scalar>
class Rythmos::LoggingIntegrationObserver< Scalar >

Logging IntegrationOberserver that counts calls to observer functions and lists their order.

Definition at line 44 of file Rythmos_LoggingIntegrationObserver.hpp.


Member Function Documentation

template<typename Scalar >
RCP< IntegrationObserverBase< Scalar > > Rythmos::LoggingIntegrationObserver< Scalar >::cloneIntegrationObserver ( ) const [virtual]

Clone this integration observer if supported .

Here, the cloned object just has to have the ouptut strategy copied, not the complete state of the object mid way through an integration.

Implements Rythmos::IntegrationObserverBase< Scalar >.

Definition at line 171 of file Rythmos_LoggingIntegrationObserver.hpp.

template<typename Scalar >
void Rythmos::LoggingIntegrationObserver< Scalar >::resetIntegrationObserver ( const TimeRange< Scalar > &  integrationTimeDomain) [virtual]

Reset the observer to prepair it to observe another integration.

Parameters:
integrationTimeDomain[in] The time domain over which the integration will be defined.

Preconditions:

  • integrationTimeDomain.length() > 0.0
Todo:
Add initial guess as an argument

Implements Rythmos::IntegrationObserverBase< Scalar >.

Definition at line 182 of file Rythmos_LoggingIntegrationObserver.hpp.

template<typename Scalar >
void Rythmos::LoggingIntegrationObserver< Scalar >::observeStartTimeIntegration ( const StepperBase< Scalar > &  stepper) [virtual]

Observe the beginning of a time integration loop.

Parameters:
stepper[in] The stepper object.

Warning! This function is *NOT* stateless. It should be called once and only once at the beginning of getFwdPoints().

NOTE: The function resetIntegrationControlStrategy() must be called prior to even the first call to function.

NOTE: This method should be pure virtual but has been given a default implementation for backwards compatibility. We will make this pure virtual in the future.

Reimplemented from Rythmos::IntegrationObserverBase< Scalar >.

Definition at line 189 of file Rythmos_LoggingIntegrationObserver.hpp.

template<typename Scalar >
void Rythmos::LoggingIntegrationObserver< Scalar >::observeEndTimeIntegration ( const StepperBase< Scalar > &  stepper) [virtual]

Observe the end of a time integration loop.

Parameters:
stepper[in] The stepper object.

Warning! This function is *NOT* stateless. It should be called once and only once at the end of getFwdPoints().

NOTE: The function resetIntegrationControlStrategy() must be called prior to even the first call to function.

NOTE: This method should be pure virtual but has been given a default implementation for backwards compatibility. We will make this pure virtual in the future.

Reimplemented from Rythmos::IntegrationObserverBase< Scalar >.

Definition at line 196 of file Rythmos_LoggingIntegrationObserver.hpp.

template<typename Scalar >
void Rythmos::LoggingIntegrationObserver< Scalar >::observeStartTimeStep ( const StepperBase< Scalar > &  stepper,
const StepControlInfo< Scalar > &  stepCtrlInfo,
const int  timeStepIter 
) [virtual]

Observer the beginning of an integration step.

Parameters:
stepper[in] The stepper object.
stepCtrlInfo[in] The info for the time step about to be taken.
timeStepIter[in] The time step iteration counter. In the first call to this function, this should be timeStepIter==0 and it should be incremented on each call only once. While the concrete implementation of *this could keep track of the this counter, putting it in the argument list helps to simplify logic and helps to validate correct usage.

Warning! This function is *NOT* stateless. It should be called once and only once at the beginning of each time step.

NOTE: The function resetIntegrationControlStrategy() must be called prior to even the first call to function.

NOTE: This method should be pure virtual but has been given a default implementation for backwards compatibility. We will make this pure virtual in the future.

Reimplemented from Rythmos::IntegrationObserverBase< Scalar >.

Definition at line 202 of file Rythmos_LoggingIntegrationObserver.hpp.

template<typename Scalar >
void Rythmos::LoggingIntegrationObserver< Scalar >::observeCompletedTimeStep ( const StepperBase< Scalar > &  stepper,
const StepControlInfo< Scalar > &  stepCtrlInfo,
const int  timeStepIter 
) [virtual]

Observe a successfully completed integration step.

Parameters:
stepper[in] The stepper object that was just stepped forward once to integrate the transient ODE/DAE equations. On the very first call and every other call, this stepper should have a finite time range for a successfull step.
stepCtrlInfo[in] The info for the actual time step that was just completed.
timeStepIter[in] The time step iteration counter. In the first call to this function, this should be timeStepIter==0 and it should be incremented on each call only once. While the concrete implementation of *this could keep track of the this counter, putting it in the argument list helps to simplify logic and helps to validate correct usage.

Warning! This function is *NOT* stateless. It should be called once and only once per time step iteration.

NOTE: The function resetIntegrationControlStrategy() must be called prior to even the first call to function.

NOTE: If isInitialTimeStep(stepper->getTimeRange(), fullTimeRange) == true then this is the first time step (where fullTimeRange was passed into resetIntegrationObserver().

NOTE: If isFinalTimeStep(stepper->getTimeRange(), fullTimeRange) == true then this is the last time step (where fullTimeRange was passed into resetIntegrationObserver().

Implements Rythmos::IntegrationObserverBase< Scalar >.

Definition at line 212 of file Rythmos_LoggingIntegrationObserver.hpp.

template<typename Scalar >
void Rythmos::LoggingIntegrationObserver< Scalar >::observeFailedTimeStep ( const StepperBase< Scalar > &  stepper,
const StepControlInfo< Scalar > &  stepCtrlInfo,
const int  timeStepIter 
) [virtual]

Observer a failed integration step.

Parameters:
stepper[in] The stepper object that was just stepped forward once to integrate the transient ODE/DAE equations. On the very first call and every other call, this stepper should have a finite time range for a successfull step.
stepCtrlInfo[in] The info for the actual time step that was just attempted.
timeStepIter[in] The time step iteration counter. In the first call to this function, this should be timeStepIter==0 and it should be incremented on each call only once. While the concrete implementation of *this could keep track of the this counter, putting it in the argument list helps to simplify logic and helps to validate correct usage.

Warning! This function is *NOT* stateless. It should be called once and only once per failed time step iteration.

NOTE: The function resetIntegrationControlStrategy() must be called prior to even the first call to function.

NOTE: If isInitialTimeStep(stepper->getTimeRange(), fullTimeRange) == true then this is the first time step (where fullTimeRange was passed into resetIntegrationObserver().

NOTE: If isFinalTimeStep(stepper->getTimeRange(), fullTimeRange) == true then this is the last time step (where fullTimeRange was passed into resetIntegrationObserver().

NOTE: This method should be pure virtual but has been given a default implementation for backwards compatibility. We will make this pure virtual in the future.

Reimplemented from Rythmos::IntegrationObserverBase< Scalar >.

Definition at line 222 of file Rythmos_LoggingIntegrationObserver.hpp.


Friends And Related Function Documentation

template<class Scalar >
Teuchos::RCP< LoggingIntegrationObserver< Scalar > > createLoggingIntegrationObserver ( ) [related]

Nonmember constructor.

Definition at line 128 of file Rythmos_LoggingIntegrationObserver.hpp.


The documentation for this class was generated from the following file:
 All Classes Functions Variables Typedefs Friends