| SimBiology® | ![]() |
The ReactionRate property defines the reaction rate equation. You can define a ReactionRate with or without the KineticLaw property. KineticLaw defines the type of reaction rate. The addkineticlaw function configures the ReactionRate based on the KineticLaw and the species and parameters specified in the kinetic law object properties SpeciesVariableNames and ParameterVariableNames.
The reaction takes place in the reverse direction if the Reversible property is true. This is reflected in ReactionRate. The ReactionRate includes the forward and reverse rate if reversible
You can specify ReactionRate without KineticLaw. Use the set function to specify the reaction rate equation. SimBiology adds species variables while creating reactionObj using the addreaction method. You must add the parameter variables (to the modelObj in this case). See the example below.
Once you have specified the ReactionRate without KineticLaw, if you later configure the reactionObj to use KineticLaw the ReactionRate is unset until you specify SpeciesVariableNames and ParameterVariableNames.
| Applies to | Object: reaction |
| Data type | char string |
| Data values | Reaction rate string. Default is '' |
| Access | Read/Write |
Create a model, add a reaction, and assign the expression for the reaction rate equation.
Create a model object, then add a reaction object.
modelObj = sbiomodel('my_model');
reactionObj = addreaction(modelObj, 'a -> c + d');Create a kinetic law object for the reaction object, of the type 'Henri-Michaelis-Menten'.
kineticlawObj = addkineticlaw(reactionObj, 'Henri-Michaelis-Menten');
reactionObj KineticLaw property is configured to kineticlawObj.
The 'Henri-Michaelis-Menten' kinetic law has two parameter variables (Vm and Km) and one species variable (S) that you should set. To set these variables, first create the parameter variables as parameter objects (parameterObj1, parameterObj2) with a names Vm_d, Km_d and assign them to kineticlawObj.
parameterObj1 = addparameter(kineticlawObj, 'Vm_d'); parameterObj2 = addparameter(kineticlawObj, 'Km_d');
Set the variable names for the kinetic law object.
set(kineticlawObj,'ParameterVariableNames', {'Vm_d' 'Km_d'});
set(kineticlawObj,'SpeciesVariableNames', {'a'});Verify that the reaction rate is expressed correctly in the reaction object ReactionRate property.
get (reactionObj, 'ReactionRate')
MATLAB® returns
ans = Vm_d*a/(Km_d + a)
Create a model, add a reaction, and specify ReactionRate without a kinetic law.
Create a model object, then add a reaction object.
modelObj = sbiomodel('my_model');
reactionObj = addreaction(modelObj, 'a + b -> c + d');Specify ReactionRate and verify the assignment.
set (reactionObj, 'ReactionRate', 'k*a'); get(reactionObj, 'ReactionRate')
MATLAB returns
ans = k*a
You cannot simulate the model until you add the parameter k to the modelObj.
parameterObj = addparameter(modelObj, 'k');
SimBiology adds the parameter to the modelObj with default Value = 1.0 for the parameter.
sbioreaction, addreaction, sbioparameter, addparameter, Reversible
![]() | Reaction | Reactions | ![]() |
| © 1984-2008- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |