Thank you for visiting nature.com. You are using a browser version with limited support for CSS. To obtain the best experience, we recommend you use a more up to date browser (or turn off compatibility mode in Internet Explorer). In the meantime, to ensure continued support, we are displaying the site without styles and JavaScript.

# Self-organisation and convection of confined magnetotactic bacteria

## Abstract

Collective motion is found at all scales in biological and artificial systems, and extensive research is devoted to describing the interplay between interactions and external cues in collective dynamics. Magnetotactic bacteria constitute a remarkable example of living organisms for which motion can be easily controlled remotely. Here, we report a new type of collective motion where a uniform distribution of magnetotactic bacteria is rendered unstable by a magnetic field. A new state of “bacterial magneto-convection” results, wherein bacterial plumes emerge spontaneously perpendicular to an interface and develop into self-sustained flow convection cells. While there are similarities to gravity driven bioconvection and the Rayleigh–Bénard instability, these rely on a density mismatch between layers of the fluids. Remarkably, here no external forces are applied on the fluid and the magnetic field only exerts an external torque aligning magnetotactic bacteria with the field. Using a theoretical model based on hydrodynamic singularities, we capture quantitatively the instability and the observed long-time growth. Bacterial magneto-convection represents a new class of collective behaviour resulting only from the balance between hydrodynamic interactions and external alignment.

## Introduction

Examples of collective motion can be found in many biological systems over a wide range of length scales1, from animal herds2, bird flocks3 and schools of fish4, to individual cells5. Microorganisms swimming in viscous fluids at low Reynolds numbers can form coherent patterns that depend on the propulsion modes of the swimmers6,7,8. For instance, randomly-swimming cells such as bacteria9 and spermatozoa10 are able to self-organise into large-scale coherent structures.

In contrast with the random motion of many cells, micro-swimmers and artificial swimmers can also bias their movement in response to external cues. The bias can arise actively, as in the cases of chemotaxis11 and phototaxis12, or passively, for example gyrotactic swimmers13, resulting in emergent pattern-formation in dense systems—a characteristic of collective locomotion. A classic example in this case is bioconvection, an instability initiated by the accumulation at an interface of gyrotactic14 or phototactic15 swimmers that are denser than the surrounding fluid. The resulting density stratification is unstable16, which leads to the formation of downward falling plumes17, 18. Boundaries and confinement19, 20 also strongly affect the swimming of microorganisms and their hydrodynamic interactions21. Although back-flow generated by boundaries tends to screen swimmer-swimmer interactions, the emergence of wall-driven attractive interactions has been observed, leading to orbiting22 and large-scale clustering at a wall23.

Magnetotactic bacteria (MTB) are prokaryotic micro-swimmers found in abundance in freshwater and marine habitats24. These bacteria can synthesize magnetosomes, membrane-bounded, magnetic nanocrystals often assembled into chain-like structures within the cytoplasm25. Magnetosomes confer to each cell a permanent magnetic dipole moment, forcing the swimming bacterium to align with external magnetic fields. The orientation and direction of motion of MTB can thus be manipulated remotely using controlled magnetic fields26,27,28. MTB can be used as a source of magnetosomes, which have demonstrated a great potential for medical applications due to their unmatched chemical purity and magnetic properties29. Furthermore, MTB have even been proposed as potential agents for targeted drug delivery30. A thorough understanding of the individual and collective properties of MTB is thus needed to fully exploit their potential for practical applications. The wall-mediated behaviour of single and pairs of MTB has been explored31, and attractive hydrodynamic interactions lead to clustering near a wall32. Various patterns and instabilities can be induced by the control and orientation of large swimmer populations33, including pearling of focused MTB in a thin capillary34, 35 or vortex formation in droplets36.

Here we report on a new type of collective motion observed in a population of confined MTB induced by the application of a magnetic field perpendicular to the confining walls. We find that a uniform distribution of magnetotactic bacteria is observed to self-organise spontaneously into bacterial plumes perpendicular to the wall, resulting in self-sustained convection cells. The observed plumes are reminiscent of bioconvection patterns and the flow generated resembles Rayleigh–Bénard convection cells37. However, an important difference exists between the phenomenon reported here and these well-studied instabilities. Both bioconvection and the Rayleigh–Bénard instability rely on a density mismatch between layers of the fluids, and thus on net (gravitational) forces applied to the fluid. In both these cases, removing the external force from the governing equations results in the absence of convective cells. In contrast, for the phenomenon reported here, no external forces are applied on the fluid and the magnetic field only exerts an external torque aligning MTB with the field34. A different mechanism thus needs to be proposed to describe the plumes and flow patterns observed.

