When being flexible matters: Ecological underpinnings for the evolution of collective flexibility and task allocation

Edited by Raghavendra Gadagkar, Indian Institute of Science, Bangalore, India; received August 31, 2021; accepted February 20, 2022
April 29, 2022
119 (18) e2116066119

Significance

A central problem in evolutionary biology is explaining variation in the organization of task allocation across collective systems. Why do human cells irreversibly adopt a task during development (e.g., kidney vs. liver cell), while sponge cells switch between different cell types? And why have only some ant species evolved specialized castes of workers for particular tasks? Although it seems reasonable to suppose that such differences reflect, at least partially, the different ecological pressures that systems face, there is no general understanding of how a system’s dynamic environment shapes its task allocation. To this end, we develop a general mathematical framework that reveals how simple ecological considerations could potentially explain cross-system variation in task allocation—including in flexibility, specialization, and (in)activity.

Abstract

Task allocation is a central feature of collective organization. Living collective systems, such as multicellular organisms or social insect colonies, have evolved diverse ways to allocate individuals to different tasks, ranging from rigid, inflexible task allocation that is not adjusted to changing circumstances to more fluid, flexible task allocation that is rapidly adjusted to the external environment. While the mechanisms underlying task allocation have been intensely studied, it remains poorly understood whether differences in the flexibility of task allocation can be viewed as adaptive responses to different ecological contexts—for example, different degrees of temporal variability. Motivated by this question, we develop an analytically tractable mathematical framework to explore the evolution of task allocation in dynamic environments. We find that collective flexibility is not necessarily always adaptive, and fails to evolve in environments that change too slowly (relative to how long tasks can be left unattended) or too quickly (relative to how rapidly task allocation can be adjusted). We further employ the framework to investigate how environmental variability impacts the internal organization of task allocation, which allows us to propose adaptive explanations for some puzzling empirical observations, such as seemingly unnecessary task switching under constant environmental conditions, apparent task specialization without efficiency benefits, and high levels of individual inactivity. Altogether, this work provides a general framework for probing the evolved diversity of task allocation strategies in nature and reinforces the idea that considering a system’s ecology is crucial to explaining its collective organization.
Collective distributed systems—such as multicellular organisms, social insect colonies, or computer networks—depend on the coordinated functioning of individual components that perform different tasks. All these systems face a fundamental problem of task allocation: how to distribute individuals over different tasks to ensure that the system meets the demands of the dynamic environment that it operates in. Living collective systems have evolved myriad ways to solve this problem and exhibit substantial cross-system variation in diverse properties of task allocation (15).
In particular, systems vary in their degree of collective flexibility—that is, in the extent to which they flexibly adjust task allocation to changing external circumstances. For example, colonies of harvester ants (Pogonomyrmex barbatus) adjust their foraging activity in response to food availability, presence of predators, and weather conditions (68). In contrast, red wood ant (Formica polyctena) colonies are more consistent in their foraging effort and do not readily adjust foraging activity to changes in the environment (9, 10). Similarly, while some species of multicellular cyanobacteria regulate nitrogen fixation in response to the diurnal cycle by switching from photosynthesis during the day to nitrogen fixation at night, other species lack this collective flexibility and instead have evolved dedicated, irreversibly differentiated cells that fix nitrogen continually (1117). Finally, while cells in most human tissues irreversibly differentiate during development, the immune system is unusual in that it exhibits substantial flexibility in response to unpredictable attacks by pathogens, through activation and proliferation of specific immune cells and reallocation of existing immune cells to different defensive functions (1821).
While such cross-system variation in the flexibility of task allocation is not necessarily adaptive and could partly result from constraints on the mechanisms by which task allocation can be achieved, one would expect that, at least to some extent, this variation reflects the different ecological pressures that different systems face (9, 2225). In particular, the temporal variability of the environment may be an important ecological factor, as environments in which the yields or demands of different tasks vary substantially over time may select for the evolution of flexibility to cope with, or take advantage of, this environmental variation (9, 2628). Understanding the evolution of collective flexibility, then, requires a framework that can evaluate task allocation in the context of a dynamic environment. Although the need for such a framework has been pointed out by multiple authors (2224), most current evolutionary models of task allocation do not account for the variability of the environment that the system operates in (refs. 2934, although see ref. 35 for a notable exception in the specific context of age polyethism in social insects).
To address this gap, here we develop a simple and analytically tractable theoretical framework to study the evolution of task allocation in dynamic environments. We take a complementary approach to the existing theoretical literature and focus on the ultimate factors that shape the properties of task allocation, instead of the proximate, individual-level, mechanisms by which task allocation emerges [e.g., response thresholds, communication between individuals, spatial differentiation (22)]. Indeed, because we aim to compare across systems where task allocation may be achieved via diverse underlying mechanisms, our approach leaves these mechanisms largely implicit and instead describes the resulting task allocation dynamics phenomenologically. This approach allows us to investigate how the evolution of task allocation is shaped by various ecological factors, including how variable the environment is, how sensitive tasks are to environmental variation, how long tasks can be left unattended for, and how quickly the system can respond to changes in environmental conditions.
We first use our framework to explore the ecological conditions under which systems that face a variable environment might evolve collective flexibility. Subsequently, we investigate how selection for (or against) collective flexibility may, in turn, impact various aspects of the internal organization of task allocation—including how frequently individuals switch between different tasks, whether or not some tasks are performed by dedicated specialists, and whether or not individuals spend some of their time being inactive (i.e., not performing any task).

Model

Our model describes a collective system that allocates its individuals to different essential tasks. The system may adjust its task allocation in response to a temporally variable external environment. We assume that task allocation evolves to optimize some form of collective fitness (which is appropriate for the systems we have in mind, such as multicellular organisms and social insect colonies), and we determine how the optimal task allocation depends on various ecological parameters. For simplicity, we assume that there are only two tasks, which suffices to capture the essence of task allocation: increasing allocation toward one task detracts from other tasks.

Environmental Variability.

The system experiences two equally likely environmental states A and B (Fig. 1A). The environment changes at a rate λ>0, upon which a new environmental state is sampled independently of the current state (and possibly equal to it). Task yields may differ across environments, and so we denote the environment-specific task yields by Y1,A, Y1,B, Y2,A, and Y2,B, where, for example, Y1,A denotes the yields for task 1 in environment A. To summarize how sensitive each task is to environmental conditions, we also introduce parameters θ1=Y1,A/Y1,B and θ2=Y2,A/Y2,B. If θi>1, then task i has higher yield in environment A than in environment B; if, conversely, θi<1, then task i has higher yield in environment B than in environment A; finally, if θi=1, then task i has equal yields in environments A and B, and hence it is not sensitive to the environment.
Fig. 1.
Model setup. (A) We model a collective system that experiences two equally likely environments A and B. New environments are sampled at a rate λ, independent from the current environment. Task yields Yi may depend on the environment; two parameters, θ1=Y1,A/Y1,B and θ2=Y2,A/Y2,B, indicate how sensitive each task is to environmental conditions. (B) The fraction of individuals a1(t) allocated toward task 1 approaches equilibrium values z1,A (in environment A) and z1,B (in environment B). Task allocation is adjusted at rate δ. (C) Task yields Yi are added to a collective task stock Si, proportional to current allocation ai. Task stocks are depleted at a rate γ. The system is evaluated on its ability to maintain stocks for both tasks; we use the average value of S1(t)S2(t) as a measure of collective fitness.

Task Allocation Dynamics.

We assume that individuals are continually active and thus, at any point in time, either performing task 1 or task 2. We write a1(t) for the fraction of individuals that are performing task 1 at time t, and a2(t)=1a1(t) for the fraction of individuals that are performing task 2. We assume that the system has a capacity for homeostasis, so that, given enough time in one environment, the fractions of individuals (a1,a2) allocated to each task stabilize at some equilibrium task allocation (z1,z2). We write (z1,A, z2,A)=(z1,A,1z1,A) for the equilibrium allocation reached in environment A and (z1,B, z2,B)=(z1,B,1z1,B) for the equilibrium allocation reached in environment B.
How quickly the system approaches the equilibrium task allocation upon a change in environmental conditions depends on constraints on the system’s ability to detect and respond to changes in environmental conditions, which we capture via a parameter δ. In particular, we assume that the system approaches the environment-dependent equilibria exponentially at rate δ (Fig. 1B), so that the task allocation dynamics are given by
daidt=δ(ziai).
[1]
The mechanisms that underlie these dynamics are left implicit. Thus, we do not explicitly consider how individuals detect changes in the environment, whether and how they communicate information about the environment to other individuals, and how they decide to perform a particular task. We simply assume that a combination of such mechanisms will allow the system to adjust its task allocation to its environment, and we use the parameter δ to summarize the resulting time scale of adjustment. This phenomenological approach allows us to compare the fitness consequences of different patterns of task allocation across collective systems in which these patterns may emerge through diverse underlying mechanisms.

Task Performance and Fitness.

For simplicity, we assume that the total yield obtained for each task scales linearly with the number of individuals allocated to it, so that, at time t, the total yield for task i equals ai(t)Yi(t). In other words, we assume that, if interactions among individuals do exist, they do not lead to diminishing returns or synergistic effects in total yield (i.e., per capita yield decreasing or increasing as a function of allocation, respectively). To track the system’s task performance over time, we assume that obtained task yields for task i are added to a collective task stock Si (Fig. 1C). For example, for tasks that extract resources from the environment (e.g., nitrogen fixation in cyanobacteria, or foraging in ants), the stock represents the amount of resource the system currently has. Task yields are added to the task stock at a rate β and are depleted from the stock at a rate γ>0,
dSidt=βaiYiγSi.
Because β affects the task stock dynamics only by rescaling the average stock size, we can, without loss of generality, assume that β=γ, so that γ sets the time scale of task stock dynamics without affecting the average stock size (SI Appendix). This simplifies the task stock dynamics to dSi/dt=γ(aiYiSi). When task stock dynamics are fast (high γ), the stock mostly comprises task yields that have been obtained very recently; when task stock dynamics are slow (low γ), task yields that were obtained farther in the past also substantially contribute to the task stock. Thus, the rate of task stock depletion γ sets the time scale over which the system can temporally integrate task yields.
We introduce a measure of collective fitness F that evaluates the system on its ability to maximize task yields, while, at the same time, ensuring that no task goes unattended for too long. Specifically, we define F=S1(t)S2(t)t as the temporally averaged product S1(t)S2(t) of the stocks for both tasks. Multiplying the sizes of the stock for each task renders the two tasks nonsubstitutable and requires the system to balance its effort toward both. However, tasks do not necessarily have to be attended to at all times: When performance of a task is temporarily interrupted, the corresponding task stock will not disappear immediately, but will only be depleted at rate γ. We can therefore also think of γ as determining how long tasks can be left unattended for.
In averaging S1(t)S2(t) over time, we assume that the fitness effects of performing both tasks are additive over the lifespan of the system. We will moreover assume that the system is sufficiently long-lived to be repeatedly exposed to all possible environmental conditions over its lifespan. Under this assumption, we need to take into account only environmental variation that occurs within (but not across) generations of the system.
In SI Appendix, we derive a closed-form expression for collective fitness F in terms of the three relevant ecological time scales set by the rates of environmental fluctuations (λ), task stock depletion (γ), and adjustment of task allocation (δ); the environment-dependent task yields (Y1,A, Y1,B, Y2,A, Y2,B); and the equilibrium task allocation (z1,A, z1,B) in each environment (see SI Appendix, Fig. S1 for validation of the result). We use this closed-form expression to compute the optimal equilibrium task allocations (z1,A, z1,B) that maximize fitness (subject to the constraints 0z1,A,z1,B1) for given values of the other parameters.

Results and Discussion

The Evolution of Collective Flexibility.

All three ecological time scales impact the optimal task allocation.

We start by investigating systems where the yields of only one of the two tasks depend on environmental conditions (θ1>1, θ2=1). For example, this scenario could represent multicellular cyanobacteria where we can assume that the yields of photosynthesis, but not nitrogen fixation, depend on the time of day, or some ant colonies where we can assume that the yields of foraging, but not of nest-associated tasks such as nursing or nest maintenance, depend on food availability around the colony. For such systems, environmental variability in task yields creates an incentive to adjust task allocation to the environment: Performing the environment-sensitive task specifically under the conditions that favor it can increase task yields and thereby system fitness. At the same time, however, temporarily biasing allocation toward a task comes with the risk that the corresponding neglect of the other task reduces fitness. Therefore, it is not clear a priori whether and when environmental variability renders it optimal to adjust task allocation to the environment.
To address this question, we use our model to determine the optimal dynamic task allocation as a function of the three ecological time scales considered: adjustment of task allocation (Fig. 2A), task stock depletion (Fig. 2B), and environmental variability (Fig. 2C). We characterize this optimal task allocation by its equilibrium allocations z1,A and z1,B (toward task 1 in environments A and B, respectively), as well as the corresponding average allocations a1,A¯=δδ+λz1,A+λδ+λz1,A+z1,B2 and a1,B¯=δδ+λz1,B+λδ+λz1,A+z1,B2 (SI Appendix), which take into account that the system is not necessarily able to reach its equilibrium allocation. Indeed, the average allocation closely matches the equilibrium allocation when the system is able to adjust its task allocation quickly relative to the time scale of environmental fluctuations (δ/λ sufficiently large; e.g., scenario iii in Fig. 2), but deviates from the equilibrium allocation when the system adjusts too slowly to be able to reach its equilibrium allocation before the environment changes again (δ/λ not large enough; e.g., scenario ii in Fig. 2). We quantify collective flexibility as the difference between the average allocations toward task 1 in environments A and B, i.e., a1,A¯a1,B¯=(z1,Az1,B)δδ+λ. This measure of collective flexibility equals 0 when a1,A¯=a1,B¯, meaning that there is no difference in average task allocation between the two environments, and 1 when a1,A¯=1 and a1,B¯=0, meaning that, in environment A, only task 1 is performed, and in environment B, only task 2 is performed.
Fig. 2.
Optimal task allocation strategies when only one task is sensitive to the environment (θ1=4, θ2=1). (AC) Optimal equilibrium task allocation (z1,A, z1,B) and the corresponding average task allocations (a1,A¯, a1,B¯). The level of collective flexibility is quantified as the difference a1,A¯a1,B¯. Parameters δ (A), γ (B), and λ (C) are varied independently, while the other two parameters are kept constant (constant values: γ=0.2, δ=1, and λ=1). (DI) Evolved task allocation dynamics for three values of δ: δ=0.1 (D and E), δ=1 (F and G), and δ=10 (H and I). Parameters γ=0.2 and λ=1.0 are kept fixed. Equilibrium task allocations are (z1,A,z1,B)=(0.56,0.44) (D and E), (z1,A,z1,B)=(0.84,0) (F and G), and (z1,A,z1,B)=(0.85,0) (H and I). (D, F, and H) Task allocation dynamics over time, as given by dai/dt=δ(ziai). The same pattern of environmental change is shown for each scenario. (E, G, and I) Task stock dynamics over time, as given by dSi/dt=γ(aiYiSi) (arbitrary units). Changes in the dynamics of S1 are caused by temporal variation in task yields Y1 (θ1=4) and task allocation a1; changes in the dynamics of S2 are caused only by temporal variation in task allocation a2 because the yields Y2 for task 2 are constant (θ2=1).
We find that the evolution of task allocation depends strongly on all three ecological time scales considered and that diverse task allocation dynamics can be evolutionarily optimal. We first focus on each time scale separately and vary the rate parameters δ, γ, and λ independently (while keeping the other two fixed; see SI Appendix for formal analysis); subsequently, we consider all time scales simultaneously to derive general conditions for the evolution of collective flexibility that depend on the relative magnitudes of δ, γ, and λ.
In Fig. 2 DI, we show the optimal task allocation dynamics for three choices of parameters that differ in the rate δ at which the system can adjust its task allocation to the environment (corresponding to cases i through iii in Fig. 2A). For low δ, we find that it is optimal to be unresponsive to the environment and equally allocate individuals to both tasks, thereby ensuring that the system properly balances its attention toward them (a1,A¯a1,B¯1/2; Fig. 2 A, D, and E). As δ increases, the system evolves to adjust its task allocation to its environment (Fig. 2 A and F–I), preferentially performing the environment-sensitive task under conditions that favor it (i.e., a1,A¯>1/2 and a1,B¯<1/2). Adjusting task allocation to the environment allows the system to obtain higher task yields, maintain higher task stocks (compare Fig. 2 G and I with E), and therefore achieve higher fitness (SI Appendix, Fig. S2). The level of collective flexibility a1,A¯a1,B¯ that evolves increases with δ, because for higher δ the system evolves more biased equilibrium allocations z1,A and z1,B (Fig. 2A), and it reaches these equilibrium allocations faster (e.g., compare scenario ii, where the equilibrium allocation is typically not reached before the environment changes [Fig. 2F], to scenario iii, where the system spends most of its time at the equilibrium allocation for the current environment [Fig. 2H]).
When we instead vary the rate of task stock depletion γ, we find that adjustments of task allocation fail to evolve when task stocks are depleted too quickly (high γ; Fig. 2B), because then temporarily neglecting tasks is strongly selected against. In contrast, when task stocks are depleted more slowly and the fitness consequences of temporarily neglecting tasks are less dire (γ0), it becomes optimal to bias task allocation as much as possible (z1,A1, z1,B0). In this case, the level of collective flexibility approaches δ/(δ+λ) and is thus determined by how quickly the system adjusts its task allocation relative to the time scale of environmental fluctuations (SI Appendix and Fig. 2B).
Finally, when we vary the rate of environmental fluctuations λ, we find that adjustments of task allocation evolve only if the environment changes sufficiently quickly (λ sufficiently large; Fig. 2C). If the environment changes too slowly, biasing task allocation toward a specific task would again lower fitness, because it causes the other task to go neglected for too long. As λ increases, the equilibrium task allocations z1,A and z1,B become progressively more biased, although, eventually, adjustments to the environment fail to be realized because the environment changes too quickly for the system to be able to adjust to it (i.e., a1,A¯ and a1,B¯ approach 1/2; Fig. 2C).
The task allocation dynamics that evolve have some surprising features. For example, as Fig. 2D shows, it may be optimal to continue to perform tasks when their yields are low (or even zero; SI Appendix, Fig. S3): In environment B, task 1 is still being performed by half of the individuals, even though its yield is 4 times lower than in environment A. Thus, the apparent inefficiency of performing tasks under suboptimal conditions can be evolutionarily optimal. Another unexpected finding is that, even though both tasks contribute equally to fitness, the optimal task allocation can be asymmetric. For example, in scenario iii (Fig. 2 H and I), individuals spend on average 30% more time performing task 2 than task 1 and only the performance of task 1 is restricted to specific environmental conditions. We can show analytically that if the environment-sensitive task 1 is sufficiently sensitive to the environment (i.e., provided θ1>(4γ+λ)/λ; SI Appendix), then for large enough δ it becomes optimal to only perform it in environment A (z1,B becomes 0 and a1,B¯ approaches 0 as δ; Fig. 2A). In contrast, for the environment-insensitive task 2, it is always optimal to perform it in both environments (i.e., z1,A and a1,A¯ never become 1; Fig. 2A), with allocation toward it never dropping below γ/(2γ+λ) (SI Appendix). Thus, only for sufficiently environment-sensitive tasks can it be optimal to temporarily ignore them, and, as a result, total allocation—over the lifespan of the system—may be biased toward environment-insensitive tasks.

Collective flexibility evolves only under certain ecological conditions.

Having explored the effect of each of the three ecological time scales separately, we now look at the effect of all three varying simultaneously. The level of collective flexibility that evolves in the model varies continuously as a function of λ, δ, and γ, ranging from a regime in which negligible collective flexibility evolves (a1,A¯a1,B¯0) to a regime in which near-maximal levels of collective flexibility evolve (a1,A¯a1,B¯1), with intermediate levels of collective flexibility in between (Fig. 3A, and see SI Appendix, Fig. S4 for the corresponding values of z1,A, z1,B, a1,A¯, and a1,B¯). We see that the evolution of nonnegligible collective flexibility requires two conditions to be met simultaneously (Fig. 3B). First, the rate of task stock depletion must be sufficiently low relative to the rate at which the environment fluctuates (γ/λ sufficiently small), so that tasks can be temporarily left unattended without the corresponding task stock being depleted to such low levels that fitness is compromised. Second, the rate of adjustment of task allocation should be sufficiently high relative to the rate at which the environment fluctuates (δ/λ sufficiently large), so that a biased task allocation can be achieved before the environment changes.
Fig. 3.
The evolution of collective flexibility. (A) The evolution of collective flexibility depends on the relative ratios of three ecological time scales: the time scales of adjustment of task allocation to the environment (δ parameter), task stock depletion (γ  parameter), and environmental fluctuations (λ parameter). The two-dimensional visualization takes advantage of the fact that there are three time scales but only two degrees of freedom: Rescaling each time scale by the same amount does not affect the model dynamics. The three axes are interdependent (indeed, δ/λ=(δ/γ)(γ/λ)); each point in the coordinate space can be orthogonally projected on each axis (in the plane of the figure). Parameters are θ1=4 and θ2=1. (B) Collective flexibility evolves when γ/λ is sufficiently small and δ/λ is sufficiently large. (C) Collective flexibility can evolve whenever θ1θ2 and is maximized for intermediate environment fluctuation rates λ. Parameters γ=0.2 and δ=1.0 are kept fixed.
These general theoretical conditions for the evolution of collective flexibility comport with empirical observations in desert harvester ants (P. barbatus), where collective flexibility—in the form of regulating foraging activity levels in response to day-to-day variation in humidity—has been shown to be adaptive (7, 8). Relative to the daily time scale of environmental fluctuations, in harvester ant colonies the adjustment of task allocation indeed takes place on a much faster time scale [within minutes, via interactions with returning foragers or patrollers (8, 36)], while their task stocks deplete on a much slower time scale [collected seeds are stored for up to months (7)].
Based on our results, we predict that across systems that face similar constraints on task allocation (i.e., have similar values of γ, δ), such as closely related species of ants, collective flexibility is least likely to evolve in systems living in environments that change very quickly or very slowly and is most likely to evolve in systems living at intermediate degrees of temporal environmental variability (Fig. 3C). Indeed, the evolution of collective flexibility requires the environment to change quickly enough for the system to be able to exploit environmental variability, but not so quickly that the system loses the ability to adjust its task allocation in time.

Collective flexibility can evolve whenever tasks differ in how their yields depend on the environment.

Our results generalize to scenarios in which not one but both tasks are sensitive to environmental conditions. In this case, either one environment maximizes yields for both tasks (correlated task yields across environments; θ1, θ2>1 or θ1, θ2<1), or the yields for the two tasks are maximized in opposite environments (anticorrelated task yields; θ1<1<θ2 or θ2<1<θ1). As an example of correlated task yields, consider pollen and nectar foraging in a honey bee colony (37), both of which may result in higher yields during good weather conditions. In contrast, a hypothetical primitive multicellular organism that allocates cells to feeding and motility and navigates a spatially heterogeneous resource environment could be an example of anticorrelated task yields, if feeding (but not motility) is favored when resources are plentiful while motility (but not feeding) is favored when resources are scarce.
In this more general setup where both tasks are sensitive to the environment, we find that collective flexibility can evolve as long as the two tasks differ in how they depend on environmental conditions (θ1θ2; Fig. 3C), but that no collective flexibility can evolve when θ1=θ2 (see Fig. 3C for θ1=θ2=4 and SI Appendix for a general mathematical derivation). In particular, collective flexibility can evolve even when task yields are correlated (Fig. 3C; θ1=4, θ2=2). In this case, the more environment-sensitive task will be prioritized under conditions favorable to both tasks, increasing the yield for this task to such an extent that it outweighs a concomitant decrease in yield for the less environment-sensitive task (which is now preferentially performed under conditions unfavorable to both tasks). While collective flexibility can evolve even when task yields are correlated, it is most pronounced (Fig. 3C) and provides the largest fitness benefits (SI Appendix, Fig. S2) when task yields are, instead, anticorrelated across environments, so that adjusting task allocation to the environment can simultaneously increase the yields obtained for both tasks.

Consequences of Environmental Variability for the Internal Organization of Task Allocation.

The framework we have developed to investigate the evolution of collective flexibility additionally presents the opportunity to explore how environmental variability affects the internal organization of task allocation. We do so in three separate extensions of our framework that each focus on a different organizational property: task switching, specialization, and inactivity, respectively. Together, these extensions showcase the versatility of our framework as a platform to investigate the evolution of diverse aspects of task allocation in the context of a dynamic environment.

Costly task switching may evolve to achieve collective flexibility.

