Article | Open | Published:

# Oxic-anoxic regime shifts mediated by feedbacks between biogeochemical processes and microbial community dynamics

## Abstract

Although regime shifts are known from various ecosystems, the involvement of microbial communities is poorly understood. Here we show that gradual environmental changes induced by, for example, eutrophication or global warming can induce major oxic-anoxic regime shifts. We first investigate a mathematical model describing interactions between microbial communities and biogeochemical oxidation-reduction reactions. In response to gradual changes in oxygen influx, this model abruptly transitions between an oxic state dominated by cyanobacteria and an anoxic state with sulfate-reducing bacteria and phototrophic sulfur bacteria. The model predictions are consistent with observations from a seasonally stratified lake, which shows hysteresis in the transition between oxic and anoxic states with similar changes in microbial community composition. Our results suggest that hysteresis loops and tipping points are a common feature of oxic-anoxic transitions, causing rapid drops in oxygen levels that are not easily reversed, at scales ranging from small ponds to global oceanic anoxic events.

## Introduction

Ecosystems may undergo sharp transitions in response to smooth environmental changes1,2,3,4. If these transitions lead to large and persistent changes in ecosystem structure and functioning, they are generally referred to as regime shifts. Regime shifts are often attributed to alternative stable states (where distinct ecological states exist under the same external conditions1, 2) and have been documented in a wide range of terrestrial, freshwater, and marine habitats3, 4. Theoretical work has contributed to understanding ecological regime shifts3 and has identified early warning signs that a regime shift may be imminent4. However, so far the potential involvement of microbial communities in regime shifts has been largely ignored, despite the fact that microbial communities make a significant contribution to many ecological and biogeochemical processes5, 6.

A small number of studies suggest that regime shifts may occur in microbial communities. Recent work has pointed at the existence of alternative stable states in the microbial community of the human gut7, 8 and in phytoplankton populations sensitive to high light9, 10. Other studies have shown a regime shift from iron reduction to sulfate reduction in an iron-rich groundwater flow11 and compositional regime shifts in a nitrifying batch reactor12. However these examples are few, and furthermore, unlike in traditional macro-ecology, there is little theoretical work on regime shifts in microbial ecosystems13, 14.

Microorganisms play an important role in the biogeochemical cycles of lakes and oceans. Many waters in temperate climates become vertically stratified in summer, when the sun heats up the surface layer while the temperature in the deeper layers remains low. Seasonal stratification induces changes in microbial community structure15,16,17. The surface layer (epilimnion) is usually rich in oxygen and often dominated by oxygenic phototrophic microorganisms such as cyanobacteria and eukaryotic algae. Especially in productive waters, microbial degradation of organic matter can create anoxic conditions in the deeper layers (hypolimnion), which may shift the microbial community to heterotrophic bacteria utilizing nitrate or sulfate as an electron acceptor. In between these layers, in the metalimnion, oxygen diffusing down from the epilimnion meets sulfide diffusing up from the hypolimnion, providing a niche for photosynthetic and non-photosynthetic sulfur-oxidizing bacteria18, 19. Because of surface cooling and wind action, the stratification is broken in the fall when different water layers are mixed, homogenizing the oxygen and temperature profiles.

In this paper, we combine a mathematical model and lake data, to show that regime shifts in microbial community structure may be common in seasonally stratified waters with an active microbial sulfur cycle. We first present a simple mathematical model of a microbial ecosystem containing cyanobacteria, sulfate-reducing bacteria and phototrophic sulfur bacteria. We show that this model can undergo regime shifts between oxic and anoxic states in response to gradual parameter variations that mimic changes in vertical stratification and hence oxygen diffusivity across the thermocline. Subsequently, we compare the model predictions with data from a seasonally stratified lake with an anoxic hypolimnion during summer, and discuss the wider implications of oxic-anoxic regime shifts for other ecosystems.

## Results

### Bringing microbial dynamics into a biogeochemical model

We consider a simple model that integrates microbial community dynamics with biogeochemical processes. The microbial community consists of three functional groups: oxygen-producing cyanobacteria (CB), phototrophic sulfur bacteria (PB) such as purple or green sulfur bacteria, and sulfate-reducing bacteria (SB) (Fig. 1). Growth of each microbial population is assumed to depend on the availability of phosphorus (P), a key limiting resource for many aquatic ecosystems20. Furthermore, the growth of phototrophic sulfur bacteria depends on sulfide (SR, representing reduced sulfur), whereas that of sulfate-reducing bacteria depends on sulfate (SO, representing oxidized sulfur). Sulfide produced by sulfate-reducing bacteria inhibits the growth of cyanobacteria21. Conversely, oxygen (O) produced by cyanobacteria is assumed to be inhibitory to both sulfate-reducing bacteria22 and phototrophic sulfur bacteria23.

Hence, changes in the population densities of cyanobacteria (N CB), phototrophic sulfur bacteria (N PB) and sulfate-reducing bacteria (N SB) can be described as:

