Abstract2DEnvironment
Models a bidimensional environment.
Parameters
the incarnation to be used.
Type Parameters
concentration type
Position2D type
Properties
Override this property if units measuring distance do not match with units used for coordinates. For instance, if your space is non-Euclidean, or if you are using polar coordinates. A notable example is using geographical latitude-longitude as y-x coordinates and meters as distance measure.
Functions
Adds to the simulation a predicate that determines whether a simulation should be terminated.
Calculates the shortest paths using the Floyd-Warshall algorithm calculating the Hop Distance between nodes.
Computes the diameter of all subnetworks in the environment. The diameter is the longest shortest path between any two nodes. Returns a Map mapping each node to the subnetwork it belongs to.
Computes the diameter of all subnetworks in the environment. The diameter is the longest shortest path between any two nodes, evaluated using the allShortestHopPaths method. Returns a Set containing the subnetworks.
Computes the diameter of all subnetworks in the environment. The diameter is the longest shortest path between any two nodes, evaluated using the allShortestHopPaths method. Returns a Set containing the subnetworks.
Movements are unconstrained: subclasses constraining them override this function, starting from the position that it returns.
Returns true the network is segmented, false otherwise.
Moves node to the farthestReachablePosition towards position, extending the environment to include it.
Returns the diameter of the network in environment units if it is not segmented, and NaN otherwise.