One way in which systems adjust their task allocation to changing conditions is by reallocating existing individuals to different tasks (i.e., task switching).* Task switching may be associated with fitness costs, because adjusting to a new task can require time and/or energy (4244). So far, we have not considered such costs to flexibility: While in our original model systems are constrained by how quickly they can adjust their task allocation, these adjustments are not costly. We therefore extend our model to incorporate task-switching costs and explore what task-switching strategies evolve when task switching is costly but at the same time required for collective flexibility.
Incorporating task-switching costs requires specifying how the net change in the overall task allocation (as given by Eq. 1) comes about from individuals switching between tasks (Fig. 4A). For simplicity, we make the minimal assumption that task-switching rates depend only on the task being performed and on the current environment. Consequently, we parametrize our task-switching model by four parameters, r12,A, r12,B, r21,A, and r21,B, that describe the per capita rates of task switching in either direction (from task 1 to task 2 or vice versa) and in either environment (A or B). In SI Appendix, we show that there is a unique way to choose these parameters that is consistent with Eq. 1: We must have r12,A=δz2,A, r12,B=δz2,B, r21,A=δz1,A, and r21,B=δz1,B. These equations can be interpreted as individuals reevaluating their current task at rate δ (prompted, for example, by observations of the environment) and then adopting task 1 with probability z1 and task 2 with probability z2. While this setup is an oversimplification of the decision-making processes underlying task switching in many real systems, it suffices to explore theoretically the trade-off between the benefits of collective flexibility and the costs of task switching.
Fig. 4.
The evolution of task allocation strategies under costly task switching. (A) The net flow δ(z1a1) from task 2 to task 1 can be decomposed as the difference between a flow δz1a2  of individuals switching from task 2 to task 1 at a per capita rate δz1 and a flow δz2a1 of individuals switching from task 1 to task 2 at a per capita rate δz2. Indeed, δz1a2δz2a1=δz1(1a1)δ(1z1)a1=δ(z1a1). (B) Evolved reevaluation rates δ, capped at 103 and at 103 (see SI Appendix, Fig. S5 for the corresponding values of z1,A and z1,B). (CE) Task-switching dynamics for parameter combinations corresponding to the different qualitative regimes that emerge: no task switching for λ=0.1, c=1 (C); deterministic task switching in response to the environment for λ=0.5, c=0.025 (D); and stochastic task switching in both environments for λ=0.1, c=0.025 (E). Each row corresponds to one individual. In BE, we have γ=0.1, θ1=4, and θ2=1.
The above assumptions on the rates of task switching allow the net change in task allocation to be decomposed into flows of individuals switching from task 2 to task 1 (at a per capita rate δz1) and from task 1 to task 2 (at a per capita rate δz2) (Fig. 4A). The average rate of task switching now equals
δ¯=δ(a1,A¯z2,A+a2,A¯z1,A)+(a1,B¯z2,B+a2,B¯z1,B)2<δ
[2]
(SI Appendix). Total (i.e., system-level) task-switching costs can therefore be implemented by subtracting from fitness a cost cδ¯, where c is a parameter that controls how costly one task switching event is, regardless of the direction of the switch. To characterize the evolution of task switching, we will calculate what combination of δ(0,) and z1,A, z1,B[0,1] maximizes fitness. Thus, δ is now evolvable rather than being a fixed constraint on task allocation. Higher values of δ allow the system to adjust its task allocation more quickly, but may also lead to higher total task-switching costs (Eq. 2).
We find that, in the extreme case of no task-switching costs (c=0), arbitrarily large reevaluation rates δ evolve, as increasing δ allows for quicker collective adjustments of task allocation at no additional cost (Fig. 4B). At the other extreme of very high task-switching costs, arbitrarily small reevaluation rates evolve (δ0) because the costs of task switching outweigh any potential benefits of collective flexibility. As a result, individuals rarely switch tasks, and end up being essentially irreversibly committed to their current task (Fig. 4C). This confirms that task-switching costs can suffice to drive the evolution of specialization, a result that has been previously obtained with simulation models (43, 45). Our analysis additionally reveals an ecological dimension to this phenomenon: How high task-switching costs need to be to drive the evolution of irreversible specialization depends on the potential benefits of collective flexibility. The higher the benefits of collective flexibility (which are maximized at intermediate environmental fluctuation rates λ; SI Appendix, Fig. S2), the higher the task-switching costs needed to offset those benefits and drive the evolution of irreversible specialization (Fig. 4B).
When task-switching costs are not high enough to completely impede the evolution of flexibility, we find that two types of flexible task-switching strategies can evolve (Fig. 4B). In environments that change sufficiently quickly (relative to the time scale of task stock depletion), individuals evolve to instantaneously and deterministically switch tasks (δ=; z1,A=1, z1,B=0) in response to shifts in environmental conditions (Fig. 4D), akin to undifferentiated cyanobacteria in which all cells switch between photosynthesis during the day and nitrogen fixation at night. While this strategy limits task-switching costs by having individuals switch between tasks only in response to environmental change (indeed, we have δ¯=λ/2, so the total costs of task switching remain bounded), it is not feasible in environments that change too slowly, where it would cause tasks to go neglected for too long. In those environments, a task-switching strategy evolves instead in which individuals switch tasks stochastically, even in the absence of environmental change, thereby making sure that both tasks receive attention at all times (Fig. 4E).
These results provide theoretical corroboration for the empirical observation that in some real systems individuals frequently switch tasks, even in the apparent absence of environmental changes that would necessitate a shift in overall task allocation. In paper wasps (Polybia), for example, workers constructing the nest flexibly switch between water collection, pulp collection, and building (46, 47). Similarly, while most animal cells are irreversibly assigned a task during development and therefore never switch tasks, some multicellular animals exhibit a more labile (and evolutionarily more ancient) form of cell differentiation in which cells readily transition between different cell types (4851). For example, in sponges (e.g., Amphimedon queenslandica), archeocytes can spontaneously transdifferentiate to become choanocytes, and vice versa (5254). Our results suggest that such individual-level flexibility can be adaptive—even when it leads to unnecessary and potentially costly task switching in the absence of environmental change—because it enables collective adjustments of task allocation when environmental conditions do change.

Environmental variability constrains the evolution of individual specialization.

So far, we have been agnostic toward which individuals are performing what tasks. In a second extension of our original model, we consider how the system may distribute the performance of different tasks across different individuals (i.e., spatially) in addition to distributing them across different environmental conditions (i.e., temporally). In many extant collective systems, individuals indeed exhibit persistent differences in task performance, although to varying degrees (46, 5563). We reason that such specialization may be favored because it has the potential—albeit not universal (64)—intrinsic benefit of improved efficiency (i.e., specialists may be more efficient at a task due to experience or task-specific physiological adaptations) (33, 34, 6567). At the same time, however, specialization limits an individual’s ability to be reallocated to other tasks when needed, thereby constraining the system’s collective flexibility. We therefore use our model to explore how environmental variability impacts the evolution of specialization.
We consider the evolution of specialists “one task at a time,” which allows us to capture how the evolution of specialists may potentially differ between tasks. Specifically, we assume that a fraction s of individuals are identical “specialists” that perform only task 1, and the remaining fraction, 1s, are identical “generalists” that can perform both tasks and adjust their task allocation at a rate δ without an associated cost, as in the original model. We introduce a parameter α that controls the efficiency gains of specialization: specifically, the yields specialists obtain for task 1 are multiplied by 1+α. Treating the efficiency parameter α as a fixed constraint, we allow the proportion of specialists s and the task allocation of generalists to evolve, and ask what combination of s[0,1] and z1,A, z1,B[0,1] maximizes fitness (SI Appendix).
We first determine how the minimum efficiency benefits α* required for the evolution of at least some specialists (i.e., s>0) depend on ecological conditions. We find that specialization is easiest to evolve (i.e., requires the lowest α*) when the potential benefits of collective flexibility are limited. In particular, when it is optimal to perform a task under all conditions, minimal efficiency benefits suffice: Specialists for such a task can evolve as soon as α>0 (Fig. 5A and SI Appendix). In contrast, when the benefits of collective flexibility render it optimal to restrict the performance of a task to specific environmental conditions, evolving specialists is more difficult. In this case, the efficiency gains of specialization must outweigh the fitness costs incurred by sacrificing some collective flexibility, and substantial gains in efficiency may be required for specialization to evolve (Fig. 5A).
Fig. 5.
The evolution of task specialists. (A) Minimum efficiency gain α* required for the evolution of specialists that perform only the environment-sensitive task 1. The visualization is two-dimensional, as in Fig. 3A; each data point can be orthogonally projected (in the plane of the figure) onto each of the three interdependent axes. (B) Optimal fraction of specialists s for α= 0.1. (CE) Examples of possible task allocation dynamics for the three qualitatively different regimes identified in B: No specialists evolve, and task 1 is performed only by generalists (C); task 1 is performed by both generalists and task 1 specialists (D); task 1 is performed only by task 1 specialists and the remaining generalists are effectively specialists for task 2 (E). Parameters for the displayed task allocation dynamics are 10γ=δ=λ (C), 4γ= δ=λ (D), and γ=δ=λ (E). In AE we have θ1=4, θ2=1. See SI Appendix, Fig. S6 for the evolution of specialists for the environment-insensitive task 2.
How easy it is to evolve specialists for a task depends on the task’s sensitivity to environmental conditions. Individuals specialize most easily on tasks whose yields are relatively insensitive to environmental fluctuations because, for those tasks, it tends to be evolutionarily optimal to perform them most or all of the time (thereby allowing specialists to evolve even when efficiency benefits are small; SI Appendix, Fig. S6). For example, we predict that an undifferentiated cyanobacterium that can photosynthesize only during the day but can fix nitrogen at any time would require smaller efficiency benefits to evolve cells specialized for nitrogen fixation (a less environment-sensitive task) than to evolve cells specialized for photosynthesis (a more environment-sensitive task). Consistent with this, some species of cyanobacteria (e.g., Anabaena variabilis) have evolved specialized nitrogen-fixing cells, while the remaining cells continue to perform both tasks: They photosynthesize during the day but also engage in environmentally regulated nitrogen fixation, for example at night (68). Similarly, in the context of reproductive division of labor, we predict that reproductive specialists (e.g., an ant queen whose only task is to lay eggs, or a stem cell in a multicellular tissue whose only task is to produce new cells) evolve most easily in environments where the demand for new individuals is relatively insensitive to environmental fluctuations. In contrast, a more balanced distribution of reproductive tasks [e.g., in ant colonies with worker reproduction (6971)] would be more favored in environments that require flexibility in the production of new individuals, for example, due to recurring but unpredictable disturbances in which substantial numbers of individuals are lost from the system.
The optimal fraction of specialists varies across ecological conditions (Fig. 5B). First, when the benefits of collective flexibility outweigh the efficiency gains of specialization, no specialists evolve (s=0), and all individuals are generalists, dividing their attention over both tasks in response to the environment as in the original model (Fig. 5C). Second, in the absence of substantial benefits to collective flexibility, complete division of labor evolves in which half the individuals become task 1 specialists (s=0.5), and the remaining generalists perform only task 2—essentially becoming specialists as well, even though they do not derive an efficiency benefit (Fig. 5E). Finally, in between these two extremes, a compromise between improved efficiency and collective flexibility emerges in which a minority of individuals are specialists (0<s<0.5), and the task they specialize on is also performed by generalists under some environmental conditions (Fig. 5D). Thus, it can be evolutionarily optimal to employ a mix of generalists and specialists, thereby reaping some efficiency benefits of specialization while still being able to adjust to the environment.
While, for simplicity, we have considered specialists that perform only task 1, we can relax this assumption by allowing specialists to also occasionally perform task 2, albeit less frequently than generalists (SI Appendix, Fig. S7). As before, we find that evolving specialists requires the smallest efficiency gains for tasks whose yields are relatively insensitive to environmental conditions. However, in this more general setup, the evolution of specialists depends not only on gained efficiency for task 1 but also on whether and to what extent specialists incur a reduction in efficiency for task 2 as a result of specializing on task 1. Thus, in general, whether specialists for a task can evolve depends on the interplay between how strongly specialists bias their task performance toward it, how sensitive the task is to environmental conditions, and how gains in efficiency for the task trade-off with a loss in efficiency for other tasks (SI Appendix, Fig. S7).

Temporary inactivity can evolve to enhance collective flexibility.

As a final application of our original model, we consider the possibility of inactivity. While we have so far assumed that individuals are continually active, individuals could also be temporarily inactive (i.e., not performing any task). Low levels of inactivity are not necessarily surprising (they could be explained by constraints on activity, e.g., the need to rest), but some systems show perplexingly high levels of inactivity (72, 73). For example, Leptothorax allardycei ants appear to spend most (55%) of their time doing nothing (74). This raises the question of whether temporary inactivity could, in fact, be adaptive, despite inactive individuals not contributing to productivity. Multiple hypotheses have been suggested for why high levels of temporary inactivity could be beneficial (72, 7578). We use our model to explore one such hypothesis, which proposes that inactivity may be adaptive because it increases the system’s flexibility (72, 77). Specifically, temporarily inactive individuals could enhance collective flexibility if they can be more quickly recruited (e.g., due to being more attentive to increased demand for any task) to tasks that require additional attention than individuals that are actively performing other tasks.
We implement inactivity by letting active individuals quit their task at a rate τ, upon which they join an inactive pool. As in our task-switching model, we assume that individuals actively performing the other task are recruited to task i at rate δzi (Fig. 4A), but that inactive individuals are recruited to task i at rate κδzi (SI Appendix, Fig. S8A). Setting κ>1 incorporates the assumption that inactive individuals can be more quickly recruited to a task than active individuals performing a different task. Because individuals switch from being active to being inactive at rate τ and switch from being inactive to active at total rate κδ, each individual spends, on average, a fraction τ/(τ+κδ) of its time inactive. Thus, while the composition of the inactive pool will change over time, its total size (as a fraction of the total number of individuals) stabilizes at τ/(τ+κδ). In response to the environment, the system can adjust what tasks active individuals perform, but not what fraction of individuals are (in)active.
To determine whether inactivity can evolve even though temporarily inactive individuals do not contribute to productivity, we calculate what combination of task quitting rate τ[0,) and z1,A, z1,B[0,1] maximizes fitness. Although task quitting is not required to achieve collective flexibility, we find that having a positive τ (and thereby a pool of temporarily inactive individuals) may indeed be evolutionarily advantageous (SI Appendix, Fig. S8B). Moreover, high levels of inactivity (up to 25% of each individual’s time, in some cases) can evolve, resulting in a correspondingly sizable pool of inactive individuals at any one time (up to 25% of individuals; see SI Appendix, Fig. S8D). Thus, inactivity can indeed evolve to enhance collective flexibility, allowing the system to more rapidly adjust its task allocation to changing circumstances (SI Appendix, Fig. S8 C and E). We expect inactivity to evolve for this reason when collective flexibility is adaptive but not fully realizable due to constraints on the rate at which the system can adjust its task allocation (SI Appendix, Fig. S8 B and D).
These results provide theoretical support for the previously proposed hypothesis that observed worker inactivity in social insects could be a component of an adaptive colony-level task allocation strategy (72, 77). Specifically, they confirm that high levels of inactivity could have evolved to allow colonies to adjust more rapidly what task is being performed by active workers in response to environmental fluctuations, even when the number of active workers stays constant over time. This hypothesis is consistent with empirical evidence from some species of social insects, where temporarily inactive workers have been confirmed to act as a “reserve” labor force [i.e., Temnothorax rugatulus ants (76)], although other explanations might be required for inactivity in other species (61, 7679).

Conclusion