Using a theoretical model based on hydrodynamic singularities, we show that the plumes result solely from the balance between the ordered state of the swimmers and both cell-cell and cell-wall hydrodynamic interactions. An instance of biased active matter related to previous examples in biological (phototactic, gyrotactic and chemotactic cells) and artificial systems (active phoretic particles in shear flows near surfaces), the self-sustained state reported here, which we term bacterial magneto-convection, represents therefore a new class of collective behaviour resulting only from the balance between hydrodynamic interactions and external alignment.

## Results

### Bacteria self organisation and plume formation

In our experiments, bacteria of the strain Magnetospirillum magneticum AMB-138 are confined to square capillary channels aligned along the x-axis. Capillaries are filled with a concentrated solution of MTB and an external magnetic field, B, is applied normal to the channel wall along the positive z direction (see schematic in Fig. 1a and Methods section). The field B is uniform throughout the capillary, with strength ranging from $$1 \times 10^{-4}\,{\mathrm{T}}$$ to $$20 \times 10^{-4}\,{\mathrm{T}}$$ (Fig. 1). The bacteria are confined within the tube by the walls $$z_-$$ and $$z_+$$ perpendicular to B, and by the walls $$y_-$$ and $$y_+$$ in the orthogonal directions. Images are acquired at $$10~{\mathrm{fps}}$$ and particle image velocimetry (PIV) is used to study the flow in the tubes, using bacteria as tracers. Some of the bacteria are non-motile and we observe the fluid flow generated by the plumes in the capillary. Cultures of motile and magnetic MTB were obtained through a racetrack selection method39 which results in a bacteria population dominated by a preferred polarity and therefore in bacteria that predominantly swim in one direction. Despite the selection, there is always a small minority population present with the reverse polarity which swims in the opposite direction. Due to the small size of that minority population, the reverse swimmers are neglected in our analysis.

In the absence of magnetic field, the bacteria are homogeneously distributed in the channel (Fig. 1b) with bacteria swimming in random directions. When the magnetic field is switched on, swimmers orient along the magnetic field B, and most motile bacteria start swimming towards the $$z_-$$ wall (Fig. 1a) with velocities ranging from $$\sim 4$$ to $$10\, {\upmu \mathrm{ms}^{-1}}$$. As bacteria accumulate at the $$z_-$$ wall, small clusters form and start growing. The time before the instability becomes visible depends strongly on both concentration and population of the bacteria, and ranges from a few seconds to $$50 \,{s}$$. As the clusters grow, they start forming plumes which advect bacteria through a strong backward flow (Fig. 1c). The plumes interact with their nearest neighbours and attract each other, leading to merging and formation of larger plumes, with ultimate separations between plumes comparable to the channel size (Fig. 1d) (see Supplementary movies SM1, SM2 and SM3). In the larger $$500~{\upmu \mathrm{m}}$$ capillaries we observe by changing the focus of the microscope along the y-direction, that the plumes form in the central region of the channel, as opposed to close to the walls.

We observe the plumes and measure their dynamics in 26 experiments carried out in different capillary sizes and bacterial concentrations. In a few experiments, the plumes do not appear or do not grow. The mobility of bacteria and their sensitivity to the magnetic field are two key parameters that impact the dynamics of the instability and the plume formation. The dynamical properties of the instability are quantified by the characteristic time, $$\tau _p$$, to reach the steady state. Experimentally $$\tau _p$$ ranges from $$170\text {s}$$ to $$600 \text {s}$$. Although no critical bacterial concentration can be determined, we find that lower concentrations of bacteria lead to larger $$\tau _p$$, and to formation of smaller plumes that do not reach the same late-time wavelength as concentrated systems.

Below a critical magnetic field, which depends on the bacteria population and concentration and ranges from $$2.6 \times 10^{-4} \text {T}$$ to $$10 \times 10^{-4} \text {T}$$, no plumes are observed. Above this critical field, plumes grow and evolve with dynamics unaltered by field strength (see Supplementary Material). The existence of a critical magnetic field can be understood by the necessity to have the bacteria aligned within a narrow orientation distribution along the magnetic field direction. All our experiments are carried out with magnetic fields much larger than the observed critical fields ($$2 \,{\mathrm{mT}}$$) to rule out any influence of the field strength and ensure that the bacteria remain perfectly aligned with the field (see details in Supplementary Material). We also note that at this field strength, magnetic dipole-dipole interactions between neighbouring bacteria are negligible compared to those with the applied magnetic field.