$${\frac{{{\rm{d}}{N_{{\rm{CB}}}}}}{{{\rm{d}}t}} = {g_{{\rm{CB}}}}\left( P \right)\;{h_{{\rm{CB}}}}\left( {{S_{\rm{R}}}} \right){N_{{\rm{CB}}}} - {m_{{\rm{CB}}}}{N_{{\rm{CB}}}}}$$
(1)
$${\frac{{{\rm{d}}{N_{{\rm{PB}}}}}}{{{\rm{d}}t}} = {g_{{\rm{PB}}}}\left( {P,{S_{\rm{R}}}} \right)\;{h_{{\rm{PB}}}}\left( O \right){N_{{\rm{PB}}}} - {m_{{\rm{PB}}}}{N_{{\rm{PB}}}}}$$
(2)
$${\frac{{{\rm{d}}{N_{{\rm{SB}}}}}}{{{\rm{d}}t}} = {g_{{\rm{SB}}}}\left( {P,{S_{\rm{O}}}} \right){h_{{\rm{SB}}}}\left( O \right){N_{{\rm{SB}}}} - {m_{{\rm{SB}}}}{N_{{\rm{SB}}}}}$$
(3)

where the functions g j (X,Y) and h j (X) describe growth and inhibition, respectively, of microbe j on substrates X and Y, and m j is the mortality rate of microbe j (e.g., due to grazing or viral lysis). The growth and inhibition functions are detailed in the Methods section.

Reduced sulfur is oxidized by phototrophic sulfur bacteria, whereas oxidized sulfur is reduced by sulfate-reducing bacteria, connecting these species in a biogeochemical cycle as they pass the sulfur back and forth (Fig. 1). In addition, oxidation of reduced sulfur can be mediated by chemolithotrophic sulfur-oxidizing bacteria and may also occur abiotically24, which we have modeled here as a simple first-order process. Furthermore, we assume a small diffusive flux of oxidized and reduced sulfur into or out of the system, depending on their concentration gradients and a substrate-specific diffusivity α S. Accordingly, changes in the oxidized and reduced sulfur concentrations can be described as:

$${\frac{{{\rm{d}}{S_{\rm{O}}}}}{{{\rm{d}}t}} = \frac{{\rm{1}}}{{y_{{\rm{PB}}}^{{S}}}}{g_{{\rm{PB}}}}\left( {P,{S_{\rm{R}}}} \right) \; {h_{{\rm{PB}}}}\left( O \right){N_{{\rm{PB}}}}} \hskip-8.5pc\\ {- \;\frac{{\rm{1}}}{{y_{{\rm{SB}}}^{{S}}}}{g_{{\rm{SB}}}}\left( {P,{S_{\rm{O}}}} \right)\;{h_{{\rm{SB}}}}\left( O \right){N_{{\rm{SB}}}}} \\ {+ cO{S_{\rm{R}}} + {\alpha _{\rm{S}}}\left( {{S_{{\rm{O,b}}}} - {S_{\rm{O}}}} \right)}$$
(4)
$${\frac{{{\rm{d}}{S_{\rm{R}}}}}{{{\rm{d}}t}} = - \;\frac{{\rm{1}}}{{y_{{\rm{PB}}}^{{S}}}}{g_{{\rm{PB}}}}\left( {P,{S_R}} \right)\;{h_{{\rm{PB}}}}\left( O \right){N_{{\rm{PB}}}}} \hskip-9.6pc\\ + {\frac{{\rm{1}}}{{y_{{\rm{SB}}}^{{S}}}}{g_{{\rm{SB}}}}\left( {P,{S_{\rm{O}}}} \right)\;{h_{{\rm{SB}}}}\left( O \right){N_{{\rm{SB}}}}} \\ - {cO{S_{\rm{R}}} + {\alpha _{\rm{S}}}\left( {{S_{R,b}} - {S_{\rm{R}}}} \right)}$$
(5)

where y j k is the yield (in cells per μmole of substrate) of microbe j on substrate k, c is the oxidation rate of reduced sulfur, and S O,b and S R,b are the background concentrations of oxidized and reduced sulfur, respectively.

Oxygen is produced by cyanobacteria, reacts with reduced sulfur, and diffuses into or out of the system depending on the concentration gradient. Finally, phosphorus is consumed by all three microbial groups, and also has a diffusive flux across the system boundary. Hence, the oxygen and phosphorus dynamics can be written as:

$${\frac{{{\rm{d}}O}}{{{\rm{d}}t}} = {p_{{\rm{CB}}}}{g_{{\rm{CB}}}}\left( P \right)\;{h_{{\rm{CB}}}}\left( {{S_{\rm{R}}}} \right){N_{{\rm{CB}}}} - cO{S_{\rm{R}}} + {\alpha _{\rm{O}}}\left( {{O_{\rm{b}}} - O} \right)}$$
(6)
$${\frac{{{\rm{d}}P}}{{{\rm{d}}t}} = - \frac{{\rm{1}}}{{y_{{\rm{CB}}}^{{P}}}}{g_{{\rm{CB}}}}\left( P \right){h_{{\rm{CB}}}}\left( {{S_{\rm{R}}}} \right){N_{{\rm{CB}}}} } \hskip-8.5pc\\ -{ \frac{{\rm{1}}}{{y_{{\rm{PB}}}^{{P}}}}{g_{{\rm{PB}}}}\left( {P,{S_{\rm{R}}}} \right){h_{{\rm{PB}}}}\left( O \right){N_{{\rm{PB}}}} } \\ -{ \frac{{\rm{1}}}{{y_{{\rm{SB}}}^{{P}}}}{g_{{\rm{SB}}}}\left( {P,{S_{\rm{O}}}} \right){h_{{\rm{SB}}}}\left( O \right){N_{{\rm{SB}}}}\, + \,{\alpha _{\rm{P}}}\left( {{P_{\rm{b}}} - P} \right)}$$
(7)

