Simulation of an MTG is already available from PlantSimEngine, but it makes a lot of copies when making a simulation.
Ideally, we would have the data in a Tables.jl compatible structure, and this structure would be given as the status of the ModelList of the node. This way it wouldn't make a copy of the data, just modify it.
Here's the specifications:
we need a Tables.jl compatible structure for the status of the ModelList
we need this structure to have as many time-steps as needed, e.g. according to the required meteorology. So we need a step before simulation to check that, and maybe a way to easily build the table for simulation
we need the data to be easily accessible and changeable through the API of MultiScaleTreeGraph
We need to avoid copies of the data as much as possible (MTGs can grow big)
But we also need a way to have the ModelList of the Node accessible. There's two solutions I can think of:
add the ModelList to the table (this is not very memory efficient as it would be repeated many times.
have a custom field in the MTG for the ModelList. For this solution to be efficient, we need to test if the ModelList can be given as a mutable field as is, or if we need to put it as a parameterized field. In the second case we need to know the ModelList at the creation of the MTG, which is probably not the best thing. Also, if we do this, it would be interesting to have a way to transform a regular MTG into this type of MTG.
In any case, we have to think about usability vs performance.
Simulation of an MTG is already available from PlantSimEngine, but it makes a lot of copies when making a simulation.
Ideally, we would have the data in a Tables.jl compatible structure, and this structure would be given as the status of the ModelList of the node. This way it wouldn't make a copy of the data, just modify it.
Here's the specifications:
But we also need a way to have the ModelList of the Node accessible. There's two solutions I can think of:
In any case, we have to think about usability vs performance.