Anylogic:队列超时阻塞流
我有一个非常简单的 Anylogic DE 模型,其中 PO 定期启动,并且一定量的材料一次性进入传入队列(请参见下面的示例图片)。然后,制造流程开始以常规速率使用该材料,但我想检查队列中的材料是否已过时,因此我使用该队列的“超时”选项,以便废弃过时的材料(超过 40 周) )。
问题是,每当某些材料通过此超时出口报废时,下游制造流程就会“停止”拉动更多材料,而不是继续,并且直到队列中接收到新批次的材料后,它才会重新启动。
我在这里做错了什么?非常感谢! 最诚挚的问候
I have a pretty simple Anylogic DE model where POs are launched regularly, and a certain amount of material gets to the incoming Queue in one shot (See Sample Picture below). Then the Manufacturing process starts using that material at a regular rate, but I want to check if the material in the queue gets outdated, so I'm using the TimeOut option of that queue, in order to scrap the outdated material (older than 40wks).
The problem is that every time that some material gets scrapped through this Timeout exit, the downstream Manufacturing process "stops" pulling more material, instead of continuing, and it does not get restarted until a new batch of material gets received into the Queue.
What am I doing wrong here? Thanks a lot in advance!!
Kindest regards
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
你的情况很有趣,因为你所做的事情似乎没有任何问题。因此,即使您所做的事情似乎是正确的,我也会为您提供解决方法。使用 Wait 块代替 Queue 块。您可以分配超时并链接超时端口,就像对队列所做的那样(参见答案末尾的图像)。
在等待块(我假设其名为
Fridge
)的On Enter
字段中,编写以下代码: MFG 块写入以下内容:
最后,在 MFG 块的
On Exit
中写入以下内容:我们在上面所做的就是手动推送代理。每次处理代理时,模型都会检查是否有能力发送更多代理,如果有,则发送新的代理。
我知道这是一个令人不快的解决方法,但它为您提供了一个解决方案,直到 AnyLogic 支持人员能够解决这个问题。
Your situation is interesting because there doesn't seem to be anything wrong with what you're doing. So even though what you are doing seems to be correct, I will provide you with a workaround. Instead of the Queue block, use a Wait block. You can assign a timeout and link the timeout port just like you did for the queue (seem image at the end of the answer).
In the
On Enter
field of the wait block (which I will assume is namedFridge
), write the following code:In the
On Enter
of MFG block write the following:And finally, in the
On Exit
of your MFG block write the following:What we are doing in the above, is we are manually pushing the agents. Each time an agent is processed, the model checks if there is capacity to send more, if yes, a new agent is sent.
I know this is an unpleasant workaround, but it provides you with a solution until AnyLogic support can figure it out.