Version 14 (modified by sward, 6 years ago) (diff) |
---|
Multi Agent System (MAS)
With r3159 a Multi Agent System (MAS) has been added to PALM. It can be used to simulate the movement of pedestrians (e.g. in urban areas).
Click on any icon below to get to the respective part of the documentation.
The embedded Multi Agent System (MAS) allows for the modeling of pedestrian movement in complex (urban) terrain. The following text provides an overview of the model's functionality as well as underlying concepts. This will cover the topics of creating a visibility graph, pathfinding, and Social Forces for collision avoidance.
For a list of input parameters, see agent_pararmeters.
Navigation
This section contains information concerning agent navigation. This includes preprocessing and online steps .
Pathfinding
During the simulation each agent receives target coordinates (see at_x and at_y). Each agent must then find a path from its current position to its target using the visibility graph. This is accomplished using the A*-algorithm which is a well-known fast pathfinding algorithm (click here for a thorough explanation). For this,
Each agent calculates the direction toward its next intermittet target during each agent time step. It will accelerate toward those coordinates. Once the agent has come close enough (dist_to_int_target) to them, the next intermittent target is chosen. When the final target is reached, the agent is deleted.
|
Social Forces
Agent movement and close-range interaction is implemented using a modified Social Force Model. The implementation uses concepts from the original Social Force Model (Helbing, 1995) and an extension of it for close-rage collision prediction and avoidance (Karamouzas et. al, 2014).
The Social Forces approach is based on the idea that pedestrian movement is results from forces exerted on the pedestrian by its surroundings and goals. These forces can be either repulsive or attractive. Repulsive forces are associated with obstacles such as buildings, trees or other pedestrians. The current goal of each pedestrian exerts an attractive force on it. The resulting force on a pedestrian α is the sum of all attractive and repulsive forces,
![\begin{equation*}
\vec{F_{\alpha}} = \sum_i{\vec{F_i}}.
\end{equation*}](/trac/tracmath/d26bbbd4b77351c433a3c02ae2d69573370f33ff.png)
The forces considered here are repulsion by obstacles and other pedestrians as well as the acceleration term driving the pedestrian toward its target.
The repulsion by an obstacle B is defined as
![\begin{equation*}
\vec{F}_{\alpha B} = - \nabla_{\vec{r}_{\alpha B}} U(|\vec{r}_{\alpha B}|),
\end{equation*}](/trac/tracmath/d054a0c8e9891d0b827f699c3e1729eacc9f3365.png)
with the repulsive potential
![\begin{equation*}
U = (|\vec{r}_{\alpha B}|) = U_0 \cdot e^{-|\vec{r}_{\alpha B}|/R_{B}}.
\end{equation*}](/trac/tracmath/d8405c09e37cee4d0dcd961ea843ba38179067c9.png)
In the MAS, U0 is repuls_wall and RB is sigma_rep_wall.
The repulsion by another pedestrian β is defined as
![\begin{equation*}
\vec{F}_{\alpha \beta} = - \nabla_{\vec{r}_{\alpha \beta}} V(|\vec{r}_{\alpha \beta}|),
\end{equation*}](/trac/tracmath/85a8e74802a1c34606ff5198ec5ccf754969734e.png)
with the repulsive potential
![\begin{equation*}
V = (|\vec{r}_{\alpha \beta}|) = V_0 \cdot e^{-|\vec{r}_{\alpha \beta}|/R_{\beta}}.
\end{equation*}](/trac/tracmath/506b1820d42e60c2a72c84ef96ec871165896731.png)
In the MAS, V0 is repuls_agent and Rβ is sigma_rep_agent. This agent repulsive force is only used if α and β are already colliding (i.e. two circles with centers at the respective agents' position with radius radius_agent are intersecting). Otherwise, a collision avoidance force according to (Karamouzas et. al, 2014) is calculated:
![\begin{equation*}
\vec{F}_{\alpha} = -\nabla_{\vec{r}_{\alpha \beta}} \left( \frac{k}{\tau^2}e^{-\tau/\tau_0} \right).
\end{equation*}](/trac/tracmath/4ff6310038e554e33aaed75b3c9fc8f3d5512c70.png)
Here, τ is the time until, given the current trajectory, a collision between the two pedestrians would occur, τ0 = 3 s and k is a constant to sets the units with a value of 1.5 m2 kg.
The acceleration force
![\begin{equation*}
\vec{F_a} = \frac{}{}(v_0\vec{e}_{\alpha} - \vec{v}_{\alpha})
\end{equation*}](/trac/tracmath/49d203ef84ab4a8c4be58d05f52a73b1c68628e2.png)
describes the tendency of a pedestrian to accelerate toward its target. Here, τα is a relaxation time (tau_accel_agent) that describes how quickly the pedestrian approaches v0 its desired walking speed with the direction to its current target, e.
The pedestrian's walking speed is given by
![\begin{equation*}
\frac{d\vec{v}_{\alpha}}{dt} = \vec{F}_{\alpha},
\end{equation*}](/trac/tracmath/a7f5d78145fa4cd98066bcc1a383d7479b0280e3.png)
with a simple Euler-forward method used for time-integration.
Examples
For an example job to get to know the agent model, have a look at
trunk/EXAMPLES/agents
NAMELIST group name: prepro_par
Parameter Name | FORTRAN Type | Default Value | Explanation |
---|---|---|---|
flag_2d | L | .F. |
Flag to force usage of 2d-buildings. |
internal_buildings | L | .F. |
Flag to control usage of buildings within courtyards. |
tolerance_dp | R * 3 |
1.41, |
Tolerance for simplification of building polygons during preprocessing. |
References
- Helbing, D., Molnar, P. (1995). Social force model for pedestrian dynamics. Physical review E, 51(5), 4282. doi
- Hershberger, J., Snoeyink, J. 1994. An O(nlogn) implementation of the Douglas-Peucker algorithm for line simplification. SCG '94 Proceedings of the tenth annual symposium on Computational geometry. 383-384. doi
- Karamouzas, I., Skinner, B., Guy, S.J. 2014. Universal Power Law Governing Pedestrian Interactions. Pyhsical Review Letters, 113, 238701. doi
Attachments (11)
- pathfinding_berlin.gif (6.1 MB) - added by sward 6 years ago.
-
color_scheme.png
(10.0 KB) -
added by sward 6 years ago.
Color scheme for the buttons
-
lm_mono_caps_10_font.zip
(41.5 KB) -
added by sward 6 years ago.
Caps font for buttons
- button_template.pptx (64.4 KB) - added by sward 6 years ago.
- button_a_star.png (50.0 KB) - added by sward 6 years ago.
- button_code_structure.png (63.9 KB) - added by sward 6 years ago.
- button_ex_setup.png (54.5 KB) - added by sward 6 years ago.
- button_input.png (52.8 KB) - added by sward 6 years ago.
- button_output.png (63.1 KB) - added by sward 6 years ago.
- button_prepro.png (64.9 KB) - added by sward 6 years ago.
- button_social_force.png (76.3 KB) - added by sward 6 years ago.