copasi API  0.1
Public Member Functions
CMathModel Class Reference

#include <CMathModel.h>

Inheritance diagram for CMathModel:
CCopasiContainer CCopasiObject

List of all members.

Public Member Functions

 CMathModel (const CCopasiContainer *pParent=NULL)
 CMathModel (const CMathModel &src, const CCopasiContainer *pParent=NULL)
virtual ~CMathModel ()
bool compile (CModel *pModel)
void evaluateRoots (CVectorCore< C_FLOAT64 > &rootValues, const bool &ignoreDiscrete)
const C_FLOAT64 & getInitialTime () const
bool processQueue (const C_FLOAT64 &time, const bool &equality, CProcessQueue::resolveSimultaneousAssignments pResolveSimultaneousAssignments)
void processRoots (const C_FLOAT64 &time, const bool &equality, const CVector< C_INT > &roots)
const C_FLOAT64 & getProcessQueueExecutionTime () const
void applyInitialValues ()
size_t getNumRoots () const
void calculateRootDerivatives (CVector< C_FLOAT64 > &rootDerivatives)
const CVector
< CMathTrigger::CRootFinder * > & 
getRootFinders () const
std::vector< Refresh * > buildRequiredRefreshList (const std::set< const CCopasiObject * > &requiredObjects) const
std::vector< Refresh * > buildDependendRefreshList (const std::set< const CCopasiObject * > &changedObjects) const

Constructor & Destructor Documentation

CMathModel::CMathModel ( const CCopasiContainer pParent = NULL)

Default constructor

Parameters:
constCCopasiContainer * pParent (default: NULL)
CMathModel::CMathModel ( const CMathModel src,
const CCopasiContainer pParent = NULL 
)

Copy constructor

Parameters:
const CMathModel &src
"constCCopasiContainer * pParent (default: NULL)
CMathModel::~CMathModel ( ) [virtual]

Destructor


Member Function Documentation

void CMathModel::applyInitialValues ( )

Initialize all values of the math model with their initial values.

std::vector< Refresh * > CMathModel::buildDependendRefreshList ( const std::set< const CCopasiObject * > &  changedObjects) const

Build a list of refresh calls needed to assure that all objects depending on the changed objects are up to date.

Parameters:
conststd::set< const CCopasiObject * > & changedObjects
Returns:
std::vector< Refresh * > refreshList
std::vector< Refresh * > CMathModel::buildRequiredRefreshList ( const std::set< const CCopasiObject * > &  requiredObjects) const

Build a list of refresh calls needed to assure that required objects are up to date.

Parameters:
conststd::set< const CCopasiObject * > & requiredObjects
Returns:
std::vector< Refresh * > refreshList
void CMathModel::calculateRootDerivatives ( CVector< C_FLOAT64 > &  rootDerivatives)

Calculate the time derivative of all roots

Parameters:
CVector<C_FLOAT64 > & rootDerivatives
bool CMathModel::compile ( CModel pModel)

Compile the mathematical model based on given the model.

Parameters:
CModel* pModel
Returns:
bool success
void CMathModel::evaluateRoots ( CVectorCore< C_FLOAT64 > &  rootValues,
const bool &  ignoreDiscrete 
)

Evaluate all root values for the current state of the model. If ignoreDiscrete is true discrete roots evaluate to 1.0.

Parameters:
CVectorCore<double > & rootValues
constbool & ignoreDiscrete
const C_FLOAT64 & CMathModel::getInitialTime ( ) const

Retreive the initial time

Returns:
const C_FLOAT64 & initialTime
size_t CMathModel::getNumRoots ( ) const

Retrieve the number of roots used in checking for discontinuities.

Returns:
size_t numRoots
const C_FLOAT64 & CMathModel::getProcessQueueExecutionTime ( ) const

Retrieve the next execution time scheduled in the process queue

Returns:
const C_FLOAT64 & processQueueExecutionTime
const CVector< CMathTrigger::CRootFinder * > & CMathModel::getRootFinders ( ) const

Retrieve a vector of root finders

Returns:
const CVector< CMathTrigger::CRootFinder * > & rootFinders
bool CMathModel::processQueue ( const C_FLOAT64 &  time,
const bool &  equality,
CProcessQueue::resolveSimultaneousAssignments  pResolveSimultaneousAssignments 
)

Process events scheduled at the given which a are checked for equality or not

Parameters:
constC_FLOAT64 & time
constbool & equality
CProcessQueue::resolveSimultaneousAssignmentspResolveSimultaneousAssignments
Returns:
bool stateChanged
void CMathModel::processRoots ( const C_FLOAT64 &  time,
const bool &  equality,
const CVector< C_INT > &  roots 
)

Check whether the roots which have value 1 lead to firing of events and schedule them if needed.

Parameters:
constC_FLOAT64 & time
constbool & equality
constCVector< C_INT > & roots

The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines