Tempus  Version of the Day
Time Integration
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Member Functions | Protected Attributes | List of all members
Tempus::TimeEventComposite< Scalar > Class Template Reference

This composite TimeEvent loops over added TimeEvents. More...

#include <Tempus_TimeEventComposite.hpp>

Inheritance diagram for Tempus::TimeEventComposite< Scalar >:
Inheritance graph
[legend]

Public Member Functions

 TimeEventComposite ()
 Constructor. More...
 
virtual ~TimeEventComposite ()
 Destructor. More...
 
void addTimeEvent (Teuchos::RCP< TimeEventBase< Scalar > > timeEvent)
 
void clearTimeEvents ()
 
std::size_t getSize () const
 
virtual void describe () const
 Describe member data. More...
 
- Public Member Functions inherited from Tempus::TimeEventBase< Scalar >
 TimeEventBase ()
 Constructor. More...
 
virtual ~TimeEventBase ()
 Destructor. More...
 
virtual Scalar getAbsTol () const
 
virtual std::string getName () const
 
virtual void setName (std::string name)
 
virtual Scalar getDefaultTime () const
 
virtual Scalar getDefaultTol () const
 
virtual int getDefaultIndex () const
 

Protected Attributes

std::vector< Teuchos::RCP
< TimeEventBase< Scalar > > > 
timeEvents_
 

Basic methods

virtual bool isTime (Scalar time) const
 Test if time is near a TimeEvent (within tolerance). More...
 
virtual Scalar timeToNextEvent (Scalar time) const
 How much time until the next event. Negative indicating the last event is in the past. More...
 
virtual Scalar timeOfNextEvent (Scalar time) const
 Time of the next event. Negative indicating the last event is in the past. More...
 
virtual bool eventInRange (Scalar time1, Scalar time2) const
 Test if an event occurs within the time range. More...
 
virtual bool isIndex (int index) const
 Test if index is a time event.TimeEventBase. More...
 
virtual int indexToNextEvent (int index) const
 How many indices until the next event. Negative indicating the last event is in the past. More...
 
virtual int indexOfNextEvent (int index) const
 Index of the next event. Negative indicating the last event is in the past. More...
 
virtual bool eventInRangeIndex (int index1, int index2) const
 Test if an event occurs within the time range. More...
 

Detailed Description

template<class Scalar>
class Tempus::TimeEventComposite< Scalar >

This composite TimeEvent loops over added TimeEvents.

Individual TimeEvents are executed in the order in which they were added.

Definition at line 29 of file Tempus_TimeEventComposite.hpp.

Constructor & Destructor Documentation

template<class Scalar >
Tempus::TimeEventComposite< Scalar >::TimeEventComposite ( )
inline

Constructor.

Definition at line 34 of file Tempus_TimeEventComposite.hpp.

template<class Scalar >
virtual Tempus::TimeEventComposite< Scalar >::~TimeEventComposite ( )
inlinevirtual

Destructor.

Definition at line 40 of file Tempus_TimeEventComposite.hpp.

Member Function Documentation

template<class Scalar >
virtual bool Tempus::TimeEventComposite< Scalar >::isTime ( Scalar  time) const
inlinevirtual

Test if time is near a TimeEvent (within tolerance).

Reimplemented from Tempus::TimeEventBase< Scalar >.

Definition at line 45 of file Tempus_TimeEventComposite.hpp.

template<class Scalar >
virtual Scalar Tempus::TimeEventComposite< Scalar >::timeToNextEvent ( Scalar  time) const
inlinevirtual

How much time until the next event. Negative indicating the last event is in the past.

Reimplemented from Tempus::TimeEventBase< Scalar >.

Definition at line 58 of file Tempus_TimeEventComposite.hpp.

template<class Scalar >
virtual Scalar Tempus::TimeEventComposite< Scalar >::timeOfNextEvent ( Scalar  time) const
inlinevirtual

Time of the next event. Negative indicating the last event is in the past.

Reimplemented from Tempus::TimeEventBase< Scalar >.

Definition at line 64 of file Tempus_TimeEventComposite.hpp.

template<class Scalar >
virtual bool Tempus::TimeEventComposite< Scalar >::eventInRange ( Scalar  time1,
Scalar  time2 
) const
inlinevirtual

Test if an event occurs within the time range.

Reimplemented from Tempus::TimeEventBase< Scalar >.

Definition at line 96 of file Tempus_TimeEventComposite.hpp.

template<class Scalar >
virtual bool Tempus::TimeEventComposite< Scalar >::isIndex ( int  index) const
inlinevirtual

Test if index is a time event.TimeEventBase.

Reimplemented from Tempus::TimeEventBase< Scalar >.

Definition at line 109 of file Tempus_TimeEventComposite.hpp.

template<class Scalar >
virtual int Tempus::TimeEventComposite< Scalar >::indexToNextEvent ( int  index) const
inlinevirtual

How many indices until the next event. Negative indicating the last event is in the past.

Reimplemented from Tempus::TimeEventBase< Scalar >.

Definition at line 122 of file Tempus_TimeEventComposite.hpp.

template<class Scalar >
virtual int Tempus::TimeEventComposite< Scalar >::indexOfNextEvent ( int  index) const
inlinevirtual

Index of the next event. Negative indicating the last event is in the past.

Reimplemented from Tempus::TimeEventBase< Scalar >.

Definition at line 128 of file Tempus_TimeEventComposite.hpp.

template<class Scalar >
virtual bool Tempus::TimeEventComposite< Scalar >::eventInRangeIndex ( int  index1,
int  index2 
) const
inlinevirtual

Test if an event occurs within the time range.

Reimplemented from Tempus::TimeEventBase< Scalar >.

Definition at line 159 of file Tempus_TimeEventComposite.hpp.

template<class Scalar >
void Tempus::TimeEventComposite< Scalar >::addTimeEvent ( Teuchos::RCP< TimeEventBase< Scalar > >  timeEvent)
inline

Definition at line 174 of file Tempus_TimeEventComposite.hpp.

template<class Scalar >
void Tempus::TimeEventComposite< Scalar >::clearTimeEvents ( )
inline

Definition at line 180 of file Tempus_TimeEventComposite.hpp.

template<class Scalar >
std::size_t Tempus::TimeEventComposite< Scalar >::getSize ( ) const
inline

Definition at line 184 of file Tempus_TimeEventComposite.hpp.

template<class Scalar >
virtual void Tempus::TimeEventComposite< Scalar >::describe ( ) const
inlinevirtual

Describe member data.

Reimplemented from Tempus::TimeEventBase< Scalar >.

Definition at line 187 of file Tempus_TimeEventComposite.hpp.

Member Data Documentation

template<class Scalar >
std::vector<Teuchos::RCP<TimeEventBase<Scalar > > > Tempus::TimeEventComposite< Scalar >::timeEvents_
protected

Definition at line 204 of file Tempus_TimeEventComposite.hpp.


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