For a collective system that faces a variable environment, flexibility may seem intuitively advantageous. Indeed, if we think of the collective system as an individual in its own right, then this intuition is corroborated by general models for the evolution of phenotypic plasticity, some of which predict that plasticity in labile traits (such as task allocation) should always be favored, at least when not costly (8082). In contrast, our framework predicts that the evolution of collective flexibility should not necessarily be expected: Flexibility in task allocation may be maladaptive, unachievable, or both. This discrepancy in predictions arises because, instead of presupposing that the optimal phenotype is determined solely by the current environment (27, 80, 82), our framework allows the optimal task allocation to emerge dynamically from the interaction between the system and its environment. This more mechanistic approach accounts for the fact that what allocation is optimal depends not only on the environment but also on what tasks have been recently performed, as the system may, at least to some extent, be able to aggregate its task performance over time. We find that the emergent optimal task allocation may end up being much less variable than the environment itself, thereby limiting the potential for the evolution of flexibility. In particular, flexibility is not favored when the environment changes so slowly that task performance cannot be effectively aggregated across environments, or when the environment changes so quickly that the system cannot adjust to it in time. Flexibility may even be so strongly selected against that it becomes optimal to continue to perform tasks under very unfavorable conditions (when their yields are low or even zero).
Whether collective flexibility is selected for, in turn, has ramifications for the internal organization of task allocation. Indeed, whether and to what extent systems may evolve various organizational properties—including task switching, specialization, and inactivity—depends on trade-offs between the potential fitness benefits of collective flexibility and other relevant factors, such as task-switching costs or efficiency benefits to specialization. Through these trade-offs, our framework has the potential to explain substantial variation in the organization of task allocation across ecological conditions and provide theoretical explanations for organizational properties that may, at least at first glance, seem counterintuitive. In Table 1, we summarize some of these properties that have been observed empirically, together with theoretical interpretations that are possible when one takes into account the variability of the environment (and the associated potential benefits of collective flexibility).
Table 1.
 Puzzling empirical observations on task allocation that can potentially be adaptive in the context of a dynamic environment
General observationIllustrative empirical example(s)Possible theoretical interpretation of the general observation
Individuals continue to switch tasks in the absence of environmental changes that necessitate a shift in task allocation.Sponge cells (A. queenslandica) spontaneously transition between different cell types: As part of normal tissue homeostasis, archeocytes can transdifferentiate to become choanocytes and vice versa (52, 54).Frequent task switching may be favored, even when costly, because it facilitates collective flexibility. The incurred costs for “unnecessary” task switching under constant conditions are offset by the benefits of being able to rapidly adjust overall task allocation when environmental conditions do change. (See Costly task switching may evolve to achieve collective flexibility.)
   
Tasks are performed by a mix of generalists and specialists.In A. variabilis cyanobacteria, nitrogen is fixed by specialized heterocysts but also by vegetative cells (68).The mix of generalists and specialists may represent an intermediate optimum that allows the system to derive some efficiency benefits of specialization (by having some specialists perform the task) while still maintaining the ability to flexibly adjust task allocation to a changing environment (by also allocating generalists to the task when needed). (See Environmental variability constrains the evolution of individual specialization.)
In stingless bees (Tetragonisca angustula), nest defense is performed by a mix of specialized soldiers and nonspecialists recruited to guarding tasks (95).
   
Some tasks are performed by specialists, while other tasks are not.During nest construction in Metapolybia wasps, specialists are employed for water foraging but not for other tasks such as building and pulp foraging (96).Even when their potential efficiency benefits of specialization are the same, tasks can nevertheless differ in whether those efficiency benefits are sufficient to offset the costs of sacrificing some flexibility; in particular, larger efficiency benefits are required to specialize on more environment-sensitive tasks. (See Environmental variability constrains the evolution of individual specialization.)
   
Individuals specialize on a task without deriving efficiency benefits.In Temnothorax albipennis ants, specialization and efficiency do not correlate: Workers that spend more of their time on a certain task are not more efficient at it than workers that spend less time on it (64).“Inefficient specialists” may be de facto generalists who spend all (or most) of their time on a particular task to complement specialists for other tasks (which could be favored, for example, because they do derive efficiency benefits). (See Environmental variability constrains the evolution of individual specialization.)
   
Individuals are not performing any task, thereby seemingly compromising system productivity.L. allardycei ants appear to spend most (55%) of their time doing nothing (74). For other examples, see ref. 72 and references therein.If inactive individuals can quickly be recruited to tasks that require additional attention, then having an inactive pool of individuals may be adaptive—even though those individuals do not contribute to productivity—because it enhances collective flexibility: It allows the system to adjust its task allocation more rapidly to changing external circumstances. (See Temporary inactivity can evolve to enhance collective flexibility.)
Each row lists a general empirical observation illustrated with a specific example, and a potential theoretical explanation supported by our framework. The proposed explanations illustrate how considering a system’s dynamic environment can provide potential interpretations of unexplained aspects of its task allocation. Beyond the explanation proposed by our framework, many alternative explanations—including nonadaptive ones—deserve consideration as well.
We propose that the presented framework is sufficiently versatile to be used broadly to study how ecology shapes the evolution of task allocation, and we outline a few directions for future work. First, while our model accounts for environmental variability by having task yields vary temporally, future models could explore additional ecological pressures, such as unpredictable disturbances that affect individuals performing specific tasks (e.g., predator-induced mortality of foragers in social insects) (29, 30, 8386). Second, future work could relax the implicit assumption that the system has perfect information about its environment, in order to explore the implications of noisy information that is potentially asymmetrically distributed across individuals (8790). Finally, we have shown that inactivity could (at least in certain systems) be interpreted as an evolutionary innovation that allows systems to partially escape one of the ecological constraints on task allocation—the limited rate at which task allocation can be adjusted. Why and under what conditions similar innovations could have evolved, such as individuals specialized to quickly detect changes in the environment (e.g., sensory cells in multicellular animals), communication mechanisms to quickly spread information about those changes among individuals [e.g., social interactions in insect colonies (9193)], and storage mechanisms that prevent task stocks from being depleted too quickly [e.g., replete ants that act as living reservoirs (94)], are further questions that are ripe for theoretical analysis in the type of ecologically explicit framework developed here.

Data Availability

There are no data underlying this work.

Acknowledgments

We thank members of the C.E.T. laboratory, members of the Integrated Behavioral Research Group at the Department of Ecology & Evolutionary Biology, and Julien Ayroles for helpful discussions and suggestions.

Supporting Information

Appendix 01 (PDF)

References

