## Abstract

Evolutionary rescue is the process by which a declining population successfully adapts genetically to avoid extinction. In a structured environment that deteriorates patch by patch, dispersal can substantially alter the chances of evolutionary rescue of a wild-type population not viable in deteriorated patches. Here, we investigate the effect of different dispersal schemes and intensities on the probability of successful establishment of a mutant population adapted to the deteriorated environment. We find that the probability of evolutionary rescue can undergo up to three phases when increasing the rate of dispersal: (i) at low dispersal rates, the probability of establishment of a mutant population increases; (ii) then at intermediate dispersal rates the establishment probability decreases; and (iii) at large dispersal rates, the population homogenizes, either promoting or suppressing the process of evolutionary rescue, depending on the fitness difference between the mutant and the wild type. Our results show that habitat choice, when compared to uniform dispersal, impedes successful adaptation when the mutant has the same habitat preference as the wild type, but promotes adaptation when the mutant mainly immigrates into patches where it has a growth advantage over the wild type.

## 1 Introduction

Facing current anthropogenic environmental changes such as deforestation, soil and water contamination or rising temperatures, the populations of many species are declining and might eventually go extinct (Bellard et al., 2012; Diniz-Filho et al., 2019). Pests and pathogens experience similarly strong selective pressures as a result of increased consumption of antibiotics and use of pesticides (Ramsayer et al., 2013; Kreiner et al., 2018). The process of genetic adaptation that saves populations from extinction is termed evolutionary rescue. It is defined as an initial population decline followed by recovery due to the establishment of rescue types, resulting in a U-shaped demographic trajectory over time (Gomulkiewicz and Holt, 1995). In recent years, empirical examples of evolutionary rescue have accumulated (as reviewed by Alexander et al., 2014; Carlson et al., 2014; Bell, 2017). Evolutionary rescue has been observed both in wild populations (e.g. Vander Wal et al., 2012; Di Giallonardo and Holmes, 2015; Gignoux-Wolfsohn et al., 2018) as well as laboratory experiments (e.g. Bell and Gonzalez, 2009; Agashe et al., 2011; Lachapelle and Bell, 2012; Lindsey et al., 2013; Stelkens et al., 2014).

In mathematical models, evolutionary rescue is often studied in a spatially homogeneous situation where the whole population experiences a sudden decrease in habitat quality. In this setting, a large number of theoretical results have been established, for example on the effects of recombination (Uecker and Hermisson, 2016) and horizontal gene transfer (Tazzyman and Bonhoeffer, 2014), reproduction mechanisms (Glémin and Ronfort, 2013; Uecker, 2017), intra- and interspecific competition (Osmond and de Mazancourt, 2013), predation pressure (Osmond et al., 2017), bottlenecks (Martin et al., 2013), different genetic pathways (Osmond et al., 2019), and the context-dependent fitness effects of mutations (Anciaux et al., 2018). In fragmented environments however, habitat deterioration is not necessarily synchronized across patches: there can be a transient spatially heterogeneous environment consisting of old- and new-habitat patches until eventually the whole environment has deteriorated. If individuals that populate different patches are able to move between those, the effect of dispersal on evolutionary rescue needs to be taken into account (Uecker et al., 2014; Tomasini and Peischl, 2019). Experiments that study the effect of dispersal on evolutionary rescue are rare but indicate that even low dispersal rates can significantly increase the likelihood of successful genetic adaptation (Bell and Gonzalez, 2011).

Evolutionary rescue in a situation where one patch after the other deteriorates is tightly linked to the study of adaptation to a heterogeneous environment with source-sink dynamics. These describe a spatially heterogeneous environment that is constant in time where a population in unfavorable habitats can be maintained by constant immigration of the wild type. Experimental and theoretical studies have found that dispersal can have a positive or a negative effect on genetic adaptation in a heterogeneous environment (see e.g. Holt and Gomulkiewicz (1997); Gomulkiewicz et al. (1999) for positive, Storfer and Sih (1998); García-Ramos and Kirkpatrick (1997); Kirkpatrick and Barton (1997); Fedorka et al. (2012) for negative, and Kawecki (2000); Gallet et al. (2018) for both effects).

In theoretical studies of local adaptation and evolutionary rescue, dispersal is typically assumed to be random, i.e. dispersing individuals are distributed uniformly among patches. Only few deterministic investigations in the context of local adaptation in source-sink systems have taken into account non-random dispersal patterns (e.g. Kawecki, 1995; Holt, 1996; Kawecki and Holt, 2002; Amarasekare, 2004). This analytical focus on random dispersal is in stark contrast to actually observed dispersal schemes in nature (Edelaar et al., 2008; Clobert et al., 2009; Edelaar and Bolnick, 2012). Here, we explore and compare the effects of several biologically motivated dispersal schemes on adaptation and evolutionary rescue in a stochastic framework.

One of the best documented modes of non-random dispersal is density-dependent dispersal. Density dependence can be positive or negative: either individuals prefer to settle or stay in large groups (positive density-dependence), or they choose to remain in or move to less populated regions (negative density-dependence). Density-dependent dispersal, of either form, is ubiquitously found in nature and has been reported in many species across the tree of life, including insects (Endriss et al., 2019), spiders (De Meester and Bonte, 2010), amphibians (Gautier et al., 2006), birds (Wilson et al., 2017), fishes (Turgeon and Kramer, 2012), and mammals (Støen et al., 2006).

Another well-established dispersal scheme is habitat choice, whereby individuals tend to immigrate into habitats they are best adapted to. This mechanism has for example been reported in lizards (Bestion et al., 2015), birds (Dreiss et al., 2011; Benkman, 2017), fishes (Bolnick et al., 2009), worms (Mathieu et al., 2010), and ciliates (Jacob et al., 2017, 2018).

Here, we concentrate on non-random dispersal effects of the immigration process. Yet, we keep in mind that density-dependence or habitat choice can also affect the emigration behavior, i.e. the likelihood for an individual to leave its current location, or even the vagrant stage when the individual is in the process of dispersal (Bowler and Benton, 2005; Ronce, 2007).

In the following, we explicitly account for these non-random dispersal schemes in the context of genetic adaptation to a deteriorating and spatially structured environment. We model an environment that consists of various patches with one of two possible habitats: the ‘old’ habitat, in which both wild types and mutants are viable, and the ‘new’ habitat, where in the absence of immigration the wild-type population will eventually go extinct. In this framework, we study four biologically motivated dispersal patterns and compare them to the random dispersal scheme. We start by investigating their consequences for the establishment dynamics of an adapted mutant in a time-constant heterogeneous environment. From there, we derive an approximation for adaptation in a source-sink setting. Using these results, we study the probability of evolutionary rescue, i.e. of adaptation in the scenario where patches, one after the other, deteriorate over time until all locations contain the new habitat. We find that dispersal bias has a direct effect on the local growth rates which in turn affect the probability of establishment and evolutionary rescue.

## 2 Model

We consider a spatially structured environment consisting of *M* patches all connected to each other. The habitat of a patch is either in the *old* or in the *new* state, corresponding to habitat quality before and after environmental deterioration, respectively. The transition from the old to the new habitat is assumed to be irreversible. Patches are populated by two types of asexually reproducing, haploid individuals, either wild type or mutant. Generations are discrete and non-overlapping generations (Wright-Fisher process). Wild type and mutant populations can each be maintained at carrying capacity in old-habitat patches; the mutant has a lower growth rate there. In new-habitat patches, the wild type population declines locally while the mutant has a positive growth rate – we will therefore call it a ‘rescue mutant’.

