问题
I am modelling a train station(using simpy, with python 2.7) where there are some incoming routes, some outgoing routes and some platforms. Now, when one of these resources is occupied, I can't assign a train to certain other resources.
Now when a train engages a route - i.e. traverses it - some other routes in the stations area become unusable for some time. If I were to model a route as a resource, then a request yielded at that resource will affect/engage other resources as well.
Is there some way of modelling resources, such that engagement of one resource_A puts resource_B, resource_C out of action for some predetermined amount of time?
Aseem Awad
回答1:
I guess you can just request the other resources (B and C; maybe using preemption) once you get resource A and release all three resources once you are done with A.
来源:https://stackoverflow.com/questions/26553392/interrelated-resources