Spine-Toolbox
Spine-Toolbox copied to clipboard
Reviving the idea of datastore "Symbols" and "Expressions"
I had a really nice use-case for this functionality today. Working on a model with costs in a particular currency and the client wanted the ability to have the exchange rate as an input variable.
For the sake of discussion, what would the easiest way be to do this right now using existing toolbox functionality. Basically, I need to multiply all instances of parameters X, Y and Z in a datastore by a certain value?
Anyway - the idea for this functionality was to be able to define static symbols that have a scalar value. For example, a currency exchange rate, or conversion factors (e.g. GJ to MWh etc., heating values of fuels etc.). Then we would introduce a new parameter type called, say, expression. In a basic implementation, the expression can be simple arithmetic that can involve symbols. In a more advanced implementation, perhaps we can derive syntax to allow referencing of other parameter values, and allow the symbol itself to be any our datatypes. This could be nice, for example, to define a timeseries as a symbol and have other parameter values derive from this.
I think this would be a nice functionality to include on the roadmap