In order to quantify the dynamics of the emergent patterning, we measure the wavelength $$\lambda$$ of the plumes, defined as the average distance between neighbouring plumes, as a function of time. We locate the plumes in the experimental data by finding peaks in the intensity profile averaged along z. While we sometimes observe short-lived smaller plumes forming later in the experiments, we focus on the larger ones by defining an intensity threshold for the measured peaks (see details in Supplementary Material). Depending on the size of the channel, we observe between a few tens of plumes to two plumes at late times. As shown in Fig. 2a, the wavelength $$\lambda (t)$$ starts from an initial value $$\lambda _0$$, grows, and this growth accelerates until it reaches a plateau value at $$\lambda _p$$, after a time denoted by $$\tau _p$$. Remarkably, this final wavelength is found to scale linearly with the size of the capillary (Fig. 2a, inset). We note that in traditional convection, it is common for external length scales, including those due to confinement, to set the late-time convection wavelength37. Plotting the normalised wavelength $$(\lambda -\lambda _0)/(\lambda _p-\lambda _0)$$ as a function of the reduced time $$t/\tau _p$$ exemplifies the two regimes of the wavelength time evolution: monotonic growth followed by a plateau, as shown in Fig. 2a.

We next use PIV to measure the flow field and plot the streamlines and flow magnitude in Fig. 3a. Plumes are generated as soon as the characteristic flow velocities induced by the layer of accumulating bacteria are of the same order of magnitude as the downward velocity of the swimmers. When the wavelength becomes on the order of the channel width, hydrodynamic interactions with the walls screen the cellular flows and plumes stop growing, resulting in stable convection cells of size comparable to the channel.

### Hydrodynamic singularities model

To further understand the mechanism for the instability and its time evolution, we develop a theoretical model which successfully describes the emergence of collective behaviour and the formation of plumes in the suspension. We model AMB-1 as pusher swimmers31, 40. Each free-swimming bacterium is modelled as two opposite regularized point forces (known as stokeslets41) of strength $$s_0$$ separated by a distance $$l_0$$, taken as the characteristic size of the swimmer42 (see Supplementary Material and movies SM4 and SM5). The force-free swimmers are confined in a channel with square section a and aspect ratio 10 with periodic boundary conditions along the x direction (see Fig. 1a), and are subject to both steric and hydrodynamic interactions20. Magnetic interactions between swimmers are negligible compared to those with the external field, and are therefore neglected. We assume that the swimmers remain aligned with the external magnetic field and always tend to swim preferentially in the negative z direction at a constant speed $$-{u} _0\hat{z}$$. However, their speeds are modified by the dipolar flow fields induced by the other swimmers and by hydrodynamic interactions with walls. Our model investigates the system for values of the magnetic field above the critical field for bacterial alignment, consistent with what was done in the experiments. The model is non-dimensionalised using characteristic length scale $$l_0$$, velocity $$u_0$$ and dynamic viscosity $$\mu$$. For comparison with experiments, we use a characteristic bacterium size $$l_0 = 5\, {\upmu \mathrm{m}}$$32. Steric interactions are included using soft pair-repulsive forces43 between the centres of each bacteria. These interactions decay as A/r and, to speed up computation times, are only taken into account for bacteria closer than $$2l_0$$ and generate a speed with upper bound $$5 u_0$$. In addition to bacterium-bacterium interactions, hydrodynamic interactions also occur between bacteria and channel walls. We include the two walls normal to the magnetic field, $$z_-$$ and $$z_+$$, and use the method of images for regularized stokeslets (algebraic regularization function with a core of size $$\delta = 0.3 l_0$$) in order to enforce the no-slip boundary condition on the walls exactly (see Ref.44 and Supplementary Material). The image system for a stokeslet consists of a stokeslet, an irrotational dipole and a stokeslet dipole45 with adequate regularization. As a result, the position $${\varvec{x}}^{(j)}$$ of the $$j^{th}$$ bacterium evolves with its velocity, $${\varvec{u}}^{(j)}$$, sum of its intrinsic swimming speed $$- u_0 {\varvec{e}}_z$$, the hydrodynamic and steric interactions with other bacteria, denoted $${\varvec{u}}_{\mathrm{hydro}}$$ and $${\varvec{u}}_{\mathrm{steric}}$$ respectively, and the flow created by interactions of all swimmers with the walls, $${\varvec{u}}_{\mathrm{wall}}$$, leading to

\begin{aligned} \frac{ {\mathrm {d}} {\varvec{x}}^{(j)}}{{\mathrm {d}} t} = {\varvec{u}}^{(j)} = - u_0 {\varvec{e}}_z + \sum _{i=1}^N {\varvec{u}}_{\mathrm{wall}}^{(j)}({\varvec{x}}^{(i)};{\varvec{x}}^{(j)}) +\sum _{i \ne j} \left[ {\varvec{u}}_{{\mathrm{steric}}}^{(j)}({\varvec{x}}^{(i)}-{\varvec{x}}^{(j)}) +{\varvec{u}}_{\mathrm{hydro}}^{(j)}({\varvec{x}}^{(i)}-{\varvec{x}}^{(j)})\right] . \end{aligned}
(1)

