3 minute read

The Flocking Algorithm

Flocking is the natural behaviour visible when a group of agents, called a flock, are foraging or in flight.

The set of rules that stand behind this behaviour can also generally be applied to the “flocking” behaviour of other species. As a result, the term “flocking” is sometimes applied, in computer science, to species other than birds.

Advertisement

It is considered an emergent behaviour arising from simple rules that are followed by individuals and does not involve any central coordination.

In the next pages the main rules we learned to control and customise during the workshop are summarised

(our customised code lines in purple)

2D Studies

Base Rules

Workshop II Workshop II

Our experimentation in search for emergent patterns starts from basic geometrical concepts

The simple starting shape is tested together with additional perceptive analogs in order to understand how different starting position can show similar trajectories

Dec 2022

Our experimentation in search for emergent patterns starts from basic geometrical concepts

The simple starting shape is tested together with additional perceptive analogs in order to understand how different starting position can show similar trajectories

Our experimentation in search for emergent patterns starts from basic geometrical concepts

The simple starting shape is tested together with additional perceptive analogs in order to understand how different starting position can show similar trajectories

Clearer central symmetries in the patterns, compared to triangular starting point

Populating on broader areas creates more branching

Additional effect of the bouncing to create

Additional population in the center not affected by repellers – can provide additional strenght to the trail

Workshop II

Workshop II

Parameter Study

Agents Pinball

Directionality

and Repeller sets Combinig lessons learned from pattern, directionality and parameters studies.

Combinig lessons learned from pattern, directionality and parameters studies.

At the end of the 2D experimentation a system of gradients has also been explored, speculating on a subsequent possible outcome in the 3D space

3D Studies

Test C - Acceleration

Repeller

Attractor

Eroding Behaviours

Adding parameters to Individual agents instead of global behavior_Acceleration Having agents with different speed can create layering effect or spear -shaped form. Velocity Vector multiplied by Acceleration Vector ’s magnitude

Variables: Neighbor Boundary

Constant Speed Behavior

Flock behavior with one-direction velocity

Constant Acceleration Behavior

Constant Speed Behavior

Flock behavior with one-direction velocity

Adding Acceleration, updating the speed

Constant Acceleration Behavior

Adding Acceleration, updating the speed

Adding Acceleration (local) and observing the change of pattern and behavior (Global)

A color range indicating the agent’s speed based on position. Blue indicating slower agents and Red indicating the faster.

Eroding Behaviours

Different group sizes as Starting points

Four groups in different size accelerated according to flock size.

Local Rule; Acceleration Force

Coordinates as Starting points

Two planes moving with delay creating intertwined pattern.

Neighbor-based Acceleration

Maximum Range of Neighbors Applied

Maximum Range of Neighbors Applied

Waves and Branches

The Smaller the group (fewer Neighbors) the Faster. Having a min and max range, creating multiple waves based on the number of neighbors.

Eroding Behaviours

Branching from Within

The Larger the group (more Neighbors) the Faster. The corners with fewer neighbors and the center with more, causing different speeds in one flock.

Local Rule; Acceleration Force

- Vertical Flock - Horizontal Flock

Privious 2D experiments with range affecting the flow and pattern.

Phase of Branching

Showing effects on the Final pattern and behavior

Segmenting the environment into pieces with different acceleration vectors based on distance.

Local Rule; Acceleration Force

Dividing the tunnel into three segments with different acceleration.

Pink Planes representing increase in acceleration and white decrease in acceleration.

The chosen 2D pattern from previous experiments based on branching capacity and diversity and rearranging it in the 3D environment.

Horizontal Flow in Grid-Based Extruded Frame

Vertical Flow in Grid-Based Extruded Frame

Horizontal Flow in Grid-Based Extruded Wide Tunnel

Vertical Flow in Grid-Based Extruded Surface

Difining the boundries; Adding a pattern of attractors and repellers based on previous 2D experiments in Multiple layers with grid setting to various environments to analys the behaviour of the flock.

3D Boundaries Categorization

Less control in case of directionality and observing similar patterns to 2D environments

Approaching the tested volume in a vertical manner and observing new patterns and behaviors. The flock’s reaction to dense attractor and repeller pattern prevents vast branching through the volume.

Rule; Acceleration Force

The Vein Less Separated Centralized Branching

The Lines Horizontal Alignment of the branches.

The Table 5-Point Concentrated Branching

The Multiple Hives Having Cohesive Flocks

Patterns in various depths of the volume from surface to the bottom are emerged according to a change of strength while a vertical wave of agents (the flock) face the setting of attractors and repellers and dodge in the redefined boundries.

The Sandbox Local Rule; Acceleration Force

- Vertical Flock

Dodged & Emerged

Flock high seperation resulting a pattern emerged from individual behaviour of agents.

Behavior of Two Various sizes of groups resulting in mixture of patterns in a single flock.

Symmetrical Behavior

Similar to 2D pattern experiments, the flock creating curves avoiding the center.

Branching through Flock’s decision to gather in large groups to avoid obstacles.

Patterns emerged from the dodging behaviour of agents in wider environment for horizontally moving flock. Multiple forms of branching with various initial decision of the flock.

The Sandbox Local Rule; Acceleration Force

- Horizontal Flock

Final experiments on weak boundaries

This article is from: