Hostname: page-component-7b7567c8c-tnzcf Total loading time: 0 Render date: 2026-11-14T02:14:17.722Z Has data issue: false hasContentIssue false

A hybrid numerical model for the collective motion of fish groups

Published online by Cambridge University Press:  14 April 2025

Xuewei Mao
Affiliation:
State Key Laboratory of Fluid Power and Mechatronic Systems, Department of Mechanics, Zhejiang University, Hangzhou 310027, PR China
Jiadong Wang
Affiliation:
State Key Laboratory of Fluid Power and Mechatronic Systems, Department of Mechanics, Zhejiang University, Hangzhou 310027, PR China
Xingyuan Mao
Affiliation:
State Key Laboratory of Fluid Power and Mechatronic Systems, Department of Mechanics, Zhejiang University, Hangzhou 310027, PR China
Jian Deng*
Affiliation:
State Key Laboratory of Fluid Power and Mechatronic Systems, Department of Mechanics, Zhejiang University, Hangzhou 310027, PR China
*
Corresponding author: Jian Deng, zjudengjian@zju.edu.cn

Abstract

We propose a hybrid numerical model for the collective motion of fish groups, which integrates an agent-based model with a computational fluid dynamics (CFD)-based model. In the agent-based model, the fish group is represented by self-propelled particles (SPPs), incorporating social forces with local interactive rules. The CFD-based model treats the fish body with an undulated filament that responds to the hydrodynamic forces imposed by the surrounding fluid flow. These two models are coupled using a central pattern generator controller. We test this hybrid model with groups of 30–50 individuals. The results show that the group exhibits various collective behaviours, including tight schooling, sparse schooling and milling patterns, by adjusting the coefficients in the SPP model. Due to the hydrodynamic interactions, particularly with the obstacle avoidance model, both the individuals’ and the group’s mean speed fluctuate, differentiating it from traditional SPP models that typically consider volumeless particles. More interestingly, our findings indicate that fish benefit from collective motion in terms of energetic consumption in both schooling and milling patterns. It is important to note that the swimming fish are actuated using a very simple mechanism without any optimisation strategy. An additional study investigates the effects of the Reynolds number, demonstrating the capability of the current hybrid model to account for fish groups of varying body lengths or swimming speeds. Future applications of this model are promising, offering potential insights into the energetic advantages of collective motion in large-scale fish groups.

Information

Type
JFM Papers
Copyright
© The Author(s), 2025. Published by Cambridge University Press
Figure 0

Figure 1.A schematic of a SPP $i$ and its neighbourhood. The tendency to maintain is previous direction vector $\mathbf {e}_{i, t}^{\|}$, the attraction to the global centre of mass ${\mathbf {G}}_{i, t}$ and the noise vector $\hat {\boldsymbol {\epsilon }}_{i, t}$ are independent of the local neighbourhood. The particle $i$ interacts with its neighbours within a distance $R_p$ through local attraction $\hat {\mathbf {C}}$ and alignment $\hat {\mathbf {A}}_{i, t}$, except for the blind zone specified by $\beta _b$ of the focal particle $i$. The particle $i$ experiences a repulsive force $ \mathbf {F}_{i, t}$ by its neighbours with a distance less than $R_r$. Note that there is no blind zone for the repulsion.

Figure 1

Table 1.The expressions for different terms in (2.3), representing different interaction rules. Here, $i$ represents the focal individual and $m$ represents its neighbour; $V_p$ and $V_r$ denote the perceptual and repulsive zones, as illustrated respectively by orange and grey colours in figure 1; and $V$ represents the entire computational domain. The simulated results for two typical set-ups, 1 and 2, are plotted in figure 2.

Figure 2

Figure 2.Plots of the instantaneous swimmer positions for two different numerical set-ups of the SPP model (as listed in table 1) representing two distinct collective patterns: ($a$) schooling for set-up 1 and ($b$) milling for set-up 2. Both cases consider 20 individuals.

Figure 3

Figure 3.Schematic illustration of the hybrid model, which couples the SPP model and the CFD model through a CPG controller.

Figure 4