Our simulations have N swimmers, with N ranging from 500 to 8000, with different values of N used for each channel size a. Bacteria are initially distributed uniformly in the channel and their position is then integrated explicitly from Eq. (1) using the dimensionless time step $${\mathrm {d}}t = 0.5$$. Swimmers are confined laterally in the channel by ensuring that, after each time step, they remain inside the walls along $$y_+$$ and $$y_-$$, i.e. $$-a/2< y^{(i)} < a/2$$. Note that in practice this constraints is rarely invoked in our simulations because hydrodynamic interactions between swimmers in the (x-z) plane are attractive and thus quickly lead to clustering within the channel. In the simulations, we take the bacteria to have identical swimming speed and therefore identical effect on the surrounding fluid. To account for the heterogeneity of the population, simulations were also carried out with bacteria velocities normally distributed around $$u_0$$ with standard deviation $$u_0/3$$ and we obtained the same plume patterns and dynamics.

The dynamics of the convective cells in the numerical model is illustrated in Fig. 4. Similar to the experimental observations, the randomly distributed bacteria (Fig. 4a) first swim in the $$-z$$ direction and accumulate at the wall (Fig. 4b). Neighbouring wall-bound bacteria experience attractive interactions and start clustering. The origin of this attraction lies in the hydrodynamic interactions between the bacteria and the wall. When a swimmer is located at the no-slip wall, the point force closer to the surface nearly cancels with its image, leaving only a stokeslet pushing the surrounding fluid away from the wall22. In other words, a bacterium stuck near a surface imposes a net force away from the wall on the surrounding fluid. Due to mass conservation, the flow created by this force induces a secondary attractive flow along the wall and directed toward the swimmer. Attractive interactions disturb the uniform distribution of wall-bound swimmers and lead to clustering. Attractive interactions between point forces located near a surface have been described in the past in both physics46 and biology22, including for MTB31. Similar hydrodynamic clustering has also been observed for Thiovulum majus (T. majus), a larger almost-spherical bacterium, swimming near walls23. While the mechanism for the initial attraction to the surface is the same, the evolution of the two systems differ significantly. The back-flow generated by the MTB in our experiments is strong enough to detach some of the swimmers and advect them away from the surface. Additionally, the T. majus bacteria in Ref.23 remain bound to the surfaces, possibly due to stronger interaction with the surfaces or because of their spherical shape, and form two-dimensional rotating crystals. In contrast, for both our experiments and model, detached MTB cells form plumes (Fig. 4c) which in turn generate stronger attractive flows, resulting in plume-plume attraction and merging. Finally, the increasing number of swimmers within each plume leads to the formation of elongated vertical plumes. This instability is predicted to occur at any bacterium concentration, as any two swimmers at the wall will experience attraction. Besides, cell detachment from the wall can occur for clusters of as little as three swimmers, which means that in our model, we predict no critical concentration for the instability. However, for very dilute systems, the timescale for plume formation becomes very long, and exceeds the time of our observations. The time-sequence from initial swimmer distribution to final plumes is illustrated in Fig. 4d with time-lapse representation of the swimmers position within the $$x-y$$ plane perpendicular to the plumes. Ultimately, a steady flow state is reached when plumes are separated by a length scale similar to the channel height, creating flows with convection cells similar to experimental observations (Fig. 3b). Note that, beyond the final state, we find a good qualitative agreement between the flow structures created by the plumes in our experiments and in the numerical model, as further detailed in the Supplementary Material.

To further compare the experimental data with the model, we study the dynamics of the plume wavelength, $$\lambda$$. In order to compute the wavelength, a histogram of the bacteria positions is obtained for each time point in the simulation. For consistency with experimental data analysis, plumes are identified where a peak is greater than 1/5 of the highest peak. Similarly to experiments, simulations reveal a sharp change in wavelength evolution, corresponding to a transition from accelerating growth to a plateau in the wavelength. Rescaling the wavelength leads to collapse of the numerical results for various concentrations and system sizes in excellent agreement with the experimental data (Fig. 2). In particular, the late-time wavelength scales with the size of the channels in both cases (we obtain $$\lambda _p \sim a$$ in the experiments and $$\lambda _p\sim 1.4a$$ for the simulations). Our simulations support an intuitive physical explanation for the existence of a plateau value wherein the transition occurs when plumes interact with their hydrodynamic images on the opposing wall, which limits the range of the flow created by all swimmers in a plume and thereby plume growth. The confinement thus sets the limit for the accelerating merging of the plumes. To validate this hypothesis, we carried out simulations without an upper wall (i.e. unconfined) and obtain, for sufficiently large concentrations, uninterrupted growth until only a single plume emerges (see Supplementary Material). We note that the presence of walls parallel to the magnetic field, $$y_-$$ and $$y_+$$, is neglected in simulations and would further slow the growth of the biggest plumes due to additional flow confinement.

