0
votes

I am very new to Anylogic and am trying to send/receive information between agents, but not sure how to accomplish that. Attached please find an image which shows connections between agents. It also shows two-way connections between agents and dependent variables 1.

  • What parameters/settings does one need to change to develop such a diagram?
  • So far I have tried embedding a dynamic variable inside the agent and then drawing a connector between the agent and a dependent variable - but doing so replaces the agent icon with a dynamic variable icon.
1
Hi, welcome to SOF. sounds like you are best off doing some more AnyLogic tutorials, especially the SD ones, but others as well. There are example models showing you agent communication. Or rephrase your question be to more specific. "How can I do this diagram" is not a good question. Also check stackoverflow.com/help/how-to-ask :-) Happy to helpBenjamin
Thank you. My question is if I define 2 single agents, can I connect them graphically with a connector and use that same connector to pass messages. When I draw a connector between two agents, it does not get connected at either ends. Putting a port inside both agents, allows me to connect the agents, but at the higher level, the agent default symbol is replaced with a port. I do not understand why connecting two agents has to be so complicated in Anylogic. What I am trying to model is a plant control system; a DCS sends a command to turn on/off a chiller and vice versa.Shaharyar Khan

1 Answers

0
votes

you cannot connect agents graphically with connectors (except in special cases).

Normally, you use the "Agent Link" objects to establish agent connections and send messages. In short, you do the following:

  1. drag it into agent type 1
  2. Set it up to connect to agent type 2
  3. when it asks to create a corresponding Agent Link object in type 2, agree

Now, you have a way to connect agents using the agent link object.

Do check the AnyLogic help and tutorials on that, there is a lot of info on how to use them.