KinSparseMatrix Class Reference

#include <KinSparseMatrix.h>

Inheritance diagram for KinSparseMatrix:
Inheritance graph
[legend]
Collaboration diagram for KinSparseMatrix:
Collaboration graph
[legend]

List of all members.

Public Member Functions

double computeRowRate (unsigned int row, const vector< double > &v) const
void getGillespieDependence (unsigned int row, vector< unsigned int > &cols) const
void fireReac (unsigned int reacIndex, vector< double > &S) const
void truncateRow (unsigned int maxColumnIndex)
vector< int > matrixEntry () const
 Here we expose the sparse matrix for MOOSE use.
vector< unsigned int > colIndex () const
vector< unsigned int > rowStart () const

Member Function Documentation

vector< unsigned int > KinSparseMatrix::colIndex (  )  const
double KinSparseMatrix::computeRowRate ( unsigned int  row,
const vector< double > &  v 
) const

Returns all non-zero column indices, for the specified row. This gives reac s in orig matrix, and molecule s in the transposed matrix Not needed. The getRow function does all this, more efficiently. int getRowIndices( unsigned int row, vector< unsigned int >& indices ); Returns the dot product of the specified row with the vector v. v corresponds to the vector of reaction rates. v must have nColumns entries.

Referenced by VoxelPools::updateRates().

void KinSparseMatrix::fireReac ( unsigned int  reacIndex,
vector< double > &  S 
) const

Fires a stochastic reaction: It undergoes a single transition This operation updates the mol concs due to the reacn.

Referenced by GssaVoxelPools::advance().

void KinSparseMatrix::getGillespieDependence ( unsigned int  row,
vector< unsigned int > &  cols 
) const

Does a special self-product of the specified row. Output is the set of nonzero indices in the product abs( Rij ) * neg( Rjk ) for the specified index i, where neg( val ) is true only if val < 0.

Referenced by Gsolve::rebuildGssaSystem().

vector< int > KinSparseMatrix::matrixEntry (  )  const

Here we expose the sparse matrix for MOOSE use.

References SparseMatrix< int >::N_.

Referenced by Stoich::getMatrixEntry().

vector< unsigned int > KinSparseMatrix::rowStart (  )  const
void KinSparseMatrix::truncateRow ( unsigned int  maxColumnIndex  ) 

This function generates a new internal list of rowEnds, such that they are all less than the maxColumnIndex. It is used because in fireReac we don't want to update all the molecules, only those that are variable.

References SparseMatrix< int >::colIndex_, and SparseMatrix< int >::rowStart_.

Referenced by Gsolve::rebuildGssaSystem().


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

Generated on 1 Jul 2015 for MOOSE by  doxygen 1.6.1