1
E. Bonabeau, G. Theraulaz, J.-L. Deneubourg, S. Aron, S. Camazine, Self-organization in social insects. Trends Ecol. Evol. 12, 188–193 (1997).
2
G. E. Robinson, Regulation of division of labor in insect societies. Annu. Rev. Entomol. 37, 637–665 (1992).
3
D. M. Gordon, The organization of work in social insect colonies. Nature 380, 121–124 (1996).
4
E. H. Davidson, How embryos work: A comparative view of diverse modes of cell fate specification. Development 108, 365–389 (1990).
5
D. M. Gordon, The evolution of the algorithms for collective behavior. Cell Syst. 3, 514–520 (2016).
6
D. M. Gordon, Dynamics of task switching in harvester ants. Anim. Behav. 38, 194–204 (1989).
7
D. M. Gordon, The rewards of restraint in the collective regulation of foraging by harvester ant colonies. Nature 498, 91–93 (2013).
8
D. M. Gordon, Ant Encounters: Interaction Networks and Colony Behavior (Princeton University Press, 2010).
9
D. M. Gordon, The ecology of collective behavior in ants. Annu. Rev. Entomol. 64, 35–50 (2019).
10
D. M. Gordon, R. Rosengren, L. Sundström, The allocation of foragers in red wood ants. Ecol. Entomol. 17, 114–120 (1992).
11
B. Bergman, J. R. Gallon, A. N. Rai, L. J. Stal, N2 fixation by non-heterocystous cyanobacteria. FEMS Microbiol. Rev. 19, 139–185 (1997).
12
M. S. H. Griffiths, J. R. Gallon, A. E. Chaplin, The diurnal pattern of dinitrogen fixation by cyanobacteria in situ. New Phytol. 107, 649–657 (1987).
13
V. Rossetti, B. E. Schirrmeister, M. V. Bernasconi, H. C. Bagheri, The evolutionary path to terminal differentiation and division of labor in cyanobacteria. J. Theor. Biol. 262, 23–34 (2010).
14
L. J. Stal, Is the distribution of nitrogen-fixing cyanobacteria in the oceans related to temperature? Environ. Microbiol. 11, 1632–1645 (2009).
15
J. P. Zehr, Nitrogen fixation by marine cyanobacteria. Trends Microbiol. 19, 162–173 (2011).
16
E. Flores, A. Herrero, Compartmentalized function through cell differentiation in filamentous cyanobacteria. Nat. Rev. Microbiol. 8, 39–50 (2010).
17
K. Hammerschmidt, G. Landan, F. Domingues Kümmel Tria, J. Alcorta, T. Dagan, The order of trait emergence in the evolution of cyanobacterial multicellularity. Genome Biol. Evol. 13, evaa249 (2021).
18
K. M. Murphy, B. Stockinger, Effector T cell plasticity: Flexibility in the face of changing circumstances. Nat. Immunol. 11, 674–680 (2010).
19
J. J. O’Shea, W. E. Paul, Mechanisms underlying lineage commitment and plasticity of helper CD4+ T cells. Science 327, 1098–1102 (2010).
20
E. C. Schrom, A. L. Graham, Instructed subsets or agile swarms: How T-helper cells may adaptively counter uncertainty with variability and plasticity. Curr. Opin. Genet. Dev. 47, 75–82 (2017).
21
N. M. Adams, S. Grassmann, J. C. Sun, Clonal expansion of innate and adaptive lymphocytes. Nat. Rev. Immunol. 20, 694–707 (2020).
22
A. Duarte, F. J. Weissing, I. Pen, L. Keller, An evolutionary perspective on self-organized division of labor in social insects. Annu. Rev. Ecol. Evol. Syst. 42, 91–110 (2011).
23
G. F. Oster, E. O. Wilson, Caste and Ecology in the Social Insects (Princeton University Press, 1978).
24
D. M. Gordon, The ecology of collective behavior. PLoS Biol. 12, e1001805 (2014).
25
E. J. T. Middleton, T. Latty, Resilience in social insect infrastructure systems. J. R. Soc. Interface 13, 20151022 (2016).
26
E. Jongepier, S. Foitzik, Fitness costs of worker specialization for ant societies. Proc. Biol. Sci. 283, 20152572 (2016).
27
R. Levins, Evolution in Changing Environments: Some Theoretical Explorations (Princeton University Press, 1968).
28
E. Kussell, S. Leibler, Phenotypic diversity, population growth, and information in fluctuating environments. Science 309, 2075–2078 (2005).
29
M. Waibel, D. Floreano, S. Magnenat, L. Keller, Division of labour and colony efficiency in social insects: Effects of interactions between genetic architecture, colony kin structure and rate of perturbations. Proc. Biol. Sci. 273, 1815–1823 (2006).
30
Y. Iwasa, S. Yamaguchi, Task allocation in a cooperative society: Specialized castes or age-dependent switching among ant workers. Sci. Rep. 10, 3339 (2020).
31
Y. Kang, G. Theraulaz, Dynamical models of task organization in social insect colonies. Bull. Math. Biol. 78, 879–915 (2016).
32
S. N. Beshers, J. H. Fewell, Models of division of labor in social insects. Annu. Rev. Entomol. 46, 413–440 (2001).
33
G. A. Cooper, S. A. West, Division of labour and the evolution of extreme specialization. Nat. Ecol. Evol. 2, 1161–1167 (2018).
34
C. Rueffler, J. Hermisson, G. P. Wagner, Evolution of functional specialization and division of labor. Proc. Natl. Acad. Sci. U.S.A. 109, E326–E335 (2012).
35
J. Y. Wakano, K. Nakata, N. Yamamura, Dynamic model of optimal age polyethism in social insects under stable and fluctuating environments. J. Theor. Biol. 193, 153–165 (1998).
36
D. M. Gordon, Behavioral flexibility and the foraging ecology of seed-eating ants. Am. Nat. 138, 379–411 (1991).
37
M. L. Winston, The Biology of the Honey Bee (Harvard University Press, 1987).
38
T. P. McGlynn, J. P. Owen, Food supplementation alters caste allocation in a natural population of Pheidole flavens, a dimorphic leaf-litter dwelling ant. Insectes Soc. 49, 8–14 (2002).
39
R. Poulin, T. Kamiya, C. Lagrue, Evolution, phylogenetic distribution and functional ecology of division of labour in trematodes. Parasit. Vectors 12, 5 (2019).
40
J. A. Harvey, L. S. Corley, M. R. Strand, Competition induces adaptive shifts in caste ratios of a polyembryonic wasp. Nature 406, 183–186 (2000).
41
L. Passera, E. Roncin, B. Kaufmann, L. Keller, Increased soldier production in ant colonies exposed to intraspecific competition. Nature 379, 630–631 (1996).
42
G. M. Leighton, D. Charbonneau, A. Dornhaus, Task switching is associated with temporal delays in Temnothorax rugatulus ants. Behav. Ecol. 28, 319–327 (2017).
43
H. J. Goldsby, A. Dornhaus, B. Kerr, C. Ofria, Task-switching costs promote the evolution of division of labor and shifts in individuality. Proc. Natl. Acad. Sci. U.S.A. 109, 13686–13691 (2012).
44
H. Hamann, I. Karsai, T. Schmickl, Time delay implies cost on task switching: A model to investigate the efficiency of task partitioning. Bull. Math. Biol. 75, 1181–1206 (2013).
45
A. Duarte, E. Scholtens, F. J. Weissing, Implications of behavioral architecture for the evolution of self-organized division of labor. PLoS Comput. Biol. 8, e1002430 (2012).
46
I. Karsai, J. W. Wenzel, Productivity, individual-level and colony-level flexibility, and organization of work as consequences of colony size. Proc. Natl. Acad. Sci. U.S.A. 95, 8665–8669 (1998).
47
R. L. Jeanne, The organization of work in Polybia occidentalis: Costs and benefits of specialization in a social wasp. Behav. Ecol. Sociobiol. 19, 333–341 (1986).
48
C. Arenas-Mena, The origins of developmental gene regulation. Evol. Dev. 19, 96–107 (2017).
49
A. Sánchez Alvarado, S. Yamanaka, Rethinking differentiation: Stem cells, regeneration, and plasticity. Cell 157, 110–119 (2014).
50
T. C. G. Bosch, Hydra and the evolution of stem cells. BioEssays 31, 478–486 (2009).
51
H. Bode et al., “Transdifferentiation occurs continuously in adult hydra” in Commitment and Instability in Cell Differentiation, A. A. Moscona, A. Monroy, Eds. (Current Topics in Developmental Biology, Academic, 1986), vol. 20, chap. 18, pp. 257–280.
52
S. Sogabe et al., Pluripotency and the origin of animal multicellularity. Nature 570, 519–522 (2019).
53
S. Sogabe, N. Nakanishi, B. M. Degnan, The ontogeny of choanocyte chambers during metamorphosis in the demosponge Amphimedon queenslandica. Evodevo 7, 6 (2016).
54
M. Adamska, “Differentiation and transdifferentiation of sponge cells” in Marine Organisms as Model Systems in Biology and Medicine, M. Kloc, J. Z. Kubiak, Eds. (Results and Problems in Cell Differentiation, Springer International Publishing, 2018) vol. 65, pp. 229–253.
55
A. F. G. Bourke, N. R. Franks, N. R. Franks, Social Evolution in Ants (Princeton University Press, 1995).
56
E. O. Wilson, The origin and evolution of polymorphism in ants. Q. Rev. Biol. 28, 136–156 (1953).
57
P. Calabi, J. F. A. Traniello, Behavioral flexibility in age castes of the ant Pheidole dentata. J. Insect Behav. 2, 663–677 (1989).
58
S. A. West, G. A. Cooper, Division of labour in microorganisms: An evolutionary perspective. Nat. Rev. Microbiol. 14, 716–723 (2016).
59
R. Jeanson, A. Weidenmüller, Interindividual variability in social insects – Proximate causes and ultimate consequences. Biol. Rev. Camb. Philos. Soc. 89, 671–687 (2014).
60
N. Pinter-Wollman, J. Hubler, J. Holley, N. Franks, A. Dornhaus, How is activity distributed among and within tasks in Temnothorax ants? Behav. Ecol. Sociobiol. 66, 1407–1420 (2012).
61
B. R. Johnson, Limited flexibility in the temporal caste system of the honey bee. Behav. Ecol. Sociobiol. 58, 219–226 (2005).
62
C. Anderson, D. W. McShea, Individual versus social complexity, with particular reference to ant colonies. Biol. Rev. Camb. Philos. Soc. 76, 211–237 (2001).
63
S. Powell, N. R. Franks, Caste evolution and ecology: A special worker for novel prey. Proc. Biol. Sci. 272, 2173–2180 (2005).
64
A. Dornhaus, Specialization does not predict individual efficiency in an ant. PLoS Biol. 6, e285 (2008).
65
L. M. Wahl, Evolving the division of labour: Generalists, specialists and task allocation. J. Theor. Biol. 219, 371–388 (2002).
66
F. Ravary, E. Lecoutey, G. Kaminski, N. Châline, P. Jaisson, Individual experience alone can generate lasting division of labor in ants. Curr. Biol. 17, 1308–1312 (2007).
67
L. Chittka, H. Muller, Learning, specialization, efficiency and task allocation in social insects. Commun. Integr. Biol. 2, 151–154 (2009).
68
T. Thiel, E. M. Lyons, J. C. Erker, A. Ernst, A second nitrogenase in vegetative cells of a heterocyst-forming cyanobacterium. Proc. Natl. Acad. Sci. U.S.A. 92, 9358–9362 (1995).
69
A. F. G. Bourke, Worker reproduction in the higher eusocial hymenoptera. Q. Rev. Biol. 63, 291–311 (1988).
70
F. Ravary, P. Jaisson, Absence of individual sterility in thelytokous colonies of the ant Cerapachys biroi Forel (Formicidae, Cerapachyinae). Insectes Soc. 51, 67–73 (2004).
71
C. Peeters, The occurrence of sexual reproduction among ant workers. Biol. J. Linn. Soc. Lond. 44, 141–152 (1991).
72
D. Charbonneau, A. Dornhaus, When doing nothing is something. How task allocation strategies compromise between flexibility, efficiency, and inactive agents. J. Bioeconomics 17, 217–242 (2015).
73
D. Charbonneau, N. Hillis, A. Dornhaus, ‘Lazy’ in nature: Ant colony time budgets show high ‘inactivity’ in the field as well as in the lab. Insectes Soc. 62, 31–35 (2015).
74
B. J. Cole, The social behavior of Leptothorax allardycei (Hymenoptera, Formicidae): Time budgets and the evolution of worker reproduction. Behav. Ecol. Sociobiol. 18, 165–173 (1986).
75
D. Charbonneau, A. Dornhaus, Workers ‘specialized’ on inactivity: Behavioral consistency of inactive workers and their role in task allocation. Behav. Ecol. Sociobiol. 69, 1459–1472 (2015).
76
D. Charbonneau, T. Sasaki, A. Dornhaus, Who needs ‘lazy’ workers? Inactive workers act as a ‘reserve’ labor force replacing active workers, but inactive workers are not replaced when they are removed. PLoS One 12, e0184074 (2017).
77
D. Charbonneau et al., Who are the “lazy” ants? The function of inactivity in social insects and a possible role of constraint: Inactive ants are corpulent and may be young and/or selfish. Integr. Comp. Biol. 57, 649–667 (2017).
78
E. Hasegawa, Y. Ishii, K. Tada, K. Kobayashi, J. Yoshimura, Lazy workers are necessary for long-term sustainability in insect societies. Sci. Rep. 6, 20846 (2016).
79
B. R. Johnson, Reallocation of labor in honeybee colonies during heat stress: The relative roles of task switching and the activation of reserve labor. Behav. Ecol. Sociobiol. 51, 188–196 (2002).
80
R. Lande, Evolution of phenotypic plasticity and environmental tolerance of a labile quantitative character in a fluctuating environment. J. Evol. Biol. 27, 866–875 (2014).
81
S. M. Scheiner, Genetics and evolution of phenotypic plasticity. Annu. Rev. Ecol. Syst. 24, 35–68 (1993).
82
R. Gomulkiewicz, M. Kirkpatrick, Quantitative genetics and the evolution of reaction norms. Evolution 46, 390–411 (1992).
83
C. L. Kwapich, W. R. Tschinkel, Limited flexibility and unusual longevity shape forager allocation in the Florida harvester ant (Pogonomyrmex badius). Behav. Ecol. Sociobiol. 70, 221–235 (2016).
84
C. Rodríguez-Caso, Can cell mortality determine division of labor in tissue organization? J. Theor. Biol. 332, 161–170 (2013).
85
S. Porter, C. D. Jorgensen, Foragers of the harvester ant, Pogonomyrmex owyheei: A disposable caste? Behav. Ecol. Sociobiol., 9 247–256 (1981).
86
J. Pellettieri, A. Sánchez Alvarado, Cell turnover and adult tissue homeostasis: From humans to planarians. Annu. Rev. Genet. 41, 83–105 (2007).
87
S. W. Pacala, D. M. Gordon, H. C. J. Godfray, Effects of social group size on information transfer and task allocation. Evol. Ecol. 10, 127–165 (1996).
88
E. S. Colizzi, R. M. Vroomans, R. M. Merks, Evolution of multicellularity by collective integration of spatial information. eLife 9, e56349 (2020).
89
M. Moussaid, S. Garnier, G. Theraulaz, D. Helbing, Collective information processing and pattern formation in swarms, flocks, and crowds. Top. Cogn. Sci. 1, 469–497 (2009).
90
J. D. Crall et al., Spatial fidelity of workers predicts collective response to disturbance in a social insect. Nat. Commun. 9, 1201 (2018).
91
T. Gernat et al., Automated monitoring of behavior reveals bursty interaction patterns and rapid spreading dynamics in honeybee social networks. Proc. Natl. Acad. Sci. U.S.A. 115, 1433–1438 (2018).
92
S. D. Leonhardt, F. Menzel, V. Nehring, T. Schmitt, Ecology and evolution of communication in social insects. Cell 164, 1277–1287 (2016).
93
S. O’Donnell, S. J. Bulova, Worker connectivity: A review of the design of worker communication systems and their effects on task performance in insect societies. Insectes Soc. 54, 203–210 (2007).
94
B. Hölldobler, E. O. Wilson, The Superorganism: The Beauty, Elegance, and Strangeness of Insect Societies (W. W. Norton, 2009).
95
K. M. Baudier et al., Changing of the guard: Mixed specialization and flexibility in nest defense (Tetragonisca angustula). Behav. Ecol. 30, 1041–1049 (2019).
96
I. Karsai, J. W. Wenzel, Organization and regulation of nest construction behavior in Metapolybia wasps. J. Insect Behav. 13, 111–140 (2000).

