sbioaddtolibrary
Add to user-defined library
Syntax
sbioaddtolibrary (
abstkineticlawObj
)
sbioaddtolibrary (unitObj
)
sbioaddtolibrary (unitprefixObj
)
Arguments
| Specify the abstract kinetic law object that holds the kinetic
law definition. The Name of the kinetic law must
be unique in the user-defined kinetic law library. Name is
referenced by .
For more information about creating ,
see sbioabstractkineticlaw . |
| Specify the user-defined unit to add to the library. For more
information about creating ,
see sbiounit . |
| Specify the user-defined unit prefix to add to the library.
For more information about creating ,
see sbiounitprefix . |
Description
The function sbioaddtolibrary
adds kinetic
law definitions, units, and unit prefixes to the user-defined library.
sbioaddtolibrary (
adds
the abstract kinetic law object (abstkineticlawObj
)abstkineticlawObj
)
to the user-defined library.
sbioaddtolibrary (
adds
the user-defined unit (unitObj
)unitObj
) to the user-defined
library.
sbioaddtolibrary (
adds
the user-defined unit prefix (unitprefixObj
)unitprefixObj
) to
the user-defined library.
The sbioaddtolibrary
function adds any kinetic
law definition, unit, or unit prefix to the root object's UserDefinedLibrary
property.
These library components become available automatically in future MATLAB® sessions.
Use the kinetic law definitions in the built-in and user-defined
library to construct a kinetic law object with the method addkineticlaw
.
To get a component of the built-in and user-defined libraries,
use the commands get(sbioroot, 'BuiltInLibrary')
and (get(sbioroot,
'UserDefinedLibrary'))
.
To remove the library component from the user-defined library,
use the function sbioremovefromlibrary
. You cannot
remove a kinetic law definition being used by a reaction.
Examples
This example shows how to create a kinetic law definition and add it to the user-defined library.
Create a kinetic law definition.
abstkineticlawObj = sbioabstractkineticlaw('ex_mylaw1', '(k1*s)/(k2+k1+s)');
Assign the parameter and species variables in the expression.
set (abstkineticlawObj, 'SpeciesVariables', {'s'}); set (abstkineticlawObj, 'ParameterVariables', {'k1', 'k2'});
Add the new kinetic law definition to the user-defined library.
sbioaddtolibrary(abstkineticlawObj);
The function adds the kinetic law definition to the user-defined library. You can verify this using
sbiowhos
.sbiowhos -kineticlaw -userdefined SimBiology Abstract Kinetic Law Array Index: Library: Name: Expression: 1 UserDefined mylaw1 (k1*s)/(k2+k1+s)
Use the new kinetic law definition when defining a reaction's kinetic law.
modelObj = sbiomodel('cell'); reactionObj = addreaction(modelObj, 'A + B <-> B + C'); kineticlawObj = addkineticlaw(reactionObj, 'ex_mylaw1');
Note
Remember to specify the
SpeciesVariableNames
and theParameterVariableNames
inkineticlawObj
to fully define theReactionRate
of the reaction.
Version History
Introduced in R2006a
See Also
addkineticlaw
| sbioabstractkineticlaw
| sbioremovefromlibrary
| sbioroot
| sbiounit
| sbiounitprefix