fpmas 1.6
Public Member Functions | List of all members
fpmas::model::UniformGridAgentMapping Class Reference

#include <grid_agent_mapping.h>

Inheritance diagram for fpmas::model::UniformGridAgentMapping:
Inheritance graph
[legend]
Collaboration diagram for fpmas::model::UniformGridAgentMapping:
Collaboration graph
[legend]

Public Member Functions

 UniformGridAgentMapping (DiscreteCoordinate grid_width, DiscreteCoordinate grid_height, std::size_t agent_count)
 
- Public Member Functions inherited from fpmas::model::RandomGridAgentMapping
template<typename DistributionX , typename DistributionY >
 RandomGridAgentMapping (DistributionX &&x, DistributionY &&y, std::size_t agent_count)
 
std::size_t countAt (api::model::GridCell *cell) override
 
virtual std::size_t countAt (api::model::GridCell *cell)=0
 

Detailed Description

api::model::SpatialAgentMapping implementation for grid environments.

Agents are uniformly distributed on a grid of the specified size.

Constructor & Destructor Documentation

◆ UniformGridAgentMapping()

fpmas::model::UniformGridAgentMapping::UniformGridAgentMapping ( DiscreteCoordinate  grid_width,
DiscreteCoordinate  grid_height,
std::size_t  agent_count 
)
inline

UniformGridAgentMapping constructor.

X and Y coordinates are uniformly assigned in [0, grid_width-1], and [0, grid_height-1] respectively.

Parameters
grid_widthgrid width
grid_heightgrid height
agent_countagent count

The documentation for this class was generated from the following file: