didppy.ElementTable2D
- class didppy.ElementTable2D
2-dimensional table of element constants.
t[x, y]
returns an element expression referring to an item wheret
isElementTable2D
andx
andy
areElementExpr
,ElementVar
,ElementResourceVar
, orint
.Examples
>>> import didppy as dp >>> model = dp.Model() >>> obj = model.add_object_type(number=2) >>> var = model.add_element_var(object_type=obj, target=1) >>> table = model.add_element_table([[2, 3], [0, 1]]) >>> table[0, var].eval(model.target_state, model) 3
Methods