where p CB is the oxygen production per cyanobacterial cell. Parameter values were based on microbial communities of freshwater lakes, where available (Supplementary Table 1). We note, however, that the model results are quite robust, since we obtained qualitatively similar results when using parameter values representative of marine environments25 or microbial mats26.

### Oxic-anoxic regime shifts

Ecological regime shifts can be identified by certain behaviors3, 13. First, models with regime shifts often contain alternative stable states, such that they may develop in different directions depending on the initial conditions. Second, environmental changes can cause ecosystems containing alternative stable states to become stuck in an ecosystem state, such that simply reversing the environmental change is not sufficient to return the ecosystem to its original state: a phenomenon known as hysteresis. For example, overfishing can cause collapses in coral reef structure that cannot be recovered simply by returning to earlier, lower fishing rates27. Here, we demonstrate that our model displays these two characteristic signs of regime shifts by investigating its response to parameter changes designed to mimic seasonal variation in lake stratification.

First, we investigate the sensitivity of the model to the initial composition of the microbial community. Figure 2 compares how the ecosystem develops over time for different initial bacterial population densities. The results show that the model is sensitive to the initial community composition, demonstrating the existence of alternative stable states. If sulfate-reducing and phototrophic sulfur bacteria are initially dominant, the oxygen concentration remains low, the concentration of reduced sulfur becomes sufficiently high to suppress cyanobacterial growth, and the system develops an anoxic state (Fig. 2a, b). Conversely, if cyanobacteria are dominant first, their photosynthetic oxygen production is sufficiently high to suppress the growth of sulfate-reducing bacteria and phototrophic sulfur bacteria, generating an oxic state (Fig. 2c, d).

Second, to determine whether the model displays hysteresis, we investigate how it responds to changes in oxygen influx. We vary the parameter αO as a proxy for the turbulent diffusion of oxygen across the thermocline of a seasonally stratified lake. A low value of the oxygen diffusivity αO represents the case where stratification restricts turbulent diffusion of oxygen across the thermocline, and a high value of oxygen diffusivity represents the case where the lake is completely mixed and oxygenated. The results confirm the existence of two alternative stable states for a wide range of oxygen diffusivities: one with a stable cyanobacterial population at steady state (blue line) and another where the cyanobacterial population has collapsed (red line) (Fig. 3a). Towards which of these two states the system develops depends on whether the initial population density of cyanobacteria is above or below the separatrix (orange dashed line).

The two alternative stable states are also visible in the steady-state concentration of dissolved oxygen: the ecosystem becomes either oxic or anoxic (Fig. 3b). Starting from the anoxic state, the ecosystem undergoes a regime shift when the oxygen diffusivity increases to high levels. That is, at the tipping point T 1 it abruptly transitions from the anoxic to the oxic state. Conversely, once the ecosystem is oxic, it remains oxic when the oxygen diffusivity decreases, and flips back to the anoxic state only when oxygen diffusivity has become very low at tipping point T 2. Hence, the system displays hysteresis (as indicated by black arrows in Fig. 3b). The underlying mechanism for the existence of this hysteresis loop is that the microbial community composition differs between the oxic and anoxic states. The anoxic state is characterized by dense populations of phototrophic sulfur bacteria and sulfate-reducing bacteria and high sulfide concentrations, which prevent cyanobacterial invasion over a wide range of oxygen diffusivities. Only when the oxygen influx becomes high enough to suppress the phototrophic sulfur and sulfate-reducing bacteria, can the cyanobacteria invade. Conversely, the oxic state is dominated by cyanobacteria whose photosynthetic oxygen production contributes to the persistence of the oxic state, thereby suppressing invasion of the anaerobic sulfur bacteria. Thus, only at a very low oxygen diffusivity can the anaerobic sulfur bacteria become established.

The anoxic state of our model can take two different forms depending on the oxygen input. At low oxygen diffusivity, the model predicts coexistence of sulfate-reducing bacteria and phototrophic sulfur bacteria which pass the sulfur back and forth (orange and gray areas in Fig. 4). At intermediate oxygen diffusivity, the anoxic state consists of sulfate-reducing bacteria only (green and pink area). In this case, oxidation of reduced sulfur by sulfur-oxidizing bacteria and direct chemical oxidation diverts reduced sulfur from the phototrophic sulfur bacteria, while resupplying sulfate-reducing bacteria with oxidized sulfur. Hence, sulfate-reducing bacteria obtain a selective advantage, and can displace the phototrophic sulfur bacteria during competition for phosphorus.

Phosphorus enrichment has a profound effect on oxic-anoxic regime shifts. As phosphorus availability increases, the model predicts that the region with alternative stable states spreads out over a larger range of oxygen diffusivities (gray and pink area in Fig. 4). The reason is that, in the oxic state, the population density of cyanobacteria increases with phosphorus enrichment. High cyanobacterial densities can sustain the oxic state by their own photosynthetic oxygen production even when the diffusive oxygen influx into the system becomes very low. Conversely, in the anoxic state, population densities of the anaerobic sulfur bacteria increase with phosphorus enrichment, and hence they can maintain anoxic conditions up to higher oxygen diffusivities. Thus, the region with alternative stable states widens with phosphorus enrichment, suggesting that particularly eutrophic waters will be very sensitive to oxic-anoxic regime shifts.

