Create user-defined unit prefix
unitprefixObject
=
sbiounitprefix('NameValue
')
unitprefixObject
=
sbiounitprefix('NameValue
', 'ExponentValue
')
unitprefixObject
=
sbiounitprefix('NameValue
', ...'PropertyName
', PropertyValue
...)
| Name of the user-defined unit prefix. |
| Shows the value of |
| Name of the unit prefix object property. For example, |
| Value of the unit prefix object property. For example, |
constructs
a SimBiology® unit prefix object with the name unitprefixObject
=
sbiounitprefix('NameValue
')
.
Valid names must begin with a letter, and be followed by letters,
underscores, or numbers.NameValue
creates
a unit-prefix object with a multiplicative factor of unitprefixObject
=
sbiounitprefix('NameValue
', 'ExponentValue
')10^'
.ExponentValue
'
defines
optional properties. The property name/property value pairs can be
in any format supported by the function unitprefixObject
=
sbiounitprefix('NameValue
', ...'PropertyName
', PropertyValue
...)set
.
In order to use
,
you must add it to the user-defined library with the unitprefixObject
sbioaddtolibrary
function.
To get the unit-prefix object into the user-defined library, use the
following command:
sbioaddtolibrary(unitprefixObject
);
unitprefixObject
properties
with the get
command. You can modify additional
properties with the set
command. Use the sbioshowunitprefixes
function to
list the units available in the user-defined library.
This example shows how to create a user-defined unit prefix, add it to the user-defined library, and query the library.
Create a unit prefix.
unitprefixObj1 = sbiounitprefix('peta', 15);
Add the unit prefix to the user-defined library.
sbioaddtolibrary(unitprefixObj1);
Query the user-defined library in the root object.
rootObj = sbioroot; rootObj.UserDefinedLibrary.UnitPrefixes Unit Prefix Array Index: Library: Name: Exponent: 1 UserDefined peta 15
Alternatively, use the sbiowhos
command.
sbiowhos -userdefined -unitprefix SimBiology UserDefined Unit Prefixes Index: Name: Multiplier: 1 peta 1.000000e+015