MOOSE - Multiscale Object Oriented Simulation Environment
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
EnzBase Class Referenceabstract

#include <EnzBase.h>

+ Inheritance diagram for EnzBase:
+ Collaboration diagram for EnzBase:

Public Member Functions

void enz (double n)
 
 EnzBase ()
 
double getKcat (const Eref &e) const
 
double getKm (const Eref &e) const
 
double getNumKm (const Eref &e) const
 
unsigned int getNumPrd (const Eref &e) const
 
unsigned int getNumSub (const Eref &e) const
 
void prd (double n)
 
void process (const Eref &e, ProcPtr p)
 
void reinit (const Eref &e, ProcPtr p)
 
void remesh (const Eref &e)
 
void setKcat (const Eref &e, double v)
 
void setKm (const Eref &e, double v)
 
void setNumKm (const Eref &e, double v)
 
virtual void setSolver (Id solver, Id orig)
 Assign solver info. More...
 
void sub (double n)
 
virtual void vEnz (double n)
 
virtual double vGetKcat (const Eref &e) const =0
 
virtual double vGetKm (const Eref &e) const =0
 
virtual double vGetNumKm (const Eref &e) const =0
 
virtual void vProcess (const Eref &e, ProcPtr p)
 
virtual void vReinit (const Eref &e, ProcPtr p)
 
virtual void vRemesh (const Eref &e)
 
virtual void vSetKcat (const Eref &e, double v)=0
 
virtual void vSetKm (const Eref &e, double v)=0
 
virtual void vSetNumKm (const Eref &e, double v)=0
 
virtual void vSub (double n)
 
virtual ~EnzBase ()
 

Static Public Member Functions

static const CinfoinitCinfo ()
 
static void zombify (Element *original, const Cinfo *zClass, Id solver)
 

Detailed Description

This class is the base class for enzymes, both the classical Michaelis- Menten form and the form with explicit enz-substrate complexes that MOOSE prefers.

Definition at line 18 of file EnzBase.h.

Constructor & Destructor Documentation

EnzBase::EnzBase ( )

Definition at line 169 of file EnzBase.cpp.

170 {;}
EnzBase::~EnzBase ( )
virtual

Definition at line 172 of file EnzBase.cpp.

173 {;}

Member Function Documentation

void EnzBase::enz ( double  n)

Definition at line 187 of file EnzBase.cpp.

References vEnz().

Referenced by CplxEnzBase::initCinfo(), and initCinfo().

188 {
189  vEnz( n );
190 }
virtual void vEnz(double n)
Definition: EnzBase.cpp:214

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

double EnzBase::getKcat ( const Eref e) const

Definition at line 256 of file EnzBase.cpp.

References vGetKcat().

Referenced by CplxEnzBase::initCinfo(), initCinfo(), ZombieEnz::vGetKm(), ZombieEnz::vGetRatio(), ZombieEnz::vSetKcat(), ZombieEnz::vSetKm(), ZombieEnz::vSetNumKm(), ZombieEnz::vSetRatio(), CplxEnzBase::zombify(), and zombify().

257 {
258  return vGetKcat( e );
259 }
virtual double vGetKcat(const Eref &e) const =0

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

double EnzBase::getKm ( const Eref e) const

Definition at line 235 of file EnzBase.cpp.

References vGetKm().

Referenced by initCinfo(), ZombieEnz::vSetRatio(), and zombify().

236 {
237  return vGetKm( enz );
238 }
virtual double vGetKm(const Eref &e) const =0
void enz(double n)
Definition: EnzBase.cpp:187

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

double EnzBase::getNumKm ( const Eref e) const

Definition at line 245 of file EnzBase.cpp.

References vGetNumKm().

Referenced by initCinfo().

246 {
247  return vGetNumKm( enz );
248 }
virtual double vGetNumKm(const Eref &e) const =0
void enz(double n)
Definition: EnzBase.cpp:187

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

unsigned int EnzBase::getNumPrd ( const Eref e) const

Definition at line 269 of file EnzBase.cpp.

References Eref::element(), Element::getMsgAndFunc(), and prdOut().

Referenced by initCinfo().

270 {
271  const vector< MsgFuncBinding >* mfb =
272  e.element()->getMsgAndFunc( prdOut()->getBindIndex() );
273  assert( mfb );
274  return ( mfb->size() );
275 }
Element * element() const
Definition: Eref.h:42
const vector< MsgFuncBinding > * getMsgAndFunc(BindIndex b) const
Definition: Element.cpp:300
static SrcFinfo2< double, double > * prdOut()
Definition: EnzBase.cpp:25

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

unsigned int EnzBase::getNumSub ( const Eref e) const

Definition at line 261 of file EnzBase.cpp.

References Eref::element(), Element::getMsgAndFunc(), and subOut().