### Comparison with lake data

Our model is a simplification of reality, in which we have reduced the highly diverse microbial communities and plethora of biogeochemical reactions in aquatic ecosystems to only a few interacting processes (Fig. 1). It is therefore interesting to assess whether we can find signatures for oxic-anoxic regime shifts in lakes that are consistent with the model results.

We investigated microbial community dynamics and water quality parameters in the seasonally stratified Lake Vechten18, 28, a small lake in the Netherlands. In early spring, the lake was well mixed and oxygenated (Fig. 5a, b). Subsequently, a temperature stratification developed, with warm oxygen-saturated waters in the epilimnion whereas the hypolimnion became anoxic during summer. Nitrate concentrations (not shown) were < 1 μM in the hypolimnion, providing favorable conditions for sulfate reduction. Sulfate concentrations were highest in early spring, and decreased to low concentrations in the anoxic hypolimnion (Fig. 5c). Conversely, sulfide accumulated in the anoxic hypolimnion, with highest concentrations in late summer and early fall (Fig. 5d).

Interestingly, when the lake became mixed again in November and December, it did not return to the oxic state but became anoxic throughout (Fig. 5b). Apparently, mixing during fall turnover was insufficient to bring the lake back into the oxic state; a behavior that looks remarkably similar to the hysteresis predicted by our model. To study this pattern in further detail, we first calculated the squared buoyancy frequency, N 2, at the thermocline as a measure of the strength of stratification29, 30. The buoyancy frequency confirms that Lake Vechten is strongly stratified during the summer period, but well mixed during late fall and winter (Fig. 5e). The inverse of the squared buoyancy frequency (1/N 2) provides a simple proxy of the oxygen diffusivity across the thermocline (see Methods). Plotting the dissolved oxygen concentration in the hypolimnion against 1/N 2 reveals a clear hysteresis loop (Fig. 6a), which is remarkably similar to the hysteresis loop predicted by the model (Fig. 3b). That is, intense mixing (high 1/N 2) produced oxic conditions in Lake Vechten during the spring period, whereas the lake was anoxic at the same intensity of mixing during fall turnover. We note that this result is robust, irrespective of the exact depth at which the oxygen concentration is measured (Supplementary Fig. 1).

We used 16S rRNA amplicon sequencing data to assess whether changes in microbial community structure were consistent with the model predictions. Cyanobacteria dominated when the lake was well mixed and oxygenated in winter and early spring (Fig. 5f). Conversely, as the lake became stratified in summer, both sulfate-reducing bacteria and phototrophic sulfur bacteria increased in the anoxic hypolimnion whereas cyanobacteria decreased dramatically. Co-occurrence network analysis of microbial taxa in the metalimnion confirms this pattern: phototrophic sulfur bacteria coexisted with sulfate-reducing bacteria, while both groups were absent when cyanobacteria were present (Fig. 6b). Hence, the microbial community composition alternated between two distinct states, in agreement with the model predictions.

Interestingly, Lake Vechten did not turn anoxic during fall turnover every year28. In several earlier years, the entire water column became fully oxygenated in the fall and the sulfur bacteria disappeared. This matches our model predictions, which indicate that when a stratified lake with an oxic epilimnion and anoxic hypolimnion is mixed it may become either oxic or anoxic depending on the initial conditions (Fig. 2). That is, subtle differences in the mixing of these two water layers may determine whether the system develops towards an oxic or anoxic state. This bistable behavior is a typical feature of systems with alternative stable states.

## Discussion

Our model and lake data show that the interplay between microbial communities and oxidation-reduction processes creates systems with hysteresis loops and tipping points, in which gradual changes in oxygen influx, vertical stratification or nutrient levels can induce abrupt transitions between oxic and anoxic states. Other ecosystems with microbial communities similar to our model may undergo similar oxic-anoxic regime shifts. An interesting example is Lake Rogoznica, a marine lake along the Croatian coast filled with seawater31, 32. Similar to Lake Vechten, this enclosed marine ecosystem is stratified during summer, with an oxic epilimnion containing cyanobacteria and eukaryotic phytoplankton and an anoxic sulfidic hypolimnion dominated by phototrophic sulfur bacteria. In some years, but not all, the entire water column of Lake Rogoznica became anoxic during fall turnover31, in agreement with the bistability predicted by our model. Furthermore, during anoxic holomixis, the phototrophic sulfur bacteria were replaced by sulfur-oxidizing chemotrophs32, supporting one of the other model predictions, i.e., that environmental changes may alter the species composition of the sulfur bacteria in the anoxic state (Fig. 4).

In recent decades, hypoxia has spread across many eutrophied coastal waters33, 34. Prolonged hypoxia may develop into anoxic conditions with high sulfide concentrations, causing mass mortalities of fish and benthic organisms33. These coastal waters often show strong fluctuations in oxygen saturation, triggered by small changes in density stratification or coastal upwelling rates35. It is possible that the coastal waters in these highly dynamic regions are poised between the oxic and anoxic alternative stable states represented in our model. Our model results and field data support earlier suggestions34, 36 that accumulation of sulfide and other reduced compounds and elimination of the aerobic community may produce a hysteresis loop, delaying recovery from coastal hypoxia.

We speculate that similar oxic-anoxic regime shifts may have occurred at a global scale in the Earth’s geological past, when vast areas of the ocean became oxygen-depleted during oceanic anoxic events (OAEs)37. Many OAEs were associated with periods of global warming and high atmospheric CO2 concentrations. High temperatures caused intense continental weathering, enhanced phosphorus discharge into the oceans, lowered oxygen solubility and increased thermohaline stratification suppressing oxygen input into the deeper water layers37, 38. As our results indicate, these changes may trigger a regime shift to anoxic conditions. During OAEs, the oceans developed high sulfide concentrations37, 39 and molecular biomarkers indicate that green sulfur bacteria were common in the photic zone40,41,42. These fascinating findings are all consistent with our model results, suggesting that OAEs are characterized by hysteresis effects and tipping points. If so, environmental changes that push the Earth’s climate beyond a critical tipping point may cause large-scale transitions from oxic to anoxic conditions in the oceans that are not easily reversed.

Our model is only an abstract representation of the real world, providing a highly simplified picture of the complexity of oxic-anoxic transitions. We have specifically focused on microbially-mediated oxidation-reduction reactions in the sulfur cycle. Various other physical, chemical, and biological processes that may also affect whether ecosystems become oxic or anoxic have been conveniently ignored. Furthermore, the species composition of natural communities plays a key role not only in the sulfur cycle but also in several other biogeochemical cycles (e.g., in the nitrogen and carbon cycle), which may again lead to unexpected nonlinear feedback mechanisms. Hence, our findings may provide an interesting starting point for further integration of ecological community dynamics in biogeochemical process studies, and further analysis of its implications.

In conclusion, our model results and field data indicate that the well-known transition from oxic to anoxic conditions in aquatic environments is not a gradual process, but may occur in the form of a regime shift. This regime shift is mediated by nonlinear feedbacks between biogeochemical processes and microbial community dynamics, which can produce hysteresis. Once water becomes anoxic, a large oxygen influx is required before an aerobic community can become re-established, because the anaerobic sulfur cycle has to be overcome. Given the continued eutrophication of many lakes and coastal waters in combination with enhanced stratification by global warming, an improved understanding and prediction of oxic-anoxic regime shifts is essential if we are to mitigate the negative environmental effects of these phenomena.

## Methods

### Growth and inhibition functions

The microbial literature offers several different equations for the growth and inhibition functions g j (X, Y) and h j (X). Here, we have chosen the Monod equation for growth, with multiplicative Monod kinetics when the growth rate is determined by two substrates43:

$${{g_j}\left( {X,Y} \right) = {g_{max,j}}\left( {\frac{X}{{{K_{j,X}} + X}}} \right)\,\left( {\frac{Y}{{{K_{j,Y}} + Y}}} \right)}$$
(8)

where g max,j is the maximum specific growth rate of species j, and K j,X and K j,Y (μM) are the half-saturation constants of species j on substrates X and Y. Inhibition of microbial growth is described by the Haldane equation44, 45:

$${{h_j}\left( X \right) = \frac{{\rm{1}}}{{{\rm{1}} + \left( {X/{H_{j,X}}} \right)}}}$$
(9)

where H j,X can be interpreted as a ‘half-inhibition constant’, i.e., it is the concentration of inhibitory substance X at which the growth rate of species j is reduced by 50%.

### Numerical simulation of the model

Our model comprises 7 ordinary differential equations, each consisting of multiple nonlinear terms. We therefore relied on numerical analysis of the model behavior.

The 1D-bifurcation diagram in Fig. 3 was produced by numerical simulation of the dynamics until steady state, at different values of the oxygen diffusivity. We used a simple continuation approach to track the equilibria of the system, where the steady state of the previous simulation at a given oxygen diffusivity provided the initial conditions for the next simulation at a slightly higher (or slightly lower) oxygen diffusivity. In this way, the equilibrium of the sulfur bacteria was tracked by gradually increasing the oxygen diffusivity until the equilibrium of the sulfur bacteria became unstable (i.e., until the trajectory diverged away from the equilibrium). Likewise, the alternative equilibrium of the cyanobacteria was tracked from the other side, by gradually decreasing the oxygen diffusivity, until the cyanobacterial equilibrium became unstable. This continuation approach was supplemented by additional numerical simulations sampling a broad range of initial conditions to verify the results. Trajectories always converged to a stable point; we did not observe stable periodic orbits or chaotic dynamics.

The 2D-bifurcation diagram in Fig. 4 was produced in a similar way. We first generated 1D-bifurcation diagrams as function of oxygen diffusivity, for a fixed value of the background phosphorus (as in Fig. 3). This was repeated at many different values of the background phosphorus to produce the 2D-bifurcation diagram. In total, the graph in Fig. 4 is based on a grid of 400 × 400 numerical simulations.

All numerical simulations were run twice for consistency using two different methods of numerical integration: the integrate.odeint function from the widely used Python library Scipy, and a custom script in C for integrating systems of ordinary differential equations using the classic fourth order Runge–Kutta Method.

### Study site and sampling