Figure 4.Illustration of the buffer zone for collision avoidance when two fish approach too closely to each other. Here, $\mathbf {e}_{i}$ represents the directional vector of the currently considered fish, and $\mathbf {e}_{j}$ represents the directional vector of its neighbour. The vector $\mathbf {r}_{j}-\mathbf {r}_{i}$ is the distance vector of the two fish heads. The angle $\beta _{ij}$ is the intersection angle between $\mathbf {e}_{i}$ and $\mathbf {r}_{i}$, and $\beta _{c}$ is a critical angle, and we set $\beta _{c} = \beta _{b}$.

Figure 5

Table 2.Model parameters used in the basic function tests, corresponding to the simulated results shown in figures 5 and 6. Note that $R_p$ and $R_r$ are illustrated in figure 1; $R_s$ is illustrated in figure 4; and $a$, $c$, $d$, $r$ and $g$ are the SPP model weights, as listed in table 1.

Figure 6

Figure 5.Basic functionality test of the hybrid model with a minimal group of two fish. ($a$) Depicts an approach followed by side-by-side swimming, while ($b$) illustrates mutual orbiting behaviour. Swimming trajectories are shown as lines in different colours (red and black) for the two individuals. The dots without arrows indicate the starting positions, and arrows represent the instantaneous swimming directions. The flow fields are coloured by the velocity magnitude, with a gradient from light blue (low velocity) to dark blue (high velocity). Model parameters are listed in table 2.

Figure 7

Figure 6.Basic functionality test of the hybrid model with a minimal group of two fish. ($a$) Shows an approach followed by staggered departure, while ($b$) shows an approach follow by departure at a certain distance. Swimming trajectories are shown as lines in different colours (red and black) for the two individuals. The dots without arrows indicate the starting positions, and arrows represent the instantaneous swimming directions. The flow fields are coloured by the velocity magnitude, with a gradient from light blue (low velocity) to dark blue (high velocity). Model parameters are listed in table 2.

Figure 8

Figure 7.Contour plots of the order parameter $P$ and the milling parameter $M$ within the parametric space defined by the parameters $a$ and $c$: ($a$) $P$ increases with the rise in $a$, marking the phase transition to a highly coordinated schooling pattern; ($b$) $M$ identifies a milling pattern in the bottom-left corner, where both the local alignment term and local attraction terms are at low intensities. For each pair of parameters $a$ and $c$, 50 simulation runs are conducted with varying random initialisation over 8 000 time units, with the last 1 000 time units used to calculate the average values of $P$ and $M$.

Figure 9

Figure 8.Simulation results for an uncontrolled fish swimming with varying mesh resolutions: ($a$) swimming speed and ($b$) vorticity contours.

Figure 10

Table 3.The parameters set for four simulation cases. The parameters are derived from (2.3). For more details, please refer to table 1.

Figure 11

Figure 9.Vorticity contours of four modes at the stable state: ($a$) S0, tight schooling mode at $t/T=50$; ($b$) S1, sparse schooling mode with $N=30$ at $t/T=58$; ($c$) S2, sparse schooling mode with $N=50$ at $t/T=45$; ($d$) M1, milling mode at $t/T=50$. Here, $T$ denotes the initial undulation cycle, which is used to normalise the time in all results presented in this study. Supplemental movies S0, S1, S2 and M1 present dynamic evolutions of these modes.

Figure 12

Figure 10.($a$) Box plots of the area occupied by the entire fish group, calculated based on the convex hull, over the time interval between $40T$ and $60T$. These plots highlight the variations in spatial occupation over time. The central line in each box denotes the median, while the box itself represents the interquartile range, indicating the spread of the middle $50\, \%$ of the data. ($b$) The time-averaged Besag function $\langle \hat {L}(r)\rangle$ for simulations of four groups, plotted as a function of spatial scale $r$. A positive $\hat {L}(r)$ indicates clustering of individuals at a given scale, while a negative $\hat {L}(r)$ suggests segregation.

Figure 13

Figure 11.Time histories of order parameters $P$ and $M$ in four different modes: S0, S1, S2 and M1, with time non-dimensionalised by the initial undulatory period.

