Term#
module wntr.msx.elements
- class Term[source]#
Bases:
VariableBase
Named expression (term) that can be used in expressions
- Parameters:
name (str) – Variable name.
expression – Mathematical expression to be aliased
note (str | dict | wntr.epanet.util.ENcomment) – Supplementary information regarding this variable, by default None
_vars – Reaction system this species is a part of, by default None
- __init__(name, expression, *, note=None, _vars=None)[source]#
Variable ABC init method.
Make sure you call this method from your concrete subclass
__init__
method:super().__init__(name, note=note)
- Parameters:
- Raises:
KeyExistsError – Name is already taken
ValueError – Name is a reserved word
- property var_type: VariableType#
Type of variable,
TERM
.