Lake Vechten (52°04′N, 5°05′E) has a maximum depth of 11.9 m, mean depth of 6.0 m and surface area of 4.7 ha28. The lake was sampled at biweekly to monthly intervals at every meter depth (0–10 m) from March 2013 to early April 2014. Water temperature and dissolved oxygen were measured on site using a Hydrolab DataSonde 4a (Hydrolab Corporation, Austin, TX, USA) and these data were visualized with Ocean Data View (version 4.6.5). Sulfate was measured by an auto-analyzer (SAN++, Skalar, The Netherlands) based on the methylthymol blue method46. Sulfide was fixed with zinc acetate (10% w/v) immediately in the field, and subsequently measured spectroscopically in the laboratory using methylene blue47. Water samples were filtered through 0.2 μm nylon membrane filters (Millipore, GNWP) to collect bacterial cells. Filters were frozen immediately and stored at −20 °C until further processing.

### Buoyancy frequency

The density of water, ρ (kg m−3), was calculated from temperature, T (°C), using the Thiesen–Scheel–Diesselhorst equation48. We quantified the strength of stratification as the square of the buoyancy frequency29, 30:

$${{N^{\rm{2}}} = \frac{g}{\rho }\frac{{{\rm d}\rho }}{{{\rm d}z}}}$$
(10)

where z is depth (m), g is the gravitational constant (9.8 m s−2), and dρ/dz is the density gradient at the thermocline.

The flux of oxygen across the thermocline can be calculated as F = K z (∂O 2/∂z), where K z is the vertical eddy diffusivity. The eddy diffusivity depends on the buoyancy frequency according to K z = Γε/N 2, where Γ is the mixing efficiency and ε is the rate of turbulent kinetic energy dissipation30, 49. Hence, the inverse of the squared buoyancy frequency (1/N 2) can be used as a simple proxy of the oxygen diffusivity across the thermocline.

### DNA extraction and 16S rRNA amplicon sequencing

DNA was extracted from bacteria on the filters using the PowerSoil DNA Isolation Kit according to the manufacturer’s instructions (Mo Bio, Laboratories Inc.). Extracted DNA concentrations were quantified with the Qubit dsDNA BR Assay Kit (Invitrogen). Sequencing was performed on an Illumina MiSeq system by the Research and Testing Laboratory (Lubbock, Texas, USA). The primer pair S-D-Bact-0341-b-S-17 (5′-CCTA CGGGNGGCWGCAG-3′) and S-D-Bact-0785-a-A-21 (5′-GACTACHVGGGTATCTAATCC-3′) was used to generate paired-end sequence reads covering the V3–V4 region of the 16S rRNA gene50. After quality filtering, a total of 2,934,111 sequences was obtained with an average sequence length of 420 bp.

### Co-occurrence network analysis

16S rRNA sequences were assigned to three functional groups: (1) Bacteria of the phylum Cyanobacteria (CB). (2) Phototrophic sulfur bacteria (PB) consisting of the phylum Chlorobi (green sulfur bacteria) and the order Chromatiales from the class Gammaproteobacteria (purple sulfur bacteria). (3) Sulfate-reducing bacteria (SB) consisting of the orders Desulfobacterales, Desulfuromonadales, and Desulfovibrionales from the class Deltaproteobacteria, as these were the only known sulfate-reducing bacteria present in the sequence data.

Co-occurrence networks were constructed with the Cytoscape plugin software program CoNet51. We used an ensemble approach to identify co-occurrence based on the Spearman rank correlation and Kullback–Leibler dissimilarity51. The ReBoot procedure with 4000 permutations was used to control for false-positive correlations. A false discovery rate of 5% was applied to control for multiple comparisons52.

### Data availability

The 16S amplicon sequences have been deposited in the Sequence Read Archive (SRA) of the National Center for Biotechnology Information (NCBI), as data set SAMN06314865-SAMN06314918. All other relevant data are available from the corresponding author on request.

Publisher's note: Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.

## References

1. 1.

Beisner, B. E., Haydon, D. T. & Cuddington, K. Alternative stable states in ecology. Front. Ecol. Environ. 1, 376–382 (2003).

2. 2.

Schröder, A., Persson, L. & De Roos, A. M. Direct experimental evidence for alternative stable states: a review. Oikos 110, 3–19 (2005).

3. 3.

Scheffer, M. & Carpenter, S. R. Catastrophic regime shifts in ecosystems: linking theory to observation. Trends Ecol. Evol. 18, 648–656 (2003).

4. 4.

Biggs, R., Carpenter, S. R. & Brock, W. A. Turning back from the brink: detecting an impending regime shift in time to avert it. Proc. Natl Acad. Sci. USA 106, 826–831 (2009).

5. 5.

Falkowski, P. G., Fenchel, T. & DeLong, E. F. The microbial engines that drive Earth’s biogeochemical cycles. Science 320, 1034–1039 (2008).

6. 6.

Widder, S. et al. Challenges in microbial ecology: building predictive understanding of community function and dynamics. ISME J. 10, 2557–2568 (2016).

7. 7.

Dethlefsen, L. & Relman, D. A. Incomplete recovery and individualized responses of the human distal gut microbiota to repeated antibiotic perturbation. Proc. Natl Acad. Sci. USA 108, 4554–4561 (2011).

8. 8.

Lahti, L., Salojärvi, J., Salonen, A., Scheffer, M. & de Vos, W. M. Tipping elements in the human intestinal ecosystem. Nat. Commun. 5, 4344 (2014).

9. 9.