Figure 14

Figure 12.Illustration of individual trajectories in swimming groups for different modes: ($a$) S0, ($b$) S1, ($c$) S2 and ($d$) M1. The trajectory colours transition from light yellow to dark blue as time progresses, and the trajectories are recorded from 20$T$ to 60$T$. Note that 20$T$ marks the time when stable collective patterns emerge.

Figure 15

Figure 13.Individual speeds as a function of time for four different modes: ($a$) S0, ($b$) S1, ($c$) S2 and ($d$) M1, spanning from time 0 to 60$T$. The blue line represents the group’s average speed, smoothed using a moving average with a window of $T$. The grey shaded area represents the standard deviation among individual speeds within the group, illustrating the variability in speed across different group members.

Figure 16

Figure 14.Time series of the oriented angle for four different modes: ($a$) S0, ($b$) S1, ($c$) S2 and ($d$) M1, spanning from time 0 to 60$T$. The blue line represents the group’s average angle of orientation, smoothed using a moving average with a window of $T$. The grey shaded area represents the standard deviation of oriented angles among the individuals, indicating the variation in alignment within the group over time.

Figure 17

Figure 15.Numerical simulations of straight-line swimming (denoted as ‘single straight’) and continuous turning (denoted as ‘single turning’) of a single fish at the highest frequency $\omega =1.0$ and maximum undulatory amplitude ($A=0.2$), with the parameter $B=0.2$ for the continuous turning (refer to (2.11) and (2.13)). ($a$) Shows the speed of the fish, and ($b$) presents the CoT efficiency. Dark lines indicate values averaged over the motion cycles.

Figure 18

Figure 16.Box plots of ($a$) swimming speed and ($b$) CoT efficiency for four modes: S0, S1, S2 and M1, averaged from $40T$ to $60T$. The data in each box represent time-averaged values for all individuals in the groups over this period. The dashed lines (blue for straight-line swimming and orange for continuous turning) represent the mean speed of a solitary swimmer.

Figure 19

Figure 17.Scatter diagram of relative position in mode M1 for average values of ($a$) speed and ($b$) CoT efficiency from $40T$ to $60T$. The diagram is presented in polar coordinates with the origin at the group centre. The red arrow points to a focused fish, labelled as A.

Figure 20

Figure 18.Illustration of energy savings of fish A (referred to by an arrow in figure 17, and highlighted with green colour in this figure) by leveraging the macroscopic properties of the flow. ($a$) The average CoT efficiency of fish A from 40$T$ to 60$T$, with a dashed line marking the CoT value for a single continuous turning fish. The height of each square column represents the value averaged over each interval $T$. Panels ($b$) and ($c$) show local vorticity contours around fish A for the two time periods highlighted in red in ($a$).

Figure 21

Figure 19.Time histories of (a) $P$ and (b) $M$ for two fish groups with different Reynolds numbers. The blue lines represent $Re\simeq 500$, and the orange lines indicate $Re\simeq 3000$.

Figure 22

Figure 20.Instantaneous vorticity contours of fish groups at $t = 65T$ for ($a$) $Re\simeq 3000$ and ($b$) $Re\simeq 500$. The vortical field for the lower Reynolds number ($Re\simeq 500$) shows a tighter milling pattern, whereas the wakes behind individuals appear more diffusive.

Supplementary material: File

Mao et al. supplementary material movie 1

S0 Dynamic evolution of mode S0.
Download Mao et al. supplementary material movie 1(File)
File 25 MB
Supplementary material: File

Mao et al. supplementary material movie 2

S1 Dynamic evolution of mode S1.
Download Mao et al. supplementary material movie 2(File)
File 18.2 MB
Supplementary material: File

Mao et al. supplementary material movie 3

S2 Dynamic evolution of mode S2.
Download Mao et al. supplementary material movie 3(File)
File 19.4 MB
Supplementary material: File

Mao et al. supplementary material movie 4

M1 Dynamic evolution of mode M1.
Download Mao et al. supplementary material movie 4(File)
File 49.6 MB