Focusing on wavelength dynamics before reaching the plateau regime, $$\lambda (t)$$, we observe some scatter in the curves of Fig. 2 for both experiments and in our model, showing that the precise wavelength growth dynamics vary with the channel size a and the cell concentration (see Supplementary Material). This shows that the time to reach the plateau $$\tau _p$$ does not fully govern the early dynamics of the system. Indeed, we identify two regimes in the simulations, one of accelerating growth and one of approximately constant growth. Their relative duration sets the shape of the $$\lambda (t)$$ curves in Fig. 2. In the first one, some bacteria have not yet reached the $$z_-$$ region of the channel as the first plumes start forming. The duration of this first regime can be estimated by computing the average of the lowest z value previously reached by each bacterium, and we see that it is higher than for free swimming bacteria due to repulsive hydrodynamic interactions in the z direction. Increasing swimmers concentration in the $$z_-$$ region accelerates plume growth (see Fig. 5), and this first regime coincides with an increasing rate of growth of the wavelength, as further detailed in the Supplementary Material.

At later times, all bacteria are in the $$z_-$$ region of the channel. If the flow created by a plume was the sum of all flows generated by individual bacteria at the wall, then $$\lambda \propto t^{1/2}$$, due to localised hydrodynamic forcing (Stokeslets) near surfaces interacting as $$r^{-2}$$, which matches neither the experiments nor the simulations. However, when in a plume, swimmers are advected away from the wall and their contribution to the flow is modified and decays more slowly. Because of this, the flow created by a plume does not scale linearly with the number of swimmers in the plume, which leads to more complex dynamics without a single scaling law. Plume-plume interactions depend on the position of individual swimmers relative to the wall and hence on the density profile of plumes. We find that plumes are systematically denser near the wall, with some bacteria sticking on it (see Supplementary Material). Integrating the inverse of the flow velocity in the x direction from simulations of a single stratified plume yields an approximation for the merging time of two plumes, given their initial separation $$x_0$$. Due to mass conservation, for a given system where plumes gradually merge, $$x_0$$ scales with the number of swimmers in a plume, $$N_p$$. We intuitively expect the merging time for two plumes to be linear with $$N_p$$, and this is observed for sufficiently large swimmer concentrations, corresponding to the concentrations used in our simulations to match experimental observations. In contrast, lower concentrations lead to longer merging times for the plumes and therefore smaller plumes, as observed both in experiments and simulations. In the regime where the bacteria have reached the $$z_-$$ part of the channel, the wavelength varies linearly with time. This linear scaling is confirmed by simulations where all bacteria were initially positioned on the $$z_-$$ surface. In that case, the wavelength depends linearly on time from the beginning of the simulation (see Supplementary Material). The time scale of the dynamics $$\tau _p$$ is therefore larger than the time for a single bacterium to swim to the wall but smaller than the time for bacteria at the wall to attract each other on distance comparable to the cross section a. To quantify the influence of the concentration on plume growth in our model, we estimate a characteristic time scale, $$\tau _\lambda$$, for wavelength growth obtained from a quadratic fit of the wavelength $$\lambda (t)$$, with results shown in Fig. 5. We see that $$\tau _\lambda$$ scales as the inverse of the concentration, which shows that the dynamics of the system are governed by the plume-plume merging time scaling as $$N_p$$, as described above. Overall, the nonlinear shape of the wavelength dependence on time can thus be explained by the time it takes for swimmers to reach the plumes region and the advection of bacteria away from their hydrodynamic images, which tends to increase their contribution to the flow and thus the attractive interactions between plumes.

In summary, we have identified experimentally a new type of collective motion, bacterial magneto-convection. MTB driven by an external magnetic field start by accumulating at the surface of a microfluidic channel. The initial random distribution of bacteria is unstable due to hydrodynamic attraction between swimmers, which cluster and form dynamic plumes. The resulting self-sustained flow resembles convection cells, with a late-time characteristic size linearly dependent on the confinement length scale, with the crucial difference that here no external forces are applied to the system, only external torques aligning the cells with the external field. A model based on hydrodynamic singularities and their images describes interactions between bacteria and with channel walls and successfully reproduces the growth and long-time dynamics of the interacting plumes. We expect this model to be useful in understanding other observed collective motions of magnetotactic bacteria as well as any confined swimmers oriented by external fields, leading to a better understanding of the respective role of swimmer-swimmer interaction and external cues. Since bacterial magneto-convection represents a new class of collective behaviour resulting only from the balance between hydrodynamic interactions and external alignment, it helps elucidate the synergy between particle-particle interactions and external cues and can be compared to other systems of biased biological or artificial swimmers to shed a light on their own collective dynamics.

## Methods