Information & Authors

Information

Published in

Go to Proceedings of the National Academy of Sciences
Proceedings of the National Academy of Sciences
Vol. 119 | No. 18
May 3, 2022
PubMed: 35486699

Classifications

Data Availability

There are no data underlying this work.

Submission history

Received: August 31, 2021
Accepted: February 20, 2022
Published online: April 29, 2022
Published in issue: May 3, 2022

Keywords

  1. task allocation
  2. division of labor
  3. task switching
  4. environmental variability
  5. specialization

Acknowledgments

We thank members of the C.E.T. laboratory, members of the Integrated Behavioral Research Group at the Department of Ecology & Evolutionary Biology, and Julien Ayroles for helpful discussions and suggestions.

Notes

This article is a PNAS Direct Submission.
*Not all systems rely on task switching, however. Alternatively, the system may adjust to its environment by adjusting the production of individuals specialized for different tasks (3841).

Authors

Affiliations

Department of Ecology and Evolutionary Biology, Princeton University, Princeton, NJ 08544
Department of Ecology and Evolutionary Biology, Princeton University, Princeton, NJ 08544

Notes

1
To whom correspondence may be addressed. Email: [email protected] or [email protected].
Author contributions: M.S. and C.E.T. designed research; M.S. performed research; M.S. contributed new reagents/analytic tools; M.S. analyzed data; and M.S. and C.E.T. wrote the paper.

Competing Interests

The authors declare no competing interest.

Metrics & Citations

Metrics

Note: The article usage is presented with a three- to four-day delay and will update daily once available. Due to ths delay, usage data will not appear immediately following publication. Citation information is sourced from Crossref Cited-by service.


Citation statements




Altmetrics

Citations

If you have the appropriate software installed, you can download article citation data to the citation manager of your choice. Simply select your manager software from the list below and click Download.

Cited by

    Loading...

    View Options

    View options

    PDF format

    Download this article as a PDF file

    DOWNLOAD PDF

    Login options

    Check if you have access through your login credentials or your institution to get full access on this article.

    Personal login Institutional Login

    Recommend to a librarian

    Recommend PNAS to a Librarian

    Purchase options

    Purchase this article to access the full text.

    Single Article Purchase

    When being flexible matters: Ecological underpinnings for the evolution of collective flexibility and task allocation
    Proceedings of the National Academy of Sciences
    • Vol. 119
    • No. 18

    Media

    Figures

    Tables

    Other

    Share

    Share

    Share article link

    Share on social media