Referenced by initCinfo().

262 {
263  const vector< MsgFuncBinding >* mfb =
264  e.element()->getMsgAndFunc( subOut()->getBindIndex() );
265  assert( mfb );
266  return ( mfb->size() );
267 }
static SrcFinfo2< double, double > * subOut()
Definition: EnzBase.cpp:17
Element * element() const
Definition: Eref.h:42
const vector< MsgFuncBinding > * getMsgAndFunc(BindIndex b) const
Definition: Element.cpp:300

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

const Cinfo * EnzBase::initCinfo ( )
static

Definition at line 33 of file EnzBase.cpp.

References enz(), enzBaseCinfo, enzDest(), getKcat(), getKm(), getNumKm(), getNumPrd(), getNumSub(), Neutral::initCinfo(), prd(), prdOut(), process(), reinit(), remesh(), setKcat(), setKm(), setNumKm(), sub(), and subOut().

Referenced by enzDest(), findMeshOfEnz(), MMenz::initCinfo(), ZombieMMenz::initCinfo(), CplxEnzBase::initCinfo(), and ZombieMMenz::setSolver().

34 {
36  // Field Definitions
39  "Km",
40  "Michaelis-Menten constant in SI conc units (milliMolar)",
43  );
44 
46  "numKm",
47  "Michaelis-Menten constant in number units, volume dependent",
50  );
51 
53  "kcat",
54  "Forward rate constant for enzyme, units 1/sec",
57  );
58 
60  "numSubstrates",
61  "Number of substrates in this MM reaction. Usually 1."
62  "Does not include the enzyme itself",
64  );
65 
67  "numProducts",
68  "Number of products in this MM reaction. Usually 1.",
70  );
71 
72 
74  // Shared Msg Definitions
76  static DestFinfo process( "process",
77  "Handles process call",
79 
80  static DestFinfo reinit( "reinit",
81  "Handles reinit call",
83 
84  /*
85  static DestFinfo group( "group",
86  "Handle for group msgs. Doesn't do anything",
87  new OpFuncDummy() );
88  */
89 
90  static DestFinfo remesh( "remesh",
91  "Tells the MMEnz to recompute its numKm after remeshing",
93 
95  // MsgDest Definitions
97  static DestFinfo enzDest( "enzDest",
98  "Handles # of molecules of Enzyme",
100  static DestFinfo subDest( "subDest",
101  "Handles # of molecules of substrate",
103  static DestFinfo prdDest( "prdDest",
104  "Handles # of molecules of product. Dummy.",
106  static Finfo* subShared[] = {
107  subOut(), &subDest
108  };
109 
110  static Finfo* prdShared[] = {
111  prdOut(), &prdDest
112  };
113  static SharedFinfo sub( "sub",
114  "Connects to substrate molecule",
115  subShared, sizeof( subShared ) / sizeof( const Finfo* )
116  );
117  static SharedFinfo prd( "prd",
118  "Connects to product molecule",
119  prdShared, sizeof( prdShared ) / sizeof( const Finfo* )
120  );
121  static Finfo* procShared[] = {
122  &process, &reinit
123  };
124  static SharedFinfo proc( "proc",
125  "Shared message for process and reinit",
126  procShared, sizeof( procShared ) / sizeof( const Finfo* )
127  );
128 
129  static Finfo* enzBaseFinfos[] = {
130  &Km, // ElementValue
131  &numKm, // ElementValue
132  &kcat, // Value
133  &numSub, // ReadOnlyElementValue
134  &numPrd, // ReadOnlyElementValue
135  &enzDest, // DestFinfo
136  &sub, // SharedFinfo
137  &prd, // SharedFinfo
138  &proc, // SharedFinfo
139  &remesh, // Destfinfo
140  };
141 
142  static string doc[] =
143  {
144  "Name", "EnzBase",
145  "Author", "Upi Bhalla",
146  "Description", "Abstract base class for enzymes."
147  };
148  static ZeroSizeDinfo< int > dinfo;
149  static Cinfo enzBaseCinfo (
150  "EnzBase",
152  enzBaseFinfos,
153  sizeof( enzBaseFinfos ) / sizeof ( Finfo* ),
154  &dinfo,
155  doc,
156  sizeof( doc )/sizeof( string ),
157  true // Don't create it, it is a an astract base class.
158  );
159 
160  return &enzBaseCinfo;
161 }
unsigned int getNumPrd(const Eref &e) const
Definition: EnzBase.cpp:269
static SrcFinfo2< double, double > * subOut()
Definition: EnzBase.cpp:17
static const Cinfo * enzBaseCinfo
Definition: EnzBase.cpp:163
void setNumKm(const Eref &e, double v)
Definition: EnzBase.cpp:240
double getKm(const Eref &e) const
Definition: EnzBase.cpp:235
double getNumKm(const Eref &e) const
Definition: EnzBase.cpp:245
DestFinfo * enzDest()
Definition: CplxEnzBase.cpp:32
void enz(double n)
Definition: EnzBase.cpp:187
void sub(double n)
Definition: EnzBase.cpp:179
unsigned int getNumSub(const Eref &e) const
Definition: EnzBase.cpp:261
void setKm(const Eref &e, double v)
Definition: EnzBase.cpp:230
Definition: EpFunc.h:49
Definition: OpFunc.h:27
void remesh(const Eref &e)
Definition: EnzBase.cpp:202
double getKcat(const Eref &e) const
Definition: EnzBase.cpp:256
void prd(double n)
Definition: EnzBase.cpp:184
static const Cinfo * initCinfo()
Definition: Neutral.cpp:16
void process(const Eref &e, ProcPtr p)
Definition: EnzBase.cpp:192
static SrcFinfo2< double, double > * prdOut()
Definition: EnzBase.cpp:25
void setKcat(const Eref &e, double v)
Definition: EnzBase.cpp:251
Definition: Cinfo.h:18
void reinit(const Eref &e, ProcPtr p)
Definition: EnzBase.cpp:197
Definition: Finfo.h:12

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void EnzBase::prd ( double  n)

Definition at line 184 of file EnzBase.cpp.

Referenced by initCinfo().

185 {;}

+ Here is the caller graph for this function:

void EnzBase::process ( const Eref e,
ProcPtr  p 
)

Definition at line 192 of file EnzBase.cpp.

References vProcess().

Referenced by initCinfo().

193 {
194  vProcess( e, p );
195 }
virtual void vProcess(const Eref &e, ProcPtr p)
Definition: EnzBase.cpp:217

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void EnzBase::reinit ( const Eref e,
ProcPtr  p 
)

Definition at line 197 of file EnzBase.cpp.

References vReinit().

Referenced by initCinfo().

198 {
199  vReinit( e, p );
200 }
virtual void vReinit(const Eref &e, ProcPtr p)
Definition: EnzBase.cpp:220

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void EnzBase::remesh ( const Eref e)

Definition at line 202 of file EnzBase.cpp.

References vRemesh().

Referenced by initCinfo().

203 {
204  vRemesh( e );
205 }
virtual void vRemesh(const Eref &e)
Definition: EnzBase.cpp:223

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void EnzBase::setKcat ( const Eref e,
double  v 
)

Definition at line 251 of file EnzBase.cpp.

References vSetKcat().

Referenced by CplxEnzBase::initCinfo(), initCinfo(), CplxEnzBase::zombify(), and zombify().

252 {
253  vSetKcat( e, v );
254 }
virtual void vSetKcat(const Eref &e, double v)=0

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void EnzBase::setKm ( const Eref e,
double  v 
)

Definition at line 230 of file EnzBase.cpp.

References vSetKm().

Referenced by initCinfo(), Enz::vRemesh(), and zombify().

231 {
232  vSetKm( enz, v );
233 }
void enz(double n)
Definition: EnzBase.cpp:187
virtual void vSetKm(const Eref &e, double v)=0

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void EnzBase::setNumKm ( const Eref e,
double  v 
)

Definition at line 240 of file EnzBase.cpp.

References vSetNumKm().

Referenced by initCinfo().

241 {
242  vSetNumKm( enz, v );
243 }
void enz(double n)
Definition: EnzBase.cpp:187
virtual void vSetNumKm(const Eref &e, double v)=0

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void EnzBase::setSolver ( Id  solver,
Id  orig 
)
virtual

Assign solver info.

Reimplemented in ZombieEnz, and ZombieMMenz.

Definition at line 319 of file EnzBase.cpp.

Referenced by CplxEnzBase::zombify(), and zombify().

320 {
321  ;
322 }

+ Here is the caller graph for this function:

void EnzBase::sub ( double  n)

Definition at line 179 of file EnzBase.cpp.

References vSub().

Referenced by initCinfo().

180 {
181  vSub( n );
182 }
virtual void vSub(double n)
Definition: EnzBase.cpp:211

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void EnzBase::vEnz ( double  n)
virtual

Reimplemented in Enz, and MMenz.

Definition at line 214 of file EnzBase.cpp.

Referenced by enz().

215 {;}

+ Here is the caller graph for this function:

virtual double EnzBase::vGetKcat ( const Eref e) const
pure virtual

Implemented in MMenz, ZombieMMenz, ZombieEnz, and Enz.

Referenced by getKcat().

+ Here is the caller graph for this function:

virtual double EnzBase::vGetKm ( const Eref e) const
pure virtual

Implemented in ZombieEnz, MMenz, ZombieMMenz, and Enz.

Referenced by getKm().

+ Here is the caller graph for this function:

virtual double EnzBase::vGetNumKm ( const Eref e) const
pure virtual

Implemented in ZombieEnz, MMenz, ZombieMMenz, and Enz.

Referenced by getNumKm().

+ Here is the caller graph for this function:

void EnzBase::vProcess ( const Eref e,
ProcPtr  p 
)
virtual

Reimplemented in Enz, and MMenz.

Definition at line 217 of file EnzBase.cpp.

Referenced by process().

218 {;}

+ Here is the caller graph for this function:

void EnzBase::vReinit ( const Eref e,
ProcPtr  p 
)
virtual

Reimplemented in Enz, and MMenz.

Definition at line 220 of file EnzBase.cpp.

Referenced by reinit().

221 {;}

+ Here is the caller graph for this function:

void EnzBase::vRemesh ( const Eref e)
virtual

Reimplemented in Enz, and MMenz.

Definition at line 223 of file EnzBase.cpp.

Referenced by remesh().

224 {;}

+ Here is the caller graph for this function:

virtual void EnzBase::vSetKcat ( const Eref e,
double  v 
)
pure virtual

Implemented in MMenz, ZombieMMenz, ZombieEnz, and Enz.

Referenced by setKcat().

+ Here is the caller graph for this function:

virtual void EnzBase::vSetKm ( const Eref e,
double  v 
)
pure virtual

Implemented in ZombieEnz, MMenz, ZombieMMenz, and Enz.

Referenced by setKm().

+ Here is the caller graph for this function:

virtual void EnzBase::vSetNumKm ( const Eref e,
double  v 
)
pure virtual

Implemented in ZombieEnz, MMenz, ZombieMMenz, and Enz.

Referenced by setNumKm().

+ Here is the caller graph for this function:

void EnzBase::vSub ( double  n)
virtual

Reimplemented in Enz, and MMenz.

Definition at line 211 of file EnzBase.cpp.

Referenced by sub().

212 {;}

+ Here is the caller graph for this function:

void EnzBase::zombify ( Element orig,
const Cinfo zClass,
Id  solver 
)
static

This function helps the conversion between Enzyme subclasses. Note that we may need a second zombify function to convert to and from explicit enz classes because there is information lost if we go right down to the EnzBase. Specifically, EnzBase only knows about two parameters, the Km and kcat. Explicit enzymes also need to know a k2, or equivalently a ratio between kcat and k2. But in principle this function allows conversion between the two cases.

Definition at line 291 of file EnzBase.cpp.

References Element::cinfo(), Eref::data(), getKcat(), getKm(), Element::id(), Element::localDataStart(), Element::numLocalData(), setKcat(), setKm(), setSolver(), and Element::zombieSwap().

Referenced by Stoich::unZombifyModel(), and Stoich::zombifyModel().

292 {
293  if ( orig->cinfo() == zClass )
294  return;
295  unsigned int start = orig->localDataStart();
296  unsigned int num = orig->numLocalData();
297  if ( num == 0 )
298  return;
299  vector< double > Km( num, 0.0 );
300  vector< double > kcat( num, 0.0 );
301  for ( unsigned int i = 0; i < num; ++i ) {
302  Eref er( orig, i + start );
303  const EnzBase* eb =
304  reinterpret_cast< const EnzBase* >( er.data() );
305  kcat[ i ] = eb->getKcat( er );
306  Km[ i ] = eb->getKm( er );
307  }
308  orig->zombieSwap( zClass );
309  for ( unsigned int i = 0; i < num; ++i ) {
310  Eref er( orig, i + start );
311  EnzBase* eb = reinterpret_cast< EnzBase* >( er.data() );
312  eb->setSolver( solver, orig->id() );
313  eb->setKcat( er, kcat[i] );
314  eb->setKm( er, Km[i] );
315  }
316 }
double getKm(const Eref &e) const
Definition: EnzBase.cpp:235
virtual void zombieSwap(const Cinfo *zCinfo)
virtual func, this base version must be called by all derived classes
Definition: Element.cpp:159
Id id() const
Definition: Element.cpp:71
void setKm(const Eref &e, double v)
Definition: EnzBase.cpp:230
Definition: Eref.h:26
const Cinfo * cinfo() const
Definition: Element.cpp:66
virtual unsigned int localDataStart() const =0
Returns index of first data entry on this node.
virtual unsigned int numLocalData() const =0
Returns number of local data entries on this node.
double getKcat(const Eref &e) const
Definition: EnzBase.cpp:256
void setKcat(const Eref &e, double v)
Definition: EnzBase.cpp:251
virtual void setSolver(Id solver, Id orig)
Assign solver info.
Definition: EnzBase.cpp:319

+ Here is the call graph for this function:

+ Here is the caller graph for this function:


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