Bacteria are grown in a liquid medium with controlled nutrients and O$$_2$$ conditions, following Ref.47. To ensure that most of the bacterium population remains magnetotactic and motile, we use a racetrack selection method39, keeping only bacteria that swim through a filter while guided by an external magnetic field. This also selects bacteria with a preferred polarity. Before the experiments reported in the present study, we measured the magnetic moment of bacteria grown in the same conditions and obtained $$\mu =10^{-15}\pm 4\times 10^{-16} {\mathrm{A\,m}^2}$$ (mean ± standard deviation)48. High concentrations of motile bacteria are then obtained by centrifugation ($$1.5 {\mathrm{ml}}$$, $$2000\, {\mathrm{rcf}}$$, $$2\,\mathrm{min}$$) and subsequent re-dispersion in approximately 10% of the supernatant. After this procedure, a majority of the obtained bacteria are motile and magnetic, however the solution also contains non motile and dead bacteria. We fill the glass capillaries (Vitrotubes, VitroCom, New Jersey, USA) by capillarity with a drop of the concentrated suspension. Both sides of the capillary are then sealed by placing them on a support with two cells filled with mineral oil, to avoid evaporation.

Two Helmholtz coils are mounted on the platform of a microscope (Nikon eclipse E200) to generate a uniform magnetic field normal to the capillary tube. We verify that the magnetic field was indeed uniform on the whole length of the capillary and calibrated the set up to obtain fields ranging from $$1 \times 10^{-4} \,{\mathrm{T}}$$ to $$20 \times 10^{-4}\, {\mathrm{T}}$$. Images are then acquired with a CCD camera (Allied Vision Technology GE680) at $$10\,{\mathrm{fps}}$$. The images are then analysed through PIV49, using bacteria as tracers. While motile magnetic bacteria accumulate at the surface of the capillary and in the plumes, the presence of non-motile bacteria enables us to observe the flow field in the capillary throughout the experiments, and obtain streamlines in the channel.

## Data availability

The data that support the findings of this study as well as the Matlab code (for image analysis and simulations) are available from the corresponding author upon reasonable request.

## References

1. Vicsek, T. & Zafeiris, A. Collective motion. Phys. Rep.517, 71–140. https://doi.org/10.1016/j.physrep.2012.03.004 (2012).

2. Sumpter, D. J. The principles of collective animal behaviour. Philos. Trans. R. Soc. B Biol. Sci. https://doi.org/10.1098/rstb.2005.1733 (2005).

3. Mora, T. et al. Local equilibrium in bird flocks. Nat. Phys.12, 1153. https://doi.org/10.1038/nphys3846 (2016).

4. Lopez, U., Gautrais, J., Couzin, I. D. & Theraulaz, G. From behavioural analyses to models of collective motion in fish schools. Interface Focus2, 693–707. https://doi.org/10.1098/rsfs.2012.0033 (2012).

5. Trepat, X. et al. Physical forces during collective cell migration. Nat. Phys.5, 426. https://doi.org/10.1038/nphys1269 (2009).

6. Lauga, E. & Powers, T. R. The hydrodynamics of swimming microorganisms. Rep. Prog. Phys.72, 096601. https://doi.org/10.1088/0034-4885/72/9/096601 (2009).

7. Cisneros, L. H., Cortez, R., Dombrowski, C., Goldstein, R. E. & Kessler, J. O. Fluid dynamics of self-propelled micro-organisms, from individuals to concentrated populations. Exp. Fluids43, 737–753. https://doi.org/10.1007/s00348-007-0387-y (2007).

8. Koch, D. L. & Subramanian, G. Collective hydrodynamics of swimming microorganisms: living fluids. Annu. Rev. Fluid Mech.43, 637–659. https://doi.org/10.1146/annurev-fluid-121108-145434 (2011).

9. Sokolov, A., Aranson, I. S., Kessler, J. O. & Goldstein, R. E. Concentration dependence of the collective dynamics of swimming bacteria. Phys. Rev. Lett.98, 158102. https://doi.org/10.1103/physrevlett.98.158102 (2007).

10. Riedel, I. H., Kruse, K. & Howard, J. A self-organized vortex array of hydrodynamically entrained sperm cells. Science309, 300–303. https://doi.org/10.1016/j.physrep.2012.03.0040 (2005).

11. Keller, E. F. & Segel, L. A. Model for chemotaxis. J. Theor. Biol.30, 225–234. https://doi.org/10.1016/j.physrep.2012.03.0041 (1971).

12. Witman, G. B. Chlamydomonas phototaxis. Trends Cell Biol.3, 403–408. https://doi.org/10.1016/j.physrep.2012.03.0042 (1993).

13. Kessler, J. O. Hydrodynamic focusing of motile algal cells. Nature313, 218. https://doi.org/10.1016/j.physrep.2012.03.0043 (1985).

14. Pedley, T. & Kessler, J. Hydrodynamic phenomena in suspensions of swimming microorganisms. Annu. Rev. Fluid Mech.24, 313–358. https://doi.org/10.1016/j.physrep.2012.03.0044 (1992).

