Semicolons in SimBiology species names: just characters, or functionally active?
1 view (last 30 days)
I was looking at Sven Mesecke's implementation of the Renin Angiotensin Aldosterone System model of Lo et al. 2011. (For those who are interested, its available on the Mathworks' fileexchange site, here).
It's nice. I did note though, that Sven implemented the name of bound Angiotensin II with a semicolon. That is:
AngII --> AngII:AT1R
I added a representation of AT1R, so my reaction is:
AngII + AT1R --> AngII:AT1R
It all works just fine, however, if I try to implement a lagged version of the bound concentration (let's call it "LBC"), ala
dLBC/dt = klag * ( AngII:AT1R - LBC)
I get an error. That is, if I put the forward rate constant in as klag * AngII:AT1R, Simbiology parses this as klag * AngII * AT1R. There appears to be no way to get SimBiology to parse the species AngII:AT1R as a species, and not as the product of two species, in the rate expression.
Do semicolons have special signficance in species names? If so, is there documentation somewhere. If not... Well, if not I guess this is a bug.
I suspect that semicolons should not be used in species names, as a rule.
Arthur Goldsipe on 17 Jun 2020
You can name your species almost anything. The naming restrictions are documented here. However, if the name is not a valid MATLAB variable name, then you must enclose the name in square brackets whenever you write it in an expression. (It's also ok to enclose a name in square brackets even if the name is a valid variable name. So if in doubt, just use brackets.)
So, you could fix your example by changing klag * AngII:AT1R to klag * [AngII:AT1R]. Without the brackets, SimBiology tries to interpret : as the colon operator.