Environments

Environments are objects in which agents can inhabit a specific position. The connection between positions is defined by the environment’s topology. There are currently three types:

  • Grid n-dimensional spatial topology with discrete positions.

  • Space n-dimensional spatial topology with continuous positions.

  • Network graph topology consisting of AgentNode and edges.

All three environment classes contain the following methods:

  • add_agents() adds agents to the environment.

  • remove_agents() removes agents from the environment.

  • move_to() changes an agent’s position.

  • move_by() changes an agent’s position, relative to their current position.

  • neighbors() returns an agent’s neighbors within a given distance.