15. Vincent, R. & Hill, N. Bioconvection in a suspension of phototactic algae. J. Fluid Mech.327, 343–371. https://doi.org/10.1016/j.physrep.2012.03.0045 (1996).

16. Childress, S., Levandowsky, M. & Spiegel, E. A. Pattern formation in a suspension of swimming microorganisms: equations and stability theory. J. Fluid Mech.69, 591–613. https://doi.org/10.1016/j.physrep.2012.03.0046 (1975).

17. Hill, N. & Pedley, T. Bioconvection. Fluid Dyn. Res.37, 1–20. https://doi.org/10.1016/j.physrep.2012.03.0047 (2005).

18. Mogami, Y., Yamane, A., Gino, A. & Baba, S. A. Bioconvective pattern formation of tetrahymena under altered gravity. J. Exp. Biol.207, 3349–3359. https://doi.org/10.1016/j.physrep.2012.03.0048 (2004).

19. Wioland, H., Lushi, E. & Goldstein, R. E. Directed collective motion of bacteria under channel confinement. New J. Phys.18, 075002. https://doi.org/10.1016/j.physrep.2012.03.0049 (2016).

20. Lushi, E., Wioland, H. & Goldstein, R. E. Fluid flows created by swimming bacteria drive self-organization in confined suspensions. Proc. Natl. Acad. Sci. https://doi.org/10.1073/pnas.1405698111 (2014).

21. Drescher, K., Dunkel, J., Cisneros, L. H., Ganguly, S. & Goldstein, R. E. Fluid dynamics and noise in bacterial cell-cell and cell-surface scattering. Proc. Natl. Acad. Sci.108, 10940–10945. https://doi.org/10.1073/pnas.1019079108 (2011).

22. Drescher, K. et al. Dancing volvox: hydrodynamic bound states of swimming algae. Phys. Rev. Lett.102, 168101. https://doi.org/10.1103/physrevlett.102.168101 (2009).

23. Petroff, A. P., Wu, X.-L. & Libchaber, A. Fast-moving bacteria self-organize into active two-dimensional crystals of rotating cells. Phys. Rev. Lett.114, 158102. https://doi.org/10.1103/physrevlett.114.158102 (2015).

24. Klumpp, S., Lefèvre, C. T., Bennet, M. & Faivre, D. Swimming with magnets: from biological organisms to synthetic devices. Phys. Rep.789, 1–54. https://doi.org/10.1016/j.physrep.2018.10.007 (2019).

25. Uebe, R. & Schüler, D. Magnetosome biogenesis in magnetotactic bacteria. Nat. Rev. Microbiol.14, 621. https://doi.org/10.1038/nrmicro.2016.99 (2016).

26. Bazylinski, D. A. & Trubitsyn, D. Magnetotactic bacteria and magnetosomes. In Magnetic Nanoparticles in Biosensing and Medicine (eds Darton, N. J. et al.) 251–284 (Cambridge University Press, Cambridge, 2019). https://doi.org/10.1017/9781139381222.009.

27. Blakemore, R. P. Magnetotactic bacteria. Annu. Rev. Microbiol.36, 217–238. https://doi.org/10.1146/annurev.mi.36.100182.001245 (1982).

28. Lefevre, C. T., Song, T., Yonnet, J.-P. & Wu, L.-F. Characterization of bacterial magnetotactic behaviors by using a magnetospectrophotometry assay. Appl. Environ. Microbiol.75, 3835–3841. https://doi.org/10.1128/aem.00165-09 (2009).

29. Alphandéry, E. Applications of magnetosomes synthesized by magnetotactic bacteria in medicine. Front. Bioeng. Biotechnol.2, 5. https://doi.org/10.3389/fbioe.2014.00005 (2014).

30. Felfoul, O. et al. Magneto-aerotactic bacteria deliver drug-containing nanoliposomes to tumour hypoxic regions. Nat. Nanotechnol.11, 941. https://doi.org/10.1038/nnano.2016.137 (2016).

31. Pierce, C. et al. Tuning bacterial hydrodynamics with magnetic fields. Phys. Rev. E95, 062612 (2017).

32. Pierce, C. et al. Hydrodynamic interactions, hidden order, and emergent collective behavior in an active bacterial suspension. Phys. Rev. Lett.121, 188001. https://doi.org/10.1103/physreve.95.062612 (2018).

33. Belovs, M., Livanovics, R. & Cēbers, A. Synchronized rotation in swarms of magnetotactic bacteria. Phys. Rev. E96, 042408. https://doi.org/10.1103/physreve.96.042408 (2017).

34. Waisbord, N., Lefèvre, C. T., Bocquet, L., Ybert, C. & Cottin-Bizonne, C. Destabilization of a flow focused suspension of magnetotactic bacteria. Phys. Rev. Fluids1, 053203. https://doi.org/10.1103/physrevfluids.1.053203 (2016).

