2

I am building an airport model with passengers spawning, shopping/eating and departing.

Most passengers rush to their GateArea (Polygonal Node) and wait there until they feel it is appropriate to engage in discretionary activities. When they think about leaving the GateArea they generate a "Eat"- or "Shop"- Goal" and are transferred into a PedGoTo-Block that is linked to the according shop. At this point I sometimes get the error:

java.lang.RuntimeException: root.pGT_F_B2.pedGoToTarget:
Unreachable target: (599.37, 398.48) on level 'name: level' for pedestrian 'id: 46' located at: (467.15, 222.68) on level 'name: level'!
    at com.anylogic.engine.Engine.error(Unknown Source)
    at com.anylogic.engine.Agent.error(Unknown Source)
    at com.anylogic.engine.Utilities.error(Unknown Source)
    at com.anylogic.libraries.pedestrian.PedBlock_xjal.error(Unknown Source)
    at com.anylogic.libraries.pedestrian.PedGoTo_xjal.d(Unknown Source)
    at com.anylogic.libraries.pedestrian.PedGoTo_xjal.c(Unknown Source)
    at com.anylogic.libraries.pedestrian.PedGoTo_xjal.g(Unknown Source)
    at com.anylogic.libraries.pedestrian.PedGoTo_xjal.f(Unknown Source)
    at com.anylogic.libraries.pedestrian.PedGoTo_xjal.d(Unknown Source)
    at com.anylogic.libraries.pedestrian.PedGoTo_xjal.a(Unknown Source)
    at com.anylogic.libraries.pedestrian.PedGoTo_xjal.a(Unknown Source)
    at com.anylogic.libraries.pedestrian.PedGoTo_xjal$1.onEnter(Unknown Source)
    at com.anylogic.libraries.processmodeling.Delay.b(Unknown Source)
    at com.anylogic.libraries.processmodeling.Delay.b(Unknown Source)
    at com.anylogic.libraries.processmodeling.Delay$9.onEnter(Unknown Source)
    at com.anylogic.libraries.processmodeling.InputBlock$1.b(Unknown Source)
    at com.anylogic.libraries.processmodeling.InPort.a(Unknown Source)
    at com.anylogic.libraries.processmodeling.InPort.receiveImmediately(Unknown Source)
    at com.anylogic.libraries.processmodeling.InputBlock$1.a(Unknown Source)
    at com.anylogic.libraries.processmodeling.OutPort.a(Unknown Source)
    at com.anylogic.libraries.processmodeling.OutPort.b(Unknown Source)
    at com.anylogic.libraries.processmodeling.PlainTransfer$1.a(Unknown Source)
    at com.anylogic.libraries.processmodeling.OutPort.a(Unknown Source)
    at com.anylogic.libraries.processmodeling.OutPort.b(Unknown Source)
    at com.anylogic.libraries.processmodeling.OutputBlock.forwardReadyEntityNotification(Unknown Source)
    at com.anylogic.libraries.processmodeling.InputBlock$1.a(Unknown Source)
    at com.anylogic.libraries.processmodeling.OutPort.a(Unknown Source)
    at com.anylogic.libraries.processmodeling.OutPort.b(Unknown Source)
    at com.anylogic.libraries.processmodeling.OutPort.a(Unknown Source)
    at com.anylogic.libraries.processmodeling.OutputBlock.a(Unknown Source)
    at com.anylogic.libraries.processmodeling.OutputBlock.a(Unknown Source)
    at com.anylogic.libraries.processmodeling.OutputBlock$2.a(Unknown Source)
    at com.anylogic.libraries.processmodeling.OutputBlock$2.action(Unknown Source)
    at com.anylogic.libraries.processmodeling.AsynchronousExecutor_xjal$a.execute(Unknown Source)
    at com.anylogic.engine.LibraryEventHandler$b.execute(Unknown Source)
    at com.anylogic.engine.Engine.c(Unknown Source)
    at com.anylogic.engine.Engine.fi(Unknown Source)
    at com.anylogic.engine.Engine.n(Unknown Source)
    at com.anylogic.engine.Engine$b.run(Unknown Source)

As you can see in the picture, neither the gate nor the shop are blocked by some static obstacles. The problem seem to be between the passengers, since they seem to block each other. I tried using less passengers per flight, which delayed the problem (or even solved it when I used very small numbers). However, the passenger numbers causing the problem are realistic (around 100) and so is the sizing of the GateArea.

Is there a way to tell passengers to "push" other agents to create a pathway or another way to solve the problem without lowering the numbers (and therefore compromising the simulation quality)?

Crowded Gate with error indication

PS. This is my first question on StackOverflow, so feel free to advise me on how to improve the question. I am hoping to get enough reputation to upvote the answers at other AnyLogic questions, since they helped more than once to overcome some deadlocks.

1 Answer 1

1

Assuming that there really aren't any obstacles other than other pedestrians, then the parameter that can help improve your situation is the diameter of the pedestrian. Reducing it means that pedestrians can get closer to each other.

enter image description here

You can also change the diameter dynamically at any point of your simulation using ped.setDiameter( x ). So for example, you can set it to 0 at that specific point in time until the pedestrian leaves that area and change it back to 0.5.


Following the discussion in the comments, it appeared that the issue was not the diameter. Nonetheless, I am keeping it above as it might be the issue for someone facing a similar problem.

The real issue was that the modeler asking the question was making the agent leave the pedestrian flow chart using remove(agent). Once the agent is sent back to the flowchart using an Enter block, AnyLogic no longer recognizes that agent as a pedestrian present in the pedestrian network.

As such, instead of using Enter block, pedEnter should be used. The latter requires as input the location of the pedestrian's appearance. Since in your case the pedestrian is not really moving, just leaving the flowchart for modeling purposes, you can specify the location as the agent's current location as shown below.

enter image description here

Sign up to request clarification or add additional context in comments.

11 Comments

Thanks for your quick reply! Unfortunately, it doesn't solve my problem. I was not aware that it is possible to change it during the agents lifetime and played a bit with different diameters and Change-Diameter-Timepoints. Since I use a Fixed Seed, the problem always appears at the same model time. Changing the diameter or the number of agents influences the time of occurence, therefore both parameters must influence the problem.
Furthermore I learned, that it is not a general problem of entering a specific "ServiceWArea", since it sometimes, but not always happens when the first agents wants to enter. Additionally it does not always happen with the same ServiceWArea, so it is not tied to a specific one (but with small diameter/nr of agents it is possible, that they will successfully use all of them with the problem appearing later in that run). Sometimes the agent really seem to be blocked by other agents (they are blocking the shortest way), but sometimes the shortest path appears fee when the engine stops.
Thanks for that remark! It took me a few tries to figure out, how to get the pedEnter to work properly. But with the settings "Appears at point (x,y), "X: ped.getX()", "Y: ped.getY()" within the pedEnter-block, it works for me. Additionally, I use a fixed diameter, since it is not really relevant and the walking speed is a parameter inside the agents, accessible via ped.p_walkingSpeed. Therefore the pedestrians seem to show a reasonable and stable behavior. Thanks again for your help!
Indeed, the trick is to update the location of the pedestrian since you have no choice but to specify a location of arrival. Getting the agent's current X and Y position resolves it. I will update my answer for future reference.
I've updated the answer. I think now it reflects your issue in case someone in the future faces a similar problem.
|

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.