Struct MechanicalLayer

Struct Documentation

struct MechanicalLayer

Class representing the mechanical behavior of a crowd of pedestrians.

This class handles the mechanical interactions between pedestrians in a crowd. It keeps track of the positions, velocities, orientations, and forces acting on each pedestrian. The class also provides methods for updating the positions and velocities of the pedestrians and saving the configuration to a file.

Public Functions

explicit MechanicalLayer(std::list<Agent*> &mech_active_agents)

Constructor for the MechanicalLayer class.

It is the main function of the mechanical layer. It will "prepare" the mechanically active agents, read the Interactions file to get possible already existing contacts, loop on dt_mech and produce the output Interactions file.

Parameters:

mech_active_agents -- Reference to a list of pointers to Agent objects representing the active agents in the crowd.

~MechanicalLayer()

Destructor for the MechanicalLayer class.

Destructor for the CrowdMech class.

This destructor transfers computed data to the agents.