35. Meng, F., Matsunaga, D. & Golestanian, R. Clustering of magnetic swimmers in a poiseuille flow. Phys. Rev. Lett.120, 188101. https://doi.org/10.1103/physrevlett.120.188101 (2018).

36. Vincenti, B. et al. Magnetotactic bacteria in a droplet self-assemble into a rotary motor. Nat. Commun.10, 1–8. https://doi.org/10.1017/9781139381222.0090 (2019).

37. Normand, C., Pomeau, Y. & Velarde, M. G. Convective instability: a physicists approach. Rev. Mod. Phys.49, 581. https://doi.org/10.1103/RevModPhys.49.581 (1977).

38. Matsunaga, T., Sakaguchi, T. & Tadakoro, F. Magnetite formation by a magnetic bacterium capable of growing aerobically. Appl. Microbiol. Biotechnol.35, 651–655. https://doi.org/10.1007/bf00169632 (1991).

39. Wolfe, R., Thauer, R. & Pfennig, N. A capillary racetrack method for isolation of magnetotactic bacteria. FEMS Microbiol. Lett.3, 31–35. https://doi.org/10.1111/j.1574-6968.1987.tb02335.x (1987).

40. Murat, D. et al. Opposite and coordinated rotation of amphitrichous flagella governs oriented swimming and reversals in a magnetotactic spirillum. J. Bacteriol.197, 3275–3282. https://doi.org/10.1128/jb.00172-15 (2015).

41. Cortez, R. The method of regularized stokeslets. SIAM J. Sci. Comput.23, 1204–1225. https://doi.org/10.1137/s106482750038146x (2001).

42. Drescher, K., Goldstein, R. E., Michel, N., Polin, M. & Tuval, I. Direct measurement of the flow field around swimming microorganisms. Phys. Rev. Lett.105, 168101. https://doi.org/10.1103/PhysRevLett.105.168101 (2010).

43. Costanzo, A., Di Leonardo, R., Ruocco, G. & Angelani, L. Transport of self-propelling bacteria in micro-channel flow. J. Phys. Condens. Matter24, 065101. https://doi.org/10.1088/0953-8984/24/6/065101 (2012).

44. Ainley, J., Durkin, S., Embid, R., Boindala, P. & Cortez, R. The method of images for regularized stokeslets. J. Comput. Phys.227, 4600–4616. https://doi.org/10.1016/j.jcp.2008.01.032 (2008).

45. Blake, J. A note on the image system for a stokeslet in a no-slip boundary. Math. Proc. Cambr. Philos. Soc.70, 303–310. https://doi.org/10.1017/s0305004100049902 (1971).

46. Squires, T. M. & Brenner, M. P. Like-charge attraction and hydrodynamic interaction. Phys. Rev. Lett.85, 4976. https://doi.org/10.1103/physrevlett.85.4976 (2000).

47. Le Nagard, L., Morillo-López, V., Fradin, C. & Bazylinski, D. A. Growing magnetotactic bacteria of the genus magnetospirillum: strains msr-1, amb-1 and ms-1. J. Vis. Exper. https://doi.org/10.3791/58536 (2018).

48. Le Nagard, L. et al. Misalignment between the magnetic dipole moment and the cell axis in the magnetotactic bacterium magnetospirillum magneticum amb-1. Phys. Biol.16, 066008. https://doi.org/10.1088/1478-3975/ab2858 (2019).

49. Thielicke, W. & Stamhuis, E. J. Pivlab-towards user-friendly, affordable and accurate digital particle image velocimetry in matlab. J. Open Res. Softw. https://doi.org/10.5334/jors.bl (2014).

## Acknowledgements

This work was funded by the European Research Council (ERC) under the EU’s Horizon 2020 research and innovation program (Grant Agreement No. 682754 to EL) and the Natural Science and Engineering Research Council of Canada. The Joliot Chair of the ESPCI Paris is gratefully acknowledged. We also thank Dennis Bazylinski and Adam Hitchcock for fruitful discussions.

## Author information

Authors

### Contributions

A.T., L.L.N. and J.-C.O.B. carried out the experiments under the direction of K.D.V. and C.F.. A.T. and E.L. developed the theoretical model and the simulations. All authors contributed to the writing of the manuscript and reviewed it.

### Corresponding author

Correspondence to Eric Lauga.

## Ethics declarations

### Competing interests

The authors declare no competing interests.

### Publisher's note

Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.

## Rights and permissions

Reprints and Permissions

Théry, A., Le Nagard, L., Ono-dit-Biot, JC. et al. Self-organisation and convection of confined magnetotactic bacteria. Sci Rep 10, 13578 (2020). https://doi.org/10.1038/s41598-020-70270-0

• Accepted:

• Published:

• DOI: https://doi.org/10.1038/s41598-020-70270-0