Gerla, D. J., Mooij, W. M. & Huisman, J. Photoinhibition and the assembly of light‐limited phytoplankton communities. Oikos 120, 359–368 (2011).

10. 10.

Veraart, A. J. et al. Recovery rates reflect distance to a tipping point in a living system. Nature 481, 357–359 (2012).

11. 11.

Blodau, C. & Knorr, K.-H. Experimental inflow of groundwater induces a ‘biogeochemical regime shift’ in iron-rich and acidic sediments. J. Geophys. Res. 111, G02026 (2006).

12. 12.

Bürgmann, H., Jenni, S., Vazquez, F. & Udert, K. M. Regime shift and microbial dynamics in a sequencing batch reactor for nitrification and anammox treatment of urine. Appl. Environ. Microbiol. 77, 5897–5907 (2011).

13. 13.

Shade, A. et al. Fundamentals of microbial community resistance and resilience. Front. Microbiol. 3, 417 (2012).

14. 14.

Bush, T., Butler, I. B., Free, A. & Allen, R. J. Redox regime shifts in microbially mediated biogeochemical cycles. Biogeosciences 12, 3713–3724 (2015).

15. 15.

Shade, A., Jones, S. E. & McMahon, K. D. The influence of habitat heterogeneity on freshwater bacterial community composition and dynamics. Environ. Microbiol. 10, 1057–1067 (2008).

16. 16.

Garcia, S. L., Salka, I., Grossart, H. P. & Warnecke, F. Depth-discrete profiles of bacterial communities reveal pronounced spatio-temporal dynamics related to lake stratification. Environ. Microbiol. Rep. 5, 549–555 (2013).

17. 17.

Yu, Z., Yang, J., Amalfitano, S., Yu, X. Q. & Liu, L. M. Effects of water stratification and mixing on microbial community structure in a subtropical deep reservoir. Sci. Rep. 4, 5821 (2014).

18. 18.

Steenbergen, C. L. M. & Korthals, H. J. Distribution of phototrophic microorganisms in the anaerobic and microaerophilic strata of Lake Vechten (The Netherlands): pigment analysis and role in primary production. Limnol. Oceanogr. 27, 883–895 (1982).

19. 19.

Casamayor, E. O., Schäfer, H., Bañeras, L., Pedrós-Alió, C. & Muyzer, G. Identification of and spatio-temporal differences between microbial assemblages from two neighboring sulfurous lakes: comparison by microscopy and denaturing gradient gel electrophoresis. Appl. Environ. Microbiol. 66, 499–508 (2000).

20. 20.

Elser, J. J. et al. Global analysis of nitrogen and phosphorus limitation of primary producers in freshwater, marine and terrestrial ecosystems. Ecol. Lett. 10, 1135–1142 (2007).

21. 21.

Miller, S. R. & Bebout, B. M. Variation in sulfide tolerance of photosystem II in phylogenetically diverse cyanobacteria from sulfidic habitats. Appl. Environ. Microbiol. 70, 736–744 (2004).

22. 22.

Cypionka, H., Widdel, F. & Pfennig, N. Survival of sulfate-reducing bacteria after oxygen stress, and growth in sulfate-free oxygen-sulfide gradients. FEMS Microbiol. Lett. 31, 39–45 (1985).

23. 23.

Imhoff, J. in Anoxygenic Photosynthetic Bacteria (eds Blankenship, R. E., Madigan, M. T. & Bauer, C. E.) 1–15 (Kluwer academic publishers, 2004).

24. 24.

Luther, G. W. et al. Thermodynamics and kinetics of sulfide oxidation by oxygen: a look at inorganically controlled reactions and biologically mediated processes in the environment. Front. Microbiol. 2, 62 (2011).

25. 25.

Sievert, S. M., Kiene, R. & Schulz, H. The sulfur cycle. Oceanography 20, 117–123 (2007).

26. 26.

De Wit, R., van den Ende, F. P. & van Gemerden, H. Mathematical simulation of the interactions among cyanobacteria, purple sulfur bacteria and chemotrophic sulfur bacteria in microbial mat communities. FEMS Microbiol. Ecol. 17, 117–136 (1995).

27. 27.

Blackwood, J. C., Hastings, A. & Mumby, P. J. The effect of fishing on hysteresis in Caribbean coral reefs. Theor. Ecol. 5, 105–114 (2012).

28. 28.

Steenbergen, C. L. M. & Verdouw, H. Lake Vechten: aspects of its morphometry, climate, hydrology and physico-chemical characteristics. Hydrobiologia 95, 11–23 (1982).

29. 29.

Denman, K. L. & Gargett, A. E. Time and space scales of vertical mixing and advection of phytoplankton in the upper ocean. Limnol. Oceanogr. 28, 801–815 (1983).

30. 30.

MacIntyre, S., Flynn, K. M., Jellison, R. & Romero, J. R. Boundary mixing and nutrient fluxes in Mono Lake, California. Limnol. Oceanogr. 44, 512–529 (1999).

31. 31.

Ciglenečki, I., Carić, M., Kršinić, F., Viličić, D. & Ćosović, B. The extinction by sulfide: turnover and recovery of a naturally eutrophic, meromictic seawater lake. J. Mar. Syst. 56, 29–44 (2005).

32. 32.

Pjevac, P. et al. Community shift from phototrophic to chemotrophic sulfide oxidation following anoxic holomixis in a stratified seawater lake. Appl. Environ. Microbiol. 81, 298–308 (2014).

