Aman, May 2024.
Parallel navigation involves a pursuer maintaining a constant bearing angle with its target. Let R(t) be the range vector from the pursuer to the prey at time t:
\[ \mathbf{R}(t) = \mathbf{P}_{prey}(t) - \mathbf{P}_{pursuer}(t) \]
The pursuer aims to keep the angle \( \theta(t) \) between \( \mathbf{R}(t) \) and its heading direction \( \mathbf{H}(t) \) constant:
\[ \theta(t) = \arccos \left( \frac{\mathbf{R}(t) \cdot \mathbf{H}(t)}{|\mathbf{R}(t)||\mathbf{H}(t)|} \right) \]
The velocity of the pursuer \( \mathbf{V}_{pursuer}(t) \) is updated to steer towards the prey:
\[ \mathbf{V}_{pursuer}(t) = \mathbf{V}_{prey}(t) + k \left( \mathbf{R}(t) \times \mathbf{\hat{n}} \right) \]
where \( k \) is a gain factor and \( \mathbf{\hat{n}} \) is a unit vector perpendicular to the plane formed by \( \mathbf{R}(t) \) and \( \mathbf{V}_{prey}(t) \).
Apparently dragonflies don't do parallel pursuit.
Just having 1 prey and 1 predator gets lonely (see parallel pursuit). So let's add a flock of boids.
Boids exhibit three basic behaviors:
\[ \mathbf{F}_{sep} = \sum_{i=1}^{N} \frac{\mathbf{R}_{i}}{|\mathbf{R}_{i}|^2} \]
\[ \mathbf{F}_{ali} = \frac{1}{N} \sum_{i=1}^{N} \mathbf{V}_{i} - \mathbf{V}_{boid} \]
\[ \mathbf{F}_{coh} = \frac{1}{N} \sum_{i=1}^{N} \mathbf{P}_{i} - \mathbf{P}_{boid} \]
The total acceleration \( \mathbf{A}_{boid} \) is the sum of these forces:
\[ \mathbf{A}_{boid} = c_{sep} \mathbf{F}_{sep} + c_{ali} \mathbf{F}_{ali} + c_{coh} \mathbf{F}_{coh} \]
Boid Max Force
Boid Max Speed
Perception Radius
Predator Perception Radius
Predator Max Speed
Predator Max Force
Kill Time (ms)
Target Boid
Number of Boids