We consider a time-varying environment, such that one after the other every *τ* generations, the habitat of a patch deteriorates (from old to new state). Initially (*t* < 0), all patches are of the old-habitat type. At time *t* = 0, the first patch deteriorates. After (*M* − 1)*τ* generations, all patches are of the new-habitat type. We denote the time-dependent frequency of old-habitat patches by *f*_{old}. It equals 1 before the first environmental change takes place (*t* < 0), and decreases by 1/*M* after each environmental deterioration event until it eventually hits 0, when all patches have undergone the environmental change. This environmental setting corresponds to the one analyzed by Uecker et al. (2014) and more recently in the special case of just two patches by Tomasini and Peischl (2019).

The individuals are assumed to go through the following life-cycle: (i) Dispersal: individuals may move between patches; (ii) Reproduction: individuals reproduce within patches (the amount of offspring that is produced depends on the parent’s type and its current location); (iii) Mutation: wild-type individuals mutate to the rescue mutant type with probability *θ* – back mutations from the mutant to the wild type are neglected; (iv) Regulation: the population size is (down)regulated to the carrying capacity *K*, if necessary. If the population size is below the carrying capacity, the regulation step is ignored.

### 2.1 Old-habitat dynamics

We assume that in old-habitat patches, both types are able to maintain the population at carrying capacity *K*. Thus, independently of population composition in these patches, the carrying capacity is always reached after reproduction. We denote the fecundities of the **w**ild-type and the **m**utant by *ω*_{w} and *ω*_{m}, respectively. We impose an adaptation trade-off for the rescue mutant, i.e. the mutant is less fit than the wild type in old-habitat patches (*ω*_{m} < *ω*_{w}). In the following, we choose offspring numbers *ω*_{i} large enough so that the reproduction, mutation and regulation events are well approximated by a Wright-Fisher process, a binomial sampling with size *K* and success probability *p*_{m},
where the random variable denotes the population sizes of type *i* (mutant or wild-type) in patches with habitat *k* (old or new) after the dispersal step, and *θ* is the mutation probability (wild-type individuals turning into mutants). Later on in the mathematical analysis, we approximate the binomial distribution by a Poisson distribution, which is reasonable for low mutant numbers, large wild-type numbers and a small mutation probability *θ* (of order 1/*K*). The rate of this Poisson distribution is given by
Setting and neglecting mutations (*θ* = 0), we define the local growth rate of a single mutant by

This is the average offspring number of one mutant individual after a completed life cycle. While still rare, mutant individuals will reproduce independently of each other and their dynamics will be described by the local growth rate given in eq. (3). The fecundity of mutant individuals in old-habitat patches is assumed to be lower than that of wild-type individuals, i.e. *ω*_{m}< *ω*_{w}. Still, the mutant’s local growth rate, given by eq. (3), can be larger than one (*s*_{old} >0). This happens when the wild-type population in old habitats, , becomes very small, which again depends strongly on the dispersal scheme and rate.

### 2.2 New habitat dynamics

In the new habitat and in the absence of immigration, the wild-type population will go extinct. To account for this, we assume that the number of wild-type offspring in new-habitat patches is a Poisson distributed value with parameter (1 − *r*), where *r* measures how strongly the wild type is affected by the environmental deterioration. For *r* = 1 the wild-type population becomes locally extinct in new-habitat patches after one generation.

The mutant type, in contrast, has a local growth rate larger than one and will (in expectation) grow in numbers. Again, the number of offspring is Poisson distributed with per-capita rate (1 + *s*_{new}), the local growth rate of the mutant in new-habitat patches.

Since we are interested in the dynamics when the mutant is rare, we do not explicitly consider density regulation in these patches in our calculations.

### 2.3 Dispersal mechanisms

We assume that dispersal is cost-free, i.e. all emigrating individuals will settle in a patch, leaving the global population size before and after dispersal unchanged. We split the dispersal step into emigration and immigration. We focus on habitat choice during immigration, i.e. individuals have a bias to immigrate into patches of a certain habitat type. The bias of immigration into new-habitat patches is set equal to one, without loss of generality. The bias of immigration into an old-habitat patch is denoted by *π*_{i}, with the index *i* indicating the wild-type (*w*) or mutant (m) bias. For *π*_{i} < 1, individuals of type *i* are more likely to settle in new-habitat patches, while for *π*_{i} > 1 the reverse is true. For *π*_{i} = 1, individuals do not have a preference and dispersal is random.

We consider equal and constant emigration rates for both types and habitats throughout the manuscript. We denote the probability for an individual to leave its natal patch by *m*. Then, the probability for an individual of type *i* born in the old habitat to disperse to the new habitat is given by
where denotes the probability for a type *i* individual to remain in an old-habitat patch (or to emigrate and re-immigrate into an old-habitat patch), and *f*_{old} is the frequency of old-habitat patches. The rates for dispersal from new patches are given analogously.

From a biological perspective, there are a number of dispersal schemes that are of particular interest. Precisely, we distinguish between the following five scenarios (see also Figure 1 for an overview):

**Absolute habitat choice (ABS):**Individuals prefer to immigrate into the habitat where they have the largest number of offspring before regulation. In our model this translates to both*π*_{w}and*π*_{m}being larger than 1, i.e. there is a bias towards old-habitat patches. In practice, individuals are thought to use biotic or abiotic cues to preferentially immigrate into habitats where their fecundity is highest when compared to other habitats. This type of dispersal, i.e. matching habitat choice, has for example been observed with common lizards*Zootoca vivipara*(Bestion et al., 2015), three-spine sticklebacks*Gasterosteus aculeatus*(Bolnick et al., 2009), and barn owls*Tyto alba*(Dreiss et al., 2011).The same range of parameters (

*π*_{w}< 1,*π*_{m}< 1) is obtained when implementing positive density-dependent dispersal. In this dispersal scheme, individuals are more likely to immigrate into patches with higher population densities, so both the wild type and the mutant will prefer the old habitat where the carrying capacity is always reached. Highly populated locations can be an indication for a safe shelter, relevant for prey species, and potentially increase the mating success of individuals. This type of positive density-dependent dispersal (also called conspecific attraction) on immigration is for example found in several amphibians, e.g. the salamander species*Mertensiella luschani*(Gautier et al., 2006) and*Ambystoma maculatum*(Greene et al., 2016) or the frogs*Oophaga pumilio*(Folt et al., 2018).**Relative habitat choice (REL):**Under this dispersal scheme, individuals tend to immigrate to habitats where they are fitter than the other type. This translates into the wild type preferring old patches, i.e.*π*_{w}> 1, while mutants tend to immigrate more often to new habitats, i.e.*π*_{m}< 1. Empirical evidence of this mechanism is scarce. It resembles the recently observed dispersal patterns of the ciliates*Tetrahymena thermophila*with a specialist and generalist type (Jacob et al., 2018). The specialist disperses to its preferred habitat while the generalist prefers to immigrate to a suboptimal habitat where it outcompetes the specialist.**Negative density-dependent dispersal (DENS):**Here, we focus on negative density-dependent dispersal, i.e. individuals are more likely to move to less populated patches. In these locations, resources might be more abundant, intra-specific competition alleviated and the chance of infection transmission decreased, which may compensate for the potentially reduced habitat quality. The corresponding parameter choice in our model is*π*_{w}< 1,*π*_{m}< 1, i.e. both types have a higher likelihood to immigrate to new-habitat patches, which are less populated during the relevant phase of rescue. The mutant being initially rare, it is unlikely that the carrying capacity is reached in these patches – as assumed throughout the analysis. Various empirical examples of negative density-dependent dispersal exist. Density-dependent immigration effects as described here, are for example found in the damselfish species*Stegastes adustus*(Turgeon and Kramer, 2012) and the migratory birds*Setophaga ruticilla*(Wilson et al., 2017). In both species, immigrants fill the empty space left by dead or emigrated individuals. Notably, in the fish species, negative density-dependent immigration is further enhanced by residents defending their territory against potential immigrants.**Maladaptive dispersal (MAL):**For completeness, we also consider the scenario in which both types disperse preferentially into the habitat they are relatively less fit in (at least initially), i.e. we have*π*_{w}< 1 and*π*_{m}> 1. This dispersal scheme is similar to the concept of an ‘ecological trap’: Individuals tend to immigrate into patches that cannot sustain a population, in its most extreme form resulting in the extinction of the species (Battin, 2004). This does not exactly apply to our framework since here the mutant is able to maintain a population in old-habitat patches, hence our choice of the term ‘maladaptive dispersal’.**Random dispersal (RAND):**Individuals do not have a bias towards any of the two habitats,*π*_{w}= 1,*π*_{m}= 1. Most theoretical results examining the interplay of dispersal and establishment have been using this dispersal scheme. Therefore, we use it as a bench-mark to which we compare the above defined dispersal patterns.

All the model parameters are summarized in Table 1 along with the default parameter values and ranges. If not stated otherwise, the default parameter values are used for the stochastic simulations.

### 2.4 Simulations

The algorithm implements the life cycle described above. First, a random number of dispersing individuals is drawn from a binomial distribution with success probability *m* and sample size equal to the local population size. The dispersing individuals are distributed according to one of the studied dispersal patterns. Then reproduction happens locally. In old-habitat patches, the number of mutant offspring is drawn from a binomial distribution with sample size *K* and parameter *p*_{m} as given in eq. (1). By doing so, reproduction, mutation and regulation are all merged in this single step. In new-habitat patches, reproduction is simulated by drawing a Poisson distributed number for both types according to the corresponding mean offspring numbers, 1 − *r* for the wild type and 1 + *s*_{new} for the mutant. Then mutation of wild-type individuals takes place with rate *θ*, implemented using a binomial distribution. Lastly, if necessary, new-habitat patches are down-regulated back to carrying capacity using a hypergeometric distribution.

In Figures 2-4, we simulate a heterogeneous environment that is constant in time, i.e. no patches deteriorate. Initial population sizes are *K* wild-type individuals in old-habitat patches, and the stationary wild-type population size in new-habitat patches (see Section S1 in the Supplementary Information (SI) for details). Figure 2 is started with initially one mutant either in an old- or new-habitat patch and the corresponding wild-type population size is reduced by one; in this figure, the mutation probability is set to zero. In all the other figures, mutants solely arise due to mutations. We stop the simulations when the total number of mutants in all new-habitat patches exceeds 0.8 × *K* × *M* (1 − *f*_{old}) (except in the case of absolute habitat choice and dispersal rates larger than 0.2, since then most individuals settle in old-habitat patches; in this case the condition is adapted to the mutant number exceeding 80% of the total population in old-habitat patches), or, in Figure 2 where there is no mutation, if the mutant has gone extinct.

In the rescue scenario, where one patch after the other deteriorates (Figures 5 and 6), we initialize all patches with *K* wild-type individuals. Simulations are run until either the population has gone extinct or the (global) mutant population size exceeds 0.8 × *K* × *M* after the last deterioration event has happened. Unless stated otherwise, the simulation results are averages of 10^{5} independent runs. All simulations are written in the C++ programming language and use the *Gnu Scientific Library*. The codes and data to generate the figures are deposited on Gitlab (https://gitlab.com/pczuppon/evolutionary_rescue_and_dispersal).

## 3 Results

We investigate the effect of the different dispersal schemes on the probability of successful adaptation and evolutionary rescue. We first compute the *establishment probability* of a single mutant individual arising either in an old- or in a new-habitat patch. We then link this probability to the dynamics of a source-sink system, i.e. a fixed environment with a certain number of old habitats (sources) and new-habitat patches (sinks). We derive an expression for the probability of a mutation to emerge and establish in a given time interval. We call this second quantity the *probability of adaptation*. Lastly, we study the time-varying scenario where patches, one after the other, deteriorate. We consider a third quantity, the *probability of evolutionary rescue*, which corresponds to the probability that a mutant appears by mutation and establishes in the new environment where all patches have deteriorated. The theoretical results are complemented by stochastic simulations that support our predictions and help visualize the differences between the different dispersal schemes.

### 3.1 Establishment probability in a heterogeneous environment

We derive the probability of establishment of a mutant population starting with a single individual initially located either in an old- or a new-habitat patch. In this analysis, we ignore further mutations and are only concerned with the fate of this single mutant lineage. The dynamics of the mutant population can be described by a two-type branching process, i.e. all mutant individuals, descendants of the initial mutant, evolve independently of each other. This is a reasonable assumption as long as the overall number of mutants is a lot smaller than the population size of the wild type. The two “types” of the two-type branching process correspond to the two habitat types (old and new). The process tracks the numbers of old-habitat and new-habitat mutants, with *k* denoting the habitat type (old or new). The number of offspring of a single mutant can be approximated by Poisson distributed numbers (see eqs. (2) and (3)). The mean number of offspring of a single mutant, either in an old- or a new-habitat patch, is then given by the following mean reproduction matrix:
where the rows denote the parent locations, and the columns the patch type of the offspring. For example, the top-left entry reads as the probability for the parent to stay in an old-habitat patch times the average number of offspring in these patches, given by the mean of the corresponding Poisson distribution with rate (1+*s*_{old}), cf. eq. (3). The other entries are obtained analogously.

The survival probability of this multi-type branching process, *φ _{k}* with

*k*indicating the initial habitat type of the mutant, is then given by the unique positive solution of the following system of equations (see Haccou et al., 2005, Chapters 5.3 and 5.6)

Intuitively the left hand side, the extinction probability, equals the sum over all possible scenarios of the trajectories towards extinction, e.g. the initial individual having *j* offspring in a patch of type *k*, old or new, and all of these *j* offspring becoming extinct ((1 − *φ*_{k})^{j}). Unfortunately, a general analytical solution to these equations is not accessible, but the equations can be solved numerically. For weak selection and (potentially) weak dispersal – i.e. *s*_{old}, *s*_{new}, *m* « 1 needs to hold for at least two of the three parameters – an approximation is available: see for example Haccou et al. (2005, Theorem 5.6) for the general theory and Tomasini and Peischl (2018) for an application in a similar setting. The detailed derivation is presented in the SI, Section S2. We find
where *C* is a scaling constant given by

The first term in the approximation of the establishment probabilities (*φ*_{old} and *φ*_{new}) in eq. (7) describes the local growth depending on the habitat type under study. The second term captures the growth rate differences between the two habitat types.The factor (1− *f*_{old} +*π _{m} f*

_{old}) accounts for the biased dispersal patterns (when

*π*

_{m}/= 1)). The third term in the equations corresponds to the direct effect of dispersal on the establishment probability. The first two summands in the bracket are the same for both establishment probabilities. They represent the general effect of dispersal due to the dynamics from new-habitat patches (first summand) and old-habitat patches (second summand). The dispersal bias induced by

*π*

_{m}changes the relative impact of old-vs. new-habitat patches. Finally, the last summand in the bracket measures the growth rate loss (or gain) due to dispersal to the other patch type. It therefore differs between the two approximations.

Note that in these equations, the competition of the mutant with the wild-type in the old-habitat patches appears in the local growth rate *s*_{old}, defined in eq. (2). This quantity is not constant, but instead depends on the wild type population size in old-habitat patches, which itself depends on the wild type’s dispersal and growth rate in both habitats.

If the emigration probability is zero (*m* = 0), the subpopulations in each habitat evolve in isolation from each other and we recover Haldane’s classical result for the establishment probability of a slightly advantageous mutant: *φ*_{new} = 2*s*_{new} (Haldane, 1927). Furthermore, in the case of random dispersal (*π*_{w} = *π*_{m} = 1) and for equal number of old- and new-habitat patches (*f*_{old} = 1/2), we obtain the approximation found in Tomasini and Peischl (2018) (compare system (7) to their eqs. (4) and (5)). Note that the approximation is independent of the actual number of patches, but only depends on the environmental configuration determined by the frequency of old-habitat patches *f*_{old}.

### Comparison to simulations and qualitative behavior

We compare in Figure 2 our predictions from eqs. (6) and (7) to simulation results for different values of the emigration rate *m*. We find good agreement with the numerical solution of eq. (6) (solid lines), which justifies our assumption of Poisson reproduction. The approximation given in eq. (7) (dashed lines) deviates slightly from the simulation results in regions where *m*, *s*_{new} and *s*_{old} are not small, i.e. when the assumptions made in the analytical derivation do not hold anymore.

The qualitative dependence of the establishment probabilities *φ*_{old} and *φ*_{new} on the dispersal probability *m* is similar for all dispersal schemes. The shape of the curve however strongly depends on the fecundity *ω*_{m} of mutants in the old habitat. Before discussing the differences between the dispersal schemes, we first provide a qualitative understanding of this general behavior.

For the probability of establishment of a single mutant in an old-habitat patch (*φ*_{old}), we observe up to three different regions, cf. Figure 2(a). This is in line with previous observations in the context of local adaptation (e.g. Kawecki, 1995; Tomasini and Peischl, 2018) and evolutionary rescue (Uecker et al., 2014). We define the regions as follows: (i) an initial increase of the establishment probability at low dispersal rates *m*; (ii) a local maximum with a subsequent decrease of the establishment probability; (iii) an increase of the establishment probability for high dispersal rates.

A detailed assessment and explanation of the regions is provided in the SI, Section S2.1. Briefly, in region (i), the prevalent effect is the dispersal of mutants from old-to new-habitat patches where they are fitter than the wild type, thus increasing the establishment probability. This effect is mediated through the third term of the establishment probability in eq. (7). Region (ii), beginning with the local maximum, is a result of two counteracting processes: increased emigration of individuals from the old habitat and larger amounts of mutant individuals that, once emigrated to a new habitat, reimmigrate into an old-habitat patch. If we increase the emigration probabilities, more individuals will emigrate out of old-habitat patches, lowering competitive pressure in old-habitat patches. As a result, local growth rates of the mutant in old-habitat patches, *s*_{old} are higher. This effect was termed ‘relaxed competition’ by Uecker et al. (2014). Higher dispersal rates however also have a negative effect on mutant establishment, by lowering the number of mutants in new-habitat patches through back-migration. Depending on whether the effect of back-immigration is stronger than the effect of relaxed competition, the establishment probability either has a local maximum or not, compare 2(a) and (c). Finally, in region (iii), dispersal is so large that the population is close to being well-mixed. This results in less competitive pressure in old-habitat patches so that the local growth rate of the mutant in these patches, *s*_{old} (first term in eq. (7)), becomes positive.

The width of region (ii) strongly depends on the fecundity of the mutant in the old habitat, *ω*_{m}. If *ω*_{m} is high, the local growth rate of the mutant *s*_{old} starts to increase at a lower dispersal rate (see Figure S1). This can make region (ii) disappear, as visible in Figure 2(c). On the other hand, for low mutant fecundity values *ω*_{m}, region (iii) might vanish (see Figure S2). There, the mutant is strongly disadvantageous in old-habitat patches when compared to the wild type, and the wild-type population will always outcompete the mutants due to the much higher offspring numbers.

We analyze the qualitative behavior of the establishment probability of a mutant emerging in the new habitat, *φ*_{new} in a similar way (Figures 2(b,d)). The establishment probability *φ*_{new} decreases at low dispersal rates: Since we let the mutant start in a new-habitat patch, where it fares better than the wild type, there is no initial benefit due to dispersal (the third term in eq. (7) is negative for *φ*_{new}). The interpretation of region (ii), describing the trajectory for intermediate emigration rates *m*, is the same as for *φ*_{old} above. For large emigration rates *m*, region (iii), the resulting establishment probability is a combination of the local growth rate and the dispersal effect, the first and third terms in eq. (7). This is because the mutant can migrate to old-habitat patches, where it will enjoy relaxed competition.

#### Comparison of dispersal schemes

We now turn to the discussion of how the establishment probabilities compare for the various dispersal schemes. We consistently observe that negative density-dependent dispersal (green curves and downward triangles in Figure 2) enhances establishment when compared to the random dispersal scheme (black curves and circles). This can be attributed to two reasons: (1) the mutant is more likely to disperse to the new habitat where it outcompetes the wild type (stronger weighting of new-habitat patches in the third term in eq. (7)); and (2) since the wild type prefers to settle in new-habitat patches (*π*_{w} < 1), individuals in old-habitat patches experience relaxed competition for lower dispersal rates *m*, thus increasing the local growth rate *s*_{old}, i.e. region (iii) is shifted to the left. An analogous (but reversed) argument explains why absolute habitat choice (blue curves and upward triangles in Figure 2) is always lower than the random dispersal scheme (black curves and circles).

The effect of relative habitat choice (orange curves and squares in Figure 2), where each type has a bias to move to the habitat where it is relatively fitter than the other type, is more involved. We disentangle the effects separately for each region. In region (i) at low emigration probabilities, the curve is almost identical to that of the negative density-dependent pattern. The mutant preference of these two dispersal modes is the same. The movement of the rare mutants is the prevailing force in this parameter regime, which explains the alignment of the green (negative density-dependent dispersal) and the orange curves. For intermediate dispersal rates, region (ii), the effect of the heterogeneous environment (second term in eq. (7)) becomes stronger, i.e. the local growth rate *s*_{old} increases because of relaxed competition in old-habitat patches. For relative habitat choice, the wild type is more likely to re-immigrate into old-habitat patches and thereby increases the population size in these locations. This reduces the effect of relaxed competition. Therefore, the orange line now drops below the green curve and even starts to decrease (Figure 2(a)). For high emigration probabilities *m*, region (iii), the competitive pressure in old-habitat patches relaxes. Again, this region is dominated by the movement of wild-type individuals. In the random dispersal scheme (black), the wild type has a lower likelihood to be in old-habitat patches than with the relative habitat choice scheme (orange), thus the black curve is above the orange curve. For very large dispersal rates, also the absolute habitat choice scheme (blue curve) can lead to higher values of *φ*_{old}than relative habitat choice (orange), cf. Figure 2(c). In this parameter regime, the mutant has a larger growth rate in old-than in the new-habitat patches (*s*_{old} > *s*_{new}). Therefore, it is beneficial for the mutant to stay or to re-immigrate into old-habitat patches.

Finally, for the maladaptive dispersal scheme (purple curves and diamonds in Figure 2) we see that for low dispersal rates *m* the results match those obtained under the absolute dispersal scheme. The mutant preferences being the same, this again shows that this region is dominated by the mutant’s dispersal behavior. For intermediate to large dispersal rates though, the maladaptive dispersal scheme results in large establishment probabilities. This is explained by the effect of strongly relaxed competition (wild-type individuals preferentially move into the new habitat) and the bias of mutants to disperse into old-habitat patches where their number of offspring individuals is now very large. Overall, this results in the highest establishment probabilities of all dispersal schemes. We note though that the term ‘maladaptive dispersal’ might be misleading for large dispersal values, since here the growth rate of the mutant in old-habitat patches, *s*_{old}, is actually larger than the growth rate in new-habitat patches, *s*_{new}.

### 3.2 Probability of adaptation in a heterogeneous environment

We now study the probability of adaptation when mutations occur recurrently. As in the previous section, we consider a heterogeneous environment with a fixed number of old- and new-habitat patches. This is effectively a source-sink system (Holt, 1985; Pulliam, 1988), where old- and new-habitat patches correspond to sources and sinks for the wild type, respectively. In the previous section, we initialized the system with one mutant in either an old- or a new-habitat patch and computed the establishment probability. Now, we let mutants appear randomly within a certain time frame. The last time point at which a mutation can occur is denoted by *t*_{fin}. Later, in the analysis of the probability for evolutionary rescue, this time will be replaced by the time between two consecutive patch deterioration events, *τ*. For now we will set this value arbitrarily to 100 and initialize the system with a fixed number of old-habitat patches.

The probability of adaptation in this setting, *P*_{adapt}, is given by

In words, the right-hand side is one minus the probability of no mutant establishing within the [0, *t*_{fin}] time interval. More precisely, the exponential is the probability of zero successes of a Poisson distribution. The rate of this Poisson distribution is given by the expected number of successfully emerging mutant lineages until time *t*_{fin}. For *t*_{fin} tending to infinity, there will almost surely be a successful mutant so that *P*_{adapt} = 1. For finite values of *t*_{fin}, the average number of mutations that appear until that time is given by the product of the mutation probability *θ*, the length of the time window of interest *t*_{fin}, the number of patches *M* and the stationary number of wild-type individuals present in the different habitats, that is *K* and for old- and new-habitat patches, respectively (cf. SI eq. (S5)). Once such a mutant appears, it then has the previously computed establishment probability *φ _{k}* to establish, depending on the patch type

*k*(old or new) it arises in. This explains the factor

*φ*in the exponential.

_{k}We compare in Figure 3 our predictions to simulation results. The shape of the probability of adaptation as function of the emigration probability *m* depends on the fecundity of the mutant in old-habitat patches, *ω*_{m} (Figures 3(a,c)). This is similar to the behavior of the establishment probability *φ*_{old} in Figure 2. Likewise, the qualitative effects of the different dispersal schemes are comparable to the ones observed for the establishment probability.

In subfigures (b) and (d), we vary the frequency of old-habitat patches *f*_{old}. We observe a maximum which is the result of two effects: (1) the likelihood for a mutation to appear increases with the number of wild-type individuals present in the system, which is highest for high frequencies of old-habitat patches *f*_{old}, and (2) the probability of establishment of a mutant decreases with the number of old-habitat patches.

The different dispersal schemes alter both effects. Negative density-dependent dispersal (green), when compared to random dispersal (black), always shifts the maximum to higher frequencies of old habitats while also increasing its quantitative value. Under negative density-dependent dispersal, mutant and wild-type individuals prefer settling in new-habitat patches (*π*_{w}, *π*_{m} < 1). As a result, the local population before reproduction in these patches is increased, so that the overall population size is higher compared to the other dispersal schemes.

There is therefore a higher number of mutants generated under this scheme. Additionally, the probability of establishment is also increased for negative density-dependent dispersal, further increasing the probability of adaptation (see also the discussion around Figure 2). Again, a reversed argument explains why absolute habitat choice (blue) always yields lower probabilities of adaptation than random dispersal.

### 3.3 Habitat of origin of the adaptive mutation

We now identify the habitat type where the successful mutation arises. The established mutant population can arise from a mutant that is born in an old- or in a new-habitat patch, but can also be traced back to two (or more) mutant individuals, one from either patch type. For example, the approximation for the probability to observe a mutant population that can be traced back to a mutant from an old-habitat patch is the following

The corresponding probabilities for the other two scenarios can be computed analogously.

In Figure 4 we compare simulation results with our predictions for the origin of a successful mutant when varying the old habitat frequency *f*_{old}. Surprisingly, even for a relatively strong fecundity disadvantage of the mutant in the old habitat, i.e. *ω*_{m} is 10% smaller than *ω _{w}*, we find that most successful mutations arise in old-habitat patches (subfigure 4(a)). Decreasing the fecundity disadvantage of the mutant by increasing its fecundity

*ω*

_{m}further increases the number of successful mutant lineages from old-habitat patches (subfigure 4(b)). If we instead increase the fecundity difference in old habitats by decreasing

*ω*

_{m}, we observe the opposite, i.e. eventually the probability for a successful mutation to arise in new-habitat patches becomes largest (see Figure S3 in SI).

### 3.4 Evolutionary rescue

Finally, we consider a time-inhomogeneous environment where patches deteriorate one after the other at regular time intervals *τ*, until all patches have switched to the new habitat. If the wild-type population fails to generate a successful mutant, the population will unevitably go extinct. The probability of evolutionary rescue is therefore tightly linked to the probabilities of adaptation and establishment that we have computed in eqs. (7) and (9). Typically, in formulas expressing the probability of evolutionary rescue, one splits the contributions into mutations arising *de-novo* and evolutionary rescue due to standing genetic variation, i.e. mutations that are present in the population before the environmental change (Alexander et al., 2014). We will discuss the effect of standing genetic variation in our system in the following section. For now, we focus on evolutionary rescue due to de-novo mutations. We approximate the probability for evolutionary rescue, denoted by *P*_{rescue}, as
where *f*_{old}(*i*) = (*M* − *i*)/*M* is the frequency of old-habitat patches after the *i* −th deterioration event and denotes the overall number of wild-type individuals living in habitat *k* (old or new) in generation *j*. The intuition for the form of this equation is the same as for eq. (9). The only difference is that we now need to account for a changing environment, which alters the population sizes, , and the establishment probabilities *φ _{k}*. In the formula, these changes are accounted for by the sums that iterate through the (discrete) time steps and by the time dependence of the corresponding quantities. We further note that we follow the wild-type population size deterministically over time, instead of assuming it to be already in its steady state as in eq. (9).

As visible in Figure 5, the approximation matches the qualitative pattern of the simulation results, i.e. the ranking and intersection of the dispersal schemes. Yet, it does not accurately predict the simulated data. This discrepancy can be explained as follows: in the formula we assume a constant establishment probability between two deterioration events. However, mutants that arise very shortly before a deterioration event just need to survive until this event happens and are thus carried over to the following environmental configuration with a higher probability than predicted by our formula. This explains why the real rescue probability is higher than our approximation, which ignores these “left-over” mutants present prior to the deterioration event. As a result, instead of assuming a constant establishment probability between two deterioration events, we should rather use a time-dependent establishment probability – which can however not be approximated in our general framework (but see Uecker et al. (2014) where scenarios with an accessible time-dependent solution are studied).

Comparing the different dispersal schemes with each other, we see substantial differences. The dispersal schemes affect the dispersal pattern of both types and as such alter their respective population dynamics. Both small and large fecundity differences in the old habitat, *ω*_{m} = 9.9 and *ω*_{m} = 9, conserve the pattern of rankings of dispersal schemes obtained for the probabilities of establishment and adaptation: from highest to lowest we have negative density-dependent (green), random dispersal (black), absolute habitat choice (blue) and interversion of relative habitat choice (orange) and maladaptive dispersal (purple), cf. Figure 5(a,b). Based on our discussion of the same behavior in Figure 2(a,c), this indicates that the most influential factor in these parameter sets is the growth rate of the mutant in old-habitat patches, *s*_{old}.

For very large fecundity differences in the old habitat (*ω*_{m} = 3 and *ω*_{m} = 0), the hierarchy of dispersal schemes is the same for all emigration probabilities without any changes in ranking; from highest to lowest, we find negative density-dependent dispersal, relative habitat choice, random dispersal, maladaptive dispersal, and absolute habitat choice (cf. Figure 5(c,d)). In this parameter setting, the probability of evolutionary rescue is dominated by the dispersal behavior of the mutant. Since the mutant is barely viable in old-habitat patches, it is always preferential for it to disperse towards new-habitat patches. Two schemes follow this rule, negative density-dependent dispersal (green) and relative habitat choice (orange), but differ in the preference of the wild type. Since wild-type individuals also preferentially disperse to new-habitat patches under density-dependent dispersal, more individuals are present in those patches. Therefore, there are more individuals overall, increasing the total amount of mutations over the deterioration time. This effect is even stronger for large dispersal rates that increase the wild-type population size in the whole environment. Together with the effect of relaxed competition, this explains the strong increase of the negative density-dependent, the maladaptive, and the random dispersal scheme in Figure 5(c).

Lastly, the probability of evolutionary rescue reaches a local (or global) maximum for inter-mediate emigration probabilities (Figures 5(c,d)). This extends previous results (Uecker et al., 2014; Tomasini and Peischl, 2019) to arbitrary dispersal schemes affecting the immigration process. The maximum can be attributed to the interaction of the three regions we identified when analyzing the establishment probability *φ _{k}* (see also Figure 2). As such it is a result of the largely positive effect of dispersal (initial increase of the probability of evolutionary rescue) and the negative effect of population mixing.

### 3.5 Habitat of origin of the rescue mutant and standing genetic variation

Similar to what was found for the probability of adaptation, rescue mutants mainly originate from the old-habitat patches – acting as sources. Mutations are more likely to appear in the more populated patches (old-habitat). However, lower mutant fecundities *ω*_{m} decrease the chance of establishment of these mutants that appears in old-habitat patches (compare black and yellow symbols in Figure 6(a)). Lower fecundity values *ω*_{m} therefore comparatively increase the probability for the rescue mutation to have appeared in the already deteriorated habitat, i.e. in new-habitat patches.

So far, we have considered settings where evolutionary rescue is exclusively due to de-novo mutations. To explore the role that could be played by standing genetic variation, we ran simulations were we let the system evolve for 1, 000 generations before the first degradation event happened. Figure 6(b) shows the relative contribution of de-novo mutations and of standing genetic variation, i.e. mutations that appeared before the first degradation event happened. With our parameters, where the environmental change lasts for 900 generations (= (*M* − 1)*τ*) in total, contributions due to standing genetic variation, are small (circles in Figure 6(b)).

Additionally, the relative contribution of standing genetic variation declines as the emigration rate *m* increases. This holds because the mutant has no chance to establish for large frequencies of old-habitat patches *f*_{old} and large emigration rates (see Figure S4 in SI). Thus, mutants that existed prior to the first deterioration event are very unlikely to survive even for a rapidly changing environment.

## 4 Discussion

We have studied the probabilities of establishment, adaptation and evolutionary rescue under four non-random dispersal schemes and compared them to random dispersal. Our analysis builds on the probability of establishment of a single mutant lineage in a heterogeneous environment with a fixed patch configuration. In line with previous results, we find that the probabilities of establishment, adaptation and evolutionary rescue can display up to three different phases when varying the dispersal rate *m*. The different dispersal schemes, by changing the population dynamics, broaden, tighten or shift these regions.

### 4.1 Dispersal and adaptation

Theoretical studies that investigated the effects of spatial subdivision on the adaptation of a population in a heterogeneous environment can be classified into two types. One type of models, classically analyzed in a population genetic context, assumes constant population sizes in all patches, independent of their local habitat type and of dispersal strength. Results obtained in this framework show that larger dispersal rates tend to decrease the probability of successful establishment of a rare mutant favored in some part of the environment (e.g. García-Ramos and Kirkpatrick, 1997). This inhibiting effect of dispersal on adaptation, also termed “gene swamping”, is a result of an increase in absolute numbers of non-adapted individuals in the habitat where the rare mutant is beneficial, resulting in a lower mutant frequency (Lenormand, 2002; Tomasini and Peischl, 2018). Additionally, for very high dispersal rates, the population homogenizes and individuals encounter an averaged environment. Therefore, the type with the largest overall growth rate, averaged over the environment, is favored.

The second type of models explicitly takes into account demographic effects due to dispersal, often in the context of source-sink systems (Holt, 1985; Pulliam, 1988). Here, the effect of dispersal on adaptation depends on the growth rate differences of the mutant and the wild type in the two habitats (Kawecki, 2000). In accordance with this result, we find that dispersal increases the probability of adaptation if the mutant is just slightly less fit than the wild type in the old habitat, *ω*_{m} /*ω _{w}* = 0.99 (Figure 2(c,d)). When the mutant’s fecundity in old habitats,

*ω*

_{m}, is smaller, establishment probabilities are non-monotonic with a local maximum at intermediate dispersal rates (see Figure 2(a)). However, if the mutant’s disadvantage in old-habitat patches is even greater, i.e.

*ω*

_{m}even smaller, adaptation is also hindered for large dispersal rates. The establishment probability becomes hump-shaped (cf. Figure S2 in SI).

Hence, models with and without demographic changes differ most at higher emigration rates. This corresponds to region (iii) in our analysis; we illustrate these points by presenting in Figure S5 in SI the non-demographic equivalent of Figure 2.

### 4.2 Dispersal and evolutionary rescue

Besides the general structure of the probability of evolutionary rescue when varying the emigration probability *m*, we also studied the effect of standing genetic variation on this quantity. We find that the contribution of standing genetic variation on the overall probability of evolutionary rescue increases with the speed of the environmental change, determined by *τ*(Figure 6(b)). This observation has also been made in a quantitative genetics setting where the adaptive trait is continuous (and not discrete as in our model) (Matuszewski et al., 2015). Experimental results with *Caenorhabditis elegans* indicate that under slow environmental change the impact of standing genetic variation is small (Guzella et al., 2018). This is because the evolution of the trait is driven by *de novo* mutations with small effects. For a sudden or fast environmental change however (small *τ*), standing genetic variation becomes increasingly important for the probability of evolutionary rescue. These observations are in line with our findings in Figure 6(b) and other theoretical results obtained in this context (Matuszewski et al., 2015).

### 4.3 The effect of different dispersal patterns on adaptation and evolutionary rescue

The importance of considering dispersal schemes different from random dispersal has been highlighted in several papers (Edelaar et al., 2008; Clobert et al., 2009; Edelaar and Bolnick, 2012). This has led to a number of simulation studies exploring the effects of various dispersal schemes onto adaptation and niche width (e.g. Vuilleumier et al., 2010; Holt and Barfield, 2015; Mortier et al., 2018; Pellerin et al., 2018).

Two of these simulation studies examined the effects of matching habitat choice on adaptation to a heterogeneous environment (Vuilleumier et al., 2010; Holt and Barfield, 2015). Both investigations indicate that matching habitat choice increases the probability of adaptation when compared to random dispersal. This is in line with our findings: we predict that type-dependent habitat choice (orange lines) generates higher probabilities of establishment and evolutionary rescue than random dispersal (black lines) (Figures 2, 3, 5).

The dispersal schemes also slightly affect the origin of the successful mutant lineage, cf. SI, Figure S6. Population densities, especially in new-habitat patches, are altered when compared to the random dispersal scheme.

To conclude, the effects of dispersal schemes are two-fold. By changing population densities in both habitat types, the dispersal schemes change the growth rate of the mutant in old-habitat patches. This is the primary reason for the ranking of the dispersal schemes. In addition, they also affect the number of mutations arising in either habitat type. This has a minor effect on the probability of evolutionary rescue for the explored parameter range but is relevant when studying the origin of the successful mutant lineage.

### 4.4 Evolutionary consequences of habitat choice

The interplay of local adaptation and habitat choice has interested evolutionary ecologists for several decades, see for example Rosenzweig (1981) for one of the first references. Our analysis shows that absolute habitat choice lowers the probability of establishment when compared to random dispersal; see blue lines in Figure 2. This indicates that habitat choice protects a population against locally deleterious mutations, that are potentially favorable elsewhere, if the mutant has the same dispersal pattern as the wild type, i.e. *π*_{m} = *π*_{w} > 1. A similar observation, protection of the already established type, was made in Ravigné et al. (2009) where a co-evolutionary model of a habitat choice trait and a local adaptation trait is implemented.

Moreover, Ravigné et al. (2009) find that habitat choice can actually evolve and lead to evolutionary branching, i.e. the coexistence of two specialist types with their own habitat preferences (our relative habitat choice dispersal scheme). In line with this, our results show that in parameter regions where relative habitat choice yields higher probabilities for establishment than random dispersal, if a mutant is able to quickly evolve its own habitat preference as it does in Ravigné et al. (2009), it has an increased chance of establishing in the meta-population. This is in agreement with recent experimental findings in the ciliate *T. thermophila* (Jacob et al., 2017). Even though we do not explicitly consider speciation and the evolution of genetic polymorphisms, our results may suggest that type-dependent matching habitat choice enhances phenotypic divergence, if we use the probability of adaptation as a proxy for invasion probability. The probability of adaptation for relative habitat choice (orange) is higher than for absolute habitat choice (blue) or random dispersal (black), Figure 3. This idea has already been promoted in other theoretical and experimental studies (e.g. Rosenzweig, 1987; Rice and Salt, 1990; Ravigné et al., 2009; Berner and Thibert-Plante, 2015; Jacob et al., 2018).

### 4.5 Generality of our theoretical analysis and future directions

Our mathematical results apply in the case where the mutant offspring numbers can be written in the form “migration times reproduction (and potential regulation)” with rates that are constant in time (see the mean reproduction matrix in eq. (5)). Biologically, this means that the resident population is stationary and the mutant is either at low numbers or unaffected by its own density. Furthermore, for our approximation in eq. (7) to generate accurate predictions, it is essential that growth rate differences between the wild type and the mutant are weak and dispersal is low. Formally, just two of these parameters need to be small – see also the corresponding discussion in Tomasini and Peischl (2018).

Since we summarize the population dynamics in our parameters of the reproduction matrix, the approach taken here is quite general and can account for various dispersal schemes and local population dynamics. However, it cannot account for explicit spatial structure as for example the stepping stone model. It also cannot account for time-inhomogeneous environments. This is the reason for our approximation to perform worse in the context of evolutionary rescue (Figure 5). Additionally, in order to obtain analytical solutions, it is important that the stationary population sizes of the wild type have an accessible solution. This is not the case if for example we consider non-linear emigration rates that depend on habitat choice like those incorporated in some simulation studies (e.g Holt and Barfield, 2015; Mortier et al., 2018).

In contrast, it should be possible to include a cost of dispersal and a different life cycle. In particular, the variation of the life cycle could yield qualitatively different results regarding adaptation (Holt and Barfield, 2015) and more generally in the context of the evolution of dispersal (Massol and Débarre, 2015).

In conclusion, we studied the effect of dispersal and different dispersal schemes on the probability of establishment, adaptation and evolutionary rescue of a mutant under divergent selection in a subdivided population. Our quantitative approach disentangles the interaction of dispersal and adaptation. We recover previous results on adaptation and provide a general framework for studying evolutionary dynamics of a subdivided population in heterogeneous environments. This unifying approach allows us to identify the forces that are responsible for the different predictions obtained in the population genetics literature and under source-sink dynamics, respectively. We find that including population demography significantly alters the results for high dispersal rates. For constant population sizes, high dispersal rates have a negative effect on establishment, while with explicit demography the effect is largely positive. The latter is a result of relaxed competition in old-habitat patches. Most importantly, we extend the existing literature by comparing different dispersal schemes and studying their effects on adaptation and evolutionary rescue. Our results indicate that habitat choice does not necessarily result in an increased adaptive potential and might even hinder successful establishment of a mutant population that would avoid population extinction. Negative density-dependent dispersal always increases the probability of adaptation and evolutionary rescue. These results show that non-random dispersal patterns can have a strong influence on population survival and adaptation in a heterogeneous environment.

## Acknowledgements

PC and FD received funding from the Agence Nationale de la Recherche (ANR-14-ACHN-0003 to FD). HU appreciates funding from the Max Planck Society. We are grateful to the INRA MIGALE bioinformatics facility (MIGALE, INRA, 2018. Migale bioinformatics Facility, doi: 10.15454/1.5572390655343293E12) for providing computational resources. Additionally, we thank Jérôme Mathieu for highlighting the connection of the ‘maladaptive dispersal scheme’ to the ecological trap literature, and Staffan Jacob and Pim Edelaar for fruitful discussion concerning the biological motivation of the dispersal schemes.