33. 33.

Diaz, R. J. & Rosenberg, R. Spreading dead zones and consequences for marine ecosystems. Science 321, 926–929 (2008).

34. 34.

Middelburg, J. J. & Levin, L. A. Coastal hypoxia and sediment biogeochemistry. Biogeosciences 6, 1273–1293 (2009).

35. 35.

Ulloa, O., Canfield, D. E., DeLong, E. F., Letelier, R. M. & Stewart, F. J. Microbial oceanography of anoxic oxygen minimum zones. Proc. Natl Acad. Sci. USA 109, 15996–16003 (2012).

36. 36.

Zhang, J. et al. Natural and human-induced hypoxia and consequences for coastal areas: synthesis and future development. Biogeosciences 7, 1443–1467 (2010).

37. 37.

Jenkyns, H. C. Geochemistry of oceanic anoxic events. Geochem. Geophys. Geosyst. 11, Q03004 (2010).

38. 38.

Erbacher, J., Huber, B. T., Norris, R. D. & Markey, M. Increased thermohaline stratification as a possible cause for an ocean anoxic event in the Cretaceous period. Nature 409, 325–327 (2001).

39. 39.

Kump, L. R., Pavlov, A. & Arthur, M. A. Massive release of hydrogen sulfide to the surface ocean and atmosphere during intervals of oceanic anoxia. Geology 33, 397–400 (2005).

40. 40.

Sinninghe Damsté, J. S. & Köster, J. A euxinic southern North Atlantic Ocean during the Cenomanian–Turonian oceanic anoxic event. Earth. Planet. Sci. Lett. 158, 165–173 (1998).

41. 41.

Kuypers, M. M. M., Pancost, R. D., Nijenhuis, I. A. & Sinninghe Damsté, J. S. Enhanced productivity led to increased organic carbon burial in the euxinic North Atlantic basin during the late Cenomanian oceanic anoxic event. Paleoceanography 17, 1051 (2002).

42. 42.

Pancost, R. D. et al. Further evidence for the development of photic‐zone euxinic conditions during Mesozoic oceanic anoxic events. J. Geol. Soc. 161, 353–364 (2004).

43. 43.

Bader, F. G. Analysis of double‐substrate limited growth. Biotechnol. Bioeng. 20, 183–202 (1978).

44. 44.

Haldane, J. B. S. Enzymes (Longmans Green, 1930).

45. 45.

Andrews, J. F. A mathematical model for the continuous culture of microorganisms utilizing inhibitory substrates. Biotechnol. Bioeng. 10, 707–723 (1968).

46. 46.

Adamski, J. M. & Villard, S. P. Application of the methylthymol blue sulfate method to water and wastewater analysis. Anal. Chem. 47, 1191–1194 (1975).

47. 47.

Trüper, H. G. & Schlegel, H. G. Sulphur metabolism in Thiorhodaceae.1. Quantitative measurements on growing cells of Chromatium okenii. Ant. Leeuwenhoek 30, 225–238 (1964).

48. 48.

McCutcheon, S. C., Martin, J. L. & Barnwell Jr, T. O. in Handbook of Hydrology (ed. Maidment, D. R.) 11.1–11.6 (McGraw-Hill, 1993).

49. 49.

Osborn, T. R. Estimates of the rate of vertical diffusion from dissipation measurements. J. Phys. Oceanogr. 10, 83–89 (1980).

50. 50.

Herlemann, D. P. et al. Transitions in bacterial communities along the 2000 km salinity gradient of the Baltic Sea. ISME J. 5, 1571–1579 (2011).

51. 51.

Faust, K. & Raes, J. CoNet app: inference of biological association networks using Cytoscape [version 2]. F1000 Res. 5, 1519 (2016).

52. 52.

Benjamini, Y. & Hochberg, Y. Controlling the false discovery rate: a practical and powerful approach to multiple testing. J. R. Stat. Soc. Ser. B Methodol. 57, 289–300 (1995).

## Acknowledgements

We thank Pieter Slot, Cherel Balkema, and Bas van Beusekom for assistance during fieldwork, Peter Serné for nutrient analysis, Karoline Faust for help with the co-occurrence network analysis, André De Roos, Hal Caswell, Emily Melton, Elliot Marsden, Qian Li, and Andrew Free for useful discussions, and Petra Pjevac T.B., R.S., and G.M. were financially supported by the research priority area Systems Biology of the University of Amsterdam. In addition, T.B. was supported by the US Army Research Office under grant number 64052-MA and by HFSP under grant RGY0081/2012, M.D. was supported by a PhD scholarship from the China Scholarship Council (CSC), R.J.A. was supported by a Royal Society University Research Fellowship, and G.M. was supported by the ERC Advanced Grant PARASOL (No. 322551).

## Author information

G.M. and J.H. conceived the idea, and T.B. and R.J.A. added further suggestions. T.B., R.S., and J.H. designed the model. T.B. and J.H. performed the model simulations and analysis. M.D, R.S., and G.M. sampled the lake. M.D. performed the nutrient analysis. M.D. and G.M. performed the 16S rRNA sequence and network analysis. T.B., M.D., G.M., and J.H. wrote the manuscript, and all authors commented on the final version.

### Competing interests

The authors declare no competing financial interests.

Correspondence to Gerard Muyzer.