abstract: This article verifies that the ideal free distribution (IFD) is evolutionarily stable, provided the payoff in each patch decreases with an increasing number of individuals. General frequency-dependent models of migratory dynamics that differ in the degree of animal omniscience are then developed. These models do not exclude migration at the IFD where balanced dispersal emerges. It is shown that the population distribution converges to the IFD even when animals are nonideal (i.e., they do not know the quality of all patches). In particular, the IFD emerges when animals never migrate from patches with a higher payoff to patches with a lower payoff and when some animals always migrate to the best patch. It is shown that some random migration does not necessarily lead to undermatching, provided migration occurs at the IFD. The effect of population dynamics on the IFD (and vice versa) is analyzed. Without any migration, it is shown that population dynamics alone drive the population distribution to the IFD. If animal migration tends (for each fixed population size) to the IFD, then the combined migrationpopulation dynamics evolve to the population IFD independent of the two timescales (i.e., behavioral vs. population). Keywords: competition, evolutionarily stable strategy, habitat choice, ideal free distribution, migration dynamics, dispersal. The ideal free distribution (IFD; Fretwell and Lucas 1970) is a theoretical concept that assumes freely moving individuals between food or habitat patches. These ideal animals have a perfect knowledge of their environment and the same competitive abilities, and they settle in the patch * E-mail: rcressma@wlu.ca. † Corresponding author; e-mail: krivan@entu.cas.cz. Am. Nat. 2006. Vol. 168, pp. 384-397. ᭧ 2006 by The University of Chicago. 0003-0147/2006/16803-41430$15.00 All rights reserved. that provides them with the highest resource intake rate. This results in a spatial distribution under which no individual can unilaterally increase its fitness (or payoff) by changing its strategy (i.e., its choice of habitat). This theory assumes that the patch quality does not change over time (e.g., because of patch exploitation) and that consumers share resources in the sense that an increase in the number of consumers in a patch decreases the payoff of each consumer in the patch. Thus, if consumers do not interfere with each other, then they should all be in the best patch. However, as the number of consumers in the best patch increases, there will be some interference between them. For example, two consumers may hunt for a single food item, which leads to a decrease in payoff. Because fitness in any patch depends on the population distribution, the IFD concept is an example of a frequency-dependent process: decisions where to settle depend on the current population distribution. The IFD has been repeatedly given in the literature (e.g., Parker 1978 Parker , 1984 Pulliam and Caraco 1984; Pulliam and Danielson 1991; Kennedy and Gray 1993; Morris 2003) as an example of the evolutionarily stable strategy (ESS). There are two conditions that an ESS must satisfy (Maynard Smith 1982) : there is no other strategy that an individual can adopt (i.e., no other patch choice) with a higher payoff and the strategy cannot be invaded by rare individuals playing another strategy. The first condition is the Nash equilibrium from game theory. In the literature on the IFD, most authors consider only this condition and pay no attention to the second ESS condition. Therefore, the question arises whether every IFD is automatically an ESS. This is answered in "The IFD Is an ESS." The IFD has become such a powerful tool for several reasons. First, the Nash equilibrium condition, that individual payoff in all inhabited patches must be the same, allows one to easily compute the IFD. More important, the (approximate) IFD has been observed in many empirical studies (for reviews, see Milinski and Parker 1991; Kacelnik et al. 1992; Tregenza 1995; Hugie and Grand 1998) . Thus, the IFD often predicts the outcome of animal migration between patches without explicitly describing this migration. On the other hand, in many other experiments reviewed in this literature, populations are not at Ideal Free Distributions 385 the IFD or evolving in this direction. It is therefore important to know which patterns of movement between patches lead to the IFD and which do not. Explicit models of migration (reviewed in Briggs and Hoopes 2004) are abundant in ecological literature on species stability, where they show that spatial heterogeneity can stabilize population dynamics. The relation between population dynamics, migration, and the IFD has been analyzed in studies on the evolution of dispersal (e.g., Gadgil 1971; Hastings 1983; Holt 1985; Johnson and Gaines 1990; McPeek and Holt 1992; Houston et al. 1995; Holt and Barfield 2001; Hutson et al. 2003; Padró n and Trevisan 2006; DeAngelis et al., forthcoming). The population distribution in these studies is the outcome of two processes: population growth in local patches and migration between patches. If individuals do not migrate at all, then at the population equilibrium, their fitness measured by the per capita population growth rate is the same (and equal to zero) in all occupied patches. Thus, the IFD is also achieved even when there is no migration. Now, suppose that population numbers are fixed but individuals do migrate. The migration rates then define a distribution that will correspond to the IFD only if these rates satisfy special conditions (called "balanced dispersal" in McPeek and Holt 1992). If passive migration is unconditional in the sense that the migration rate between any two patches is the same in both directions, unbalanced dispersal rates lead to a higher density in the poor patch and a lower density in the good patch when compared with the IFD. This phenomenon is known as "undermatching" (Milinski 1988; Kennedy and Gray 1993; Houston et al. 1995; Jackson et al. 2004 ). In the context of the evolution of dispersal, undermatching leads to the prediction that unconditional dispersal should be selected against in spatially heterogeneous but temporally constant environments (Hastings 1983; Holt 1985) . The studies on the evolution of dispersal also consider conditional dispersal (McPeek and Holt 1992; Padró n and Trevisan 2006) , in which the per capita dispersal rate depends solely on the habitat type and so is not influenced by habitat fitness based on local population density. It is shown that conditional per capita balanced dispersal rates corresponding to the IFD at equilibrium population densities cannot be invaded by mutants with different dispersal rates. A similar result was also observed recently in simulations of an individual-based model with density-dependent migration rates combined with population dynamics (DeAngelis et al., forthcoming). In this article, our migration analysis begins by assuming that overall population density is fixed, and we ask, "What are the migration rules that correspond to the IFD?" We develop several density-dependent models of migratory dynamics that differ in the degree of animal omniscience, and we show that migration rates in these models converge to those corresponding to balanced dispersal. In particular, migration does not cease when the IFD is reached, which agrees with experimental observations surveyed by Hugie and Grand (1998, 2003). A common feature of these models that lead to the IFD is that individuals do not migrate to patches with lower payoff. Such behavior is most realistic when animals receive sensory cues for differences in patch quality (e.g., the visual cues for resource input rates in experiments on ducks [Harper 1982] and sticklebacks [Milinski 1988] ). An indirect consequence of these models is that (per capita) emigration rates are low from patches with high payoff. There is empirical evidence to support the hypothesis that individuals move more readily from patches with low payoff. For instance, field observations by Hodek and Honěk (1996; see also Osawa 2000) show that ladybird beetles stay longer in high-quality-resource patches (i.e., where the resource density of aphids is high). That is, per capita emigration rates from a given patch are inversely related to its quality. However, conclusions concerning immigration patterns based on such data are less convincing because either the destination patch of migrating animals is not recorded (but see Osawa [2000] , who suggests that ladybirds can sense the odor of aphids in distant patches to better direct their movements) or there is evidence of some randomness in the choice of destination. To model these empirical results, we also consider the consequences of suboptimal migration patterns that include a random component. For two-patch models, Hugie and Grand (1998) show how undermatching occurs when the nonrandom component satisfies the following conditions: animals do not migrate to patches with lower payoff and individual migration rates change continuously as patch densities change. We extend this result to multihabitat environments. We also show the surprising result that the IFD may still emerge in suboptimal circumstances that are far from ideal when either of these conditions are not satisfied. This gives another indication of the robustness of the IFD outcome beyond the original framework of Fretwell and Lucas (1970) . Our analysis also studies the effect of combining population dynamics with migration dynamics. We rewrite population dynamics in the form of a density-dependent replicator equation that clearly shows that if individuals do not move between patches at all, the IFD will be achieved at the population equilibrium due solely to changes in overall population numbers. Second, we combine this equation with migration dynamics and give conditions under which the combined population-migration dynamics converge to the IFD irrespective of the relative timescales between these two processes. considered a fixed number of individuals that freely migrate between patches and that know perfectly the payoff in all patches (i.e., ideal animals), and they called the resulting distribution the ideal free distribution (IFD). They predicted that under the IFD the first k patches are occupied and that the payoff in all occupied patches is the same and at least as large as the payoff in unoccupied patches (i.e., , ). In the case of a monomorphic population, is inter- * p i preted as the proportion of time an average individual spends in patch i. Average payoff is then calculated as . However, because * * * *  cause only the first k patches are occupied both by residents and by mutants (if mutants occupied patch i with , i 1 k then their payoff would be lower than the average payoff). This equality of resident and mutant payoffs means that the definition of the IFD does not exclude the possibility that an initially rare subpopulation can spread in the resident population. In other words, the Fretwell and Lucas (1970) definition of the IFD does not secure stability of the distribution. To avoid this possibility that the IFD is unstable with respect to spatial perturbations, we need to verify that the above IFD can withstand these invasions by showing that it satisfies the second ESS stability condition (Maynard Smith 1982) . Appendix A in the online edition of the American Naturalist proves that for a single population, the IFD automatically satisfies the stability condition and is therefore an ESS. This result is by no means trivial because it does not hold in general for more than one population. In particular, Cressman et al. (2004) give an example where the Nash equilibrium for two competing species is not stable with respect to spatial perturbations, provided interspecific competition is strong enough. Both the IFD and the ESS concepts are independent of any particular migratory and evolutionary dynamics. This means that the IFD is stable with respect to invasion by a single monomorphic mutant with a different strategy irrespective of the particular migration strategy of the mutant. In other words, if a resident population uses some unspecified migration rule that drives the population to the IFD, then, provided the resident population already reached the IFD, no mutant with any different migration rule can invade the resident population. We see that this concept of stability is very strong because it is entirely independent of particular migration rules. However, the question arises as to what migration rules lead to the IFD. We resolve this issue in "Migration Dynamics." In this section, we develop several models that describe migration under the assumption that the overall population abundance (M) does not change and then study under which conditions the equilibrium distribution is the IFD. Thus, the distribution across patches is a function of immigration and emigration processes only. To describe changes in population distribution due to migration, we define the migration matrix I. The entries of this matrix (I ij ) describe the transition probabilities that an individual currently in patch j moves to patch i in a unit time interval. The local changes in population numbers due to migration are described by for , where is the vector 1 H of population densities in H patches. Thus, the first term in the above summation describes immigration to patch i from other patches, and the second term describes emigration from patch i to other patches. Because the terms I ii (m)m i describing movement from patch i to itself cancel in equation (1)  To achieve the IFD, either the migration matrix must be frequency dependent or the fixed migration rates must correspond to balanced dispersal. Indeed, for any frequency-independent migration matrix with positive entries, there will be a unique globally asymptotically stable equilibrium distribution (app. D in the online edition * p of the American Naturalist) that exhibits undermatching in some patches unless the fixed migration rates equal those for balanced dispersal given by Holt (1985) . We show now that if individuals are ideal and always sample their environment, the migration matrix in equation (2) changes abruptly near patch distributions where two (or more) habitats have the same (highest) payoff. Suppose there are two patches. The migration rates between these two patches are I 12 (p) and I 21 (p). If individuals migrate from patches with a lower payoff to patches with a higher payoff only (which excludes random migration between patches), then they migrate from patch 2 to patch 1 ( and ) when the payoff in patch 1 is higher than that in patch 2 ( ) and conversely when the payoff in patch 2 is higher than that in patch 1 ( and ). Thus, continuous dependence of the migration matrix I(p) on the distribution p immediately implies that under the IFD (i.e., when ), there is no migration between the two patches ( ), as suggested by Hugie and Grand (1998). However, if migration ceases under the IFD, then individuals cannot keep track of changes in other patch payoffs (unless the migratory cues are obtained without moving, such as through animals observing feeding rates, as in Harper 1982). Out of the five empirical studies of fish and bird habitat distributions that converged to the IFD reviewed by Hugie and Grand (1998) , in only one instance was no movement between patches observed at equilibrium distribution, and this was for a case where distance between patches was large. Thus, if we want animals to migrate between patches even under the IFD, then either the migration matrix must be a discontinuous function of population distribution p (which means that small changes in population distribution lead to disproportionately large changes in the migration rates if two or more patches have the same payoff) or there must be some non-IFD (e.g., random) movement between patches (Hugie and Grand 1998). We discuss both scenarios below. In what follows, we study the conditions under which the migration dynamics described by equation (2) converge to the IFD. We show that this happens under much weaker conditions than those originally imposed by Fretwell and Lucas (1970) . In fact, we prove (app. B in the online edition of the American Naturalist) that convergence to the IFD occurs, provided migration rates satisfy the following two conditions: individuals never migrate to patches with lower payoff and some individuals always migrate to a patch with the highest payoff (which prevents the unrealistic case that the patch with the highest payoff is completely neglected by migrating animals). It is important to emphasize that these conditions do not require ideal animals that know their environment perfectly in the sense that they always move directly to the best patch, as originally assumed by Fretwell and Lucas (1970) . Instead, an individual needs only to be able to compare the payoff in one other patch that it samples (perhaps at random) with its payoff in its current patch, a much weaker assumption. This is one explanation for the prevalence that the IFD is observed in the experimental literature despite the fact that the species in many of these experiments were clearly nonideal. Below we illustrate our results using some explicit migration dynamics. Most of these migration dynamics satisfy the above two assumptions, but we are also interested in situations where some individuals migrate between patches at random, in which case our first condition does not hold. We start with migration dynamics that assume ideal animals, exactly as Fretwell and Lucas (1970) did. Thus, if these animals are in a suboptimal patch, they always migrate directly to the patch(es) with the highest payoff. If, for a given distribution , the payoff patch i is larger than that in any other patch, then the corresponding migration matrix has 1s in the ith row (because the probability that an animal migrates from any other patch to patch i equals 1) and 0s everywhere else. We document this for the case with three patches ( ; fig. 1A ), where we set . , and trajectory that starts at the initial distribution (0, 1, 0). The solid line shows the payoff in the first patch, the dashed line shows the payoff in the second patch, and the dotted line is the payoff in the third patch. The right panel shows emigration rates from these respective patches along the same trajectory. Parameters: , , , Ideal Free Distributions 389 ( fig. 1A , left, dotted triangle) into three parts. In each of these three parts, the best patch is uniquely given, and the migration matrix I(p) is constant and equal to one of the following three matrices: We stress here that although the matrices I 1 , I 2 , and I 3 are frequency independent, the migration matrix I(p) is frequency dependent because its entries depend on the distribution. Specifically, migration matrix I(p) is piecewise constant and changes its value when the distribution crosses one of the three equal-payoff lines interior point). If population size (M) is large enough so that all habitats are occupied at the IFD, these three equalpayoff lines intersect at the IFD ( fig. 1A , left, dot): Three trajectories of equation (2) are shown in figure 1A (left) as solid lines. The IFD is reached in finite time, as is clearly documented in figure 1A (middle), where we see that patch payoffs equalize in a finite time when the IFD is achieved. For example, let us consider an initial distribution where all individuals occupy patch 2 only, corresponding to the lower right corner of the triangle in figure 1A (left). For the particular parameters used in this figure, the "best" patch is then the first patch, and so individuals initially migrate there. Thus, payoff in patch 1 decreases, payoff in patch 2 increases, and payoff in patch 3 does not change ( fig. 1A, middle) . Once the population reaches the equalpayoff line where the payoff in patch 1 equals the payoff in patch 3, individuals then start to migrate to patch 3 as well because both patch 1 and patch 3 are the best patches. The animal distribution must stay on this equal-payoff line. Indeed, if slightly more individuals moved to patch 1 (so that the corresponding trajectory shifted slightly off and below the equal-payoff line), the payoff in this patch would decrease below the payoff in patch 3, and immediately, patch 3 would become the best patch. This forces the trajectory to move back to the equal-payoff line. The above specific example can be extended to any number of patches. The dynamics given by equation (2) are also called the best response dynamics (Hofbauer and Sigmund 1998) because they can be used to model individuals who choose the best strategy with respect to the present state of the system. Under our assumptions, the IFD is globally asymptotically stable regardless of the number of patches. That is, every trajectory of equation (2) will converge to the IFD when the migration matrix corresponds to ideal animals. Furthermore, migration does not cease at the IFD. In fact, at the IFD (eq. [3]), the migration rates are equal to the population distribution (i.e., , , as explained in app. C in the * online edition of the American Naturalist). That is, the probability of migrating from any other patch to patch i, or staying in patch i and not migrating, is positive (and equal to ). If the total population density * corresponds to the population equilibrium (i.e., ), then the IFD (eq. [3]) simplifies to and corre- * sponds exactly to balanced dispersal (Holt and Barfield 2001) . This agrees with the theoretical prediction given by McPeek and Holt (1992) that the migration rate from patch j to patch i (which is ) is inversely related * to the carrying capacity K j of patch j. Furthermore, the emigration rate from patch j (E j , defined as the sum of the migration rates from patch j to other patches) at the IFD (e.g., this rate is * * with experimental results, such as those of Osawa (2000) and Diffendorfer (1998). In fact, for our models, a comparison of patch payoffs and emigration rates ( fig. 1A , middle and right, respectively) shows that these are also inversely related along trajectories of equation (2) that have not yet reached the IFD. Indeed, for every time instant, if the payoff in patch i is higher than that in patch j (i.e., ), then the emigration rate from patch i is V 1 V i j lower than that from patch j. Along this trajectory, the emigration rates are piecewise constant, and it is clear that they do not cease when the IFD is reached. The assumption that animals are ideal in the sense that they immediately move to the best patch is very unrealistic because it means that animals know their environment 390 The American Naturalist perfectly. Other more realistic migration rules that are based on local knowledge can be considered. For example, we can assume that individuals sample patches at random and switch to a new habitat only if it has a higher payoff. If the sampled patch has a lower payoff, then the individual moves back to the patch it started from. This type of behavior was observed in the sticklebacks of work by Milinski (1988) , where it continued after the IFD was reached as some fish checked the resource level in each patch. It is also a common assumption in simulations of real ecosystems (e.g., Mooij et al. [2002] used this behavior to simulate the movement of snail kites in their Florida wetlands habitat). In our model, the probability that an individual switches from a patch j with a lower payoff (V j ) to a patch i with a higher payoff (V i ) is because of 1/H random sampling of the H patches (here we assume that with probability an individual "samples" its own 1/H patch). The probability that an individual switches in the opposite direction (i.e., from patch i to patch j) is 0. If all patches have different payoffs, the probability that an individual returns to the same patch it started from is , k/H where k is the number of patches with a lower payoff. We will call individuals that follow such migration rules "myopic" because their behavior depends only on a local knowledge of their environment. We illustrate this migration rule in the case of three patches. Once again, the migration matrix I(p) is piecewise constant. Migration rates change when the population distribution crosses one of the equal-payoff lines ( fig. 1B , left, dashed lines), which leads to six different values of the migration matrix. For example, in the region of the distribution space where , the migration matrix Indeed, because the payoff in the first patch is highest, all individuals from patch 1 that sampled any other patch will return, which gives migration probability On the 123 I p 1. other hand, one-third of individuals from patch 2 and patch 3 sample patch 1 and stay there. This gives the first row in the migration matrix I 123 . Likewise, all individuals that sampled patch 2 from patch 1 will move back to patch 1, leading to . Furthermore, one-third of individ- I p 0 21 uals from patch 2 sample patch 3 and return to patch 2, which together with one-third of individuals from patch 2 that did not sample any other patch, gives 123 I p 2/3. Also, one-third of individuals from patch 3 sampled patch 2 and stay there. This gives the second row of the migration matrix. For the third row, all individuals from patch 1 and patch 2 that sampled patch 3 return, and only one-third of individuals from patch 3 (i.e., those that did not sample any other patch) stay in patch 3. The migration matrices in any of the other remaining parts of the distribution phase space can be constructed similarly. The migration dynamics are shown in figure 1B . As predicted, they converge to the IFD, which is the same as the one for ideal animals. In contrast to the ideal case ( fig.  1A) , trajectories in figure 1B do not evolve immediately in the direction of the current best patch. This is because individuals from the worst patch can migrate to either of the two other patches that have a higher payoff. There is another important difference when compared with ideal animals; namely, it is no longer possible to compute migration rates at the IFD because these rates are not defined uniquely ( fig. 1B, right; app. C). In other words, it is, in principle, impossible to predict the migration rates at the IFD when animals are myopic. However, as with ideal animals, the distribution dynamics continue to be uniquely defined for myopic animals, and there will still be migration at the IFD. The two migration dynamics studied above assumed that individuals migrate even if their distribution is at the IFD. Migration dynamics can also be developed in which migration matrices I(p) depend continuously on the population distribution p (e.g., Hugie and Grand 2003). In other words, a small change in the distribution causes small changes in individual strategies. However, as we discussed above, under the assumption that individuals never migrate to patches with a lower payoff, continuity immediately implies there can be no migration among patches with the same payoff. Although this assumption is therefore unrealistic in many situations, there are circumstances where continuous dependence makes sense. For instance, if individuals can perceive their environment by some sensory stimuli that do not require them to visit the other patches, they do not need to migrate when patch payoffs are the same (i.e., when the distribution corresponds to the IFD). One of the simplest examples of such a migration matrix is given by where is so small that I ii is positive. The above matrix m 1 0 describes migration that increases as the difference between the payoffs increases. That is, the higher the benefit Ideal Free Distributions 391 is to moving to a new patch, the more willing individuals are to do so. As our two general conditions are satisfied (i.e., individuals do not migrate to patches with a lower payoff, and some migrate to a patch with the highest payoff), the trajectories of these migration dynamics converge to the IFD. In this example, migration ceases at the IFD ( for ). Furthermore, convergence to the IFD I p 0 i ( j ij can no longer occur in finite time because the resulting dynamical system has a continuous vector field near the IFD. The case with three patches is shown in figure 1C . Another particularly important example of historical interest has the migration matrix given by Straightforward calculations then show that equation (2) becomes the replicator equation which is the standard behavioral dynamics used in evolutionary game theory (Hofbauer and Sigmund 1998; Cressman 2003) . In contrast to all the previous migration matrices, individuals never migrate to unoccupied patches (if initially, then patch i stays animal free for all p p 0 i time) for the replicator equation. Because this is quite an unrealistic feature of equation (5) in our context, we feel that this migration matrix should not be used as a general model describing migration. However, once again, distributions described by the replicator equation converge to the IFD if all patches are initially occupied. In this section, we assume that there are some individuals that will move from patches with higher payoffs to patches with lower payoffs but that the probability of such maladaptive movement will be small when compared with the probability of moving from a worse patch to a better patch. This section can then be interpreted as a migration model that combines both IFD and non-IFD migration (sensu Hugie and Grand 1998). One interpretation of adding random migration is that it allows an individual to make a mistake in assessing the payoff of a sampled patch. When the component of migration that leads to the IFD varies continuously with payoff differences as in the previous section, we show that undermatching occurs. However, for ideal or myopic animals, we show that the resulting population distribution can still correspond to the IFD even if individuals make errors in their decisions about where to move. Assume that the migration matrix has the form ij ij H where parameter ( ) measures the degree of 0 ≤ ≤ 1 random versus frequency-dependent migration in the population. For example, matrix J can be any of the matrices considered previously that describe frequencydependent migration. When , migration matrix (eq. p 1 [7]) has all its entries the same (i.e., ). This de-I p 1/H ij scribes unconditional random migration because every individual has the same probability of moving to any one of the other patches or staying in the current patch. Suppose that matrix I depends continuously on distribution p and that I ij increases as either the payoff in patch i increases or the payoff in patch j decreases. Appendix D shows that migration dynamics (eq. [2]), where I is given by equation (7) with , has an asymptotically stable 1 0 equilibrium . Moreover, all patches are occupied at this * p equilibrium distribution, which depends continuously on the parameter . If migration under J converges to the IFD, this ranges from the uniform distribution when * p ( fig. 1D, ) to the IFD when p 1 (1/3, 1/3, 1/3) p 0. For positive (such as in fig. 1D ), there is undermatching because fewer individuals are in the better patch than predicted by the IFD. The extent of undermatching increases as the component of IFD movement in the population decreases (i.e., as approaches 1). Somewhat counterintuitively, if the migration matrix can change abruptly with population distribution (e.g., animals are ideal or myopic), then the IFD can still be reached even if individuals make errors in their decisions (i.e., when ) and migration under J corresponds to 1 0 ideal (or myopic) individuals. This is clearly documented in figure 2, where the stable distribution is shown as a function of the degree of randomness () in individual behavior. This figure assumes that when , individuals p 0 are ideal and their migration is described by the best response dynamics (i.e., the matrix J corresponds to the best response dynamics). We observe that even with some random migration (here can be any value up to 0.2), the stable population distribution still corresponds exactly with the IFD, and, despite the randomness in individual movement, there is no undermatching. For this phenomenon to occur, the migration matrix J corresponding to IFD movement cannot depend continuously on the population distribution because it is crucial that the IFD move-392 The American Naturalist verges to the uniform distribution ( , , ). Parameters as in figure 1/3 1/3 1/3 1. ment under J continue even when the IFD is reached in order to offset the random (i.e., non-IFD) migration component. Suboptimal migration patterns can also emerge when individual movement depends on other factors besides resource abundance. For instance, animals may exhibit exploratory behavior based in part on the memory of patch payoffs received in the past (our models all assume that migration rates depend only on current payoffs). The twopatch simulation study of Regelmann (1984) shows that combining this effect with some tendency to move to better patches again leads to the IFD. Furthermore, in a variety of taxa, it has been shown (e.g., Weisser 2001) that animals select patches with lower predation risk. Thus, risky patches can be occupied by disproportionately fewer consumers than would be the case without predation risk, while safe patches can be occupied disproportionately more often. Similarly, animals may prefer to move to already occupied patches where they can find mates to patches with no or low occupancy. Qualitatively, migration then combines two mechanisms: an increase in immigration rates to patches occupied by conspecifics because of increased mating probability or decreased predation risk and an increase in emigration rate from a patch as the number of individuals increase there. For instance, these two tendencies are captured by the migration matrix first and second mechanisms, respectively. The second factor can also be interpreted as an individual's dissatisfaction with a low payoff in its current patch, together with a random component whereby these individuals have 1/H not chosen the destination patch. What is interesting for us is that the IFD again emerges for migration matrix (eq. [8]), which includes some random migration and also varies continuously with frequency. The reason for this is that equation (2) again leads to the replicator equation (6) of the previous section because the maladaptive movement of some individuals is more than offset by net migration to better patches and the aggregate population behavior results in balanced dispersal at the IFD. That is, the overall population distribution moves toward the IFD even though individuals do not behave optimally, a phenomenon that has been noted many times in habitat selection models (e.g., Houston and McNamara 1988; Hugie and Grand 1998; Stamps 2001) . In summary, while suboptimal migration may lead to undermatching, as shown by Hugie and Grand (1998) , it can often result in the IFD outcome along with continued movement between patches at this equilibrium. The theory of IFD separates behavioral and population timescales by assuming that the IFD occurs so fast that changes in population numbers can be neglected. However, individuals also undergo population dynamics, and these cause a complex feedback between distribution and population dynamics: distribution changes population growth, which, in turn, influences distribution (Cressman and Garay 2003). Here we combine both population dynamics and migration dynamics to disentangle this feedback. We interpret payoff V i as individual fitness. When there is no migration, population dynamics in each patch are then where m i is the population density in patch i. In order to combine these with migration dynamics, we rewrite equation (9) in terms of the population distribution and total population size. To this end, the average fitness is given by , where we re- size and is the frequency distribution of individuals among habitats. By differentiating the last two equalities and substituting equation (9), the effect of the population dynamics on the density M and the distribution p becomes This is the density-dependent replicator equation (Vincent and Brown 2005) . We stress here that the distribution dynamics (eq. [10]) are produced solely by changes in population numbers in each habitat without any migration. At the equilibrium of the above model, * * are initially occupied must be occupied at the population equilibrium. Otherwise, if the population in a patch is declining to 0, then the payoff in that habitat is eventually positive, and the population is then increasing (which contradicts the assumption that an initially occupied patch would go extinct). Therefore, if all habitats are initially occupied, the individual fitness in each habitat is 0 at the combined population and distribution equilibrium . That is, at the population equilibrium, each hab- * * (p , M ) itat i is at its carrying capacity K i , and so the IFD is achieved without any migration between patches. This shows that the IFD concept, which is based on individual movement between patches, is also relevant for population dynamics without migration. Of course, along trajectories of equation (10), the population distribution does not conform to the IFD (because fitness differs among patches) before population numbers are close to the population equilibrium. When population dynamics are combined with migration dynamics, the corresponding population-migration dynamics are described by the following combination of equations (2) and (10): Here l is a positive parameter that characterizes the relative timescales between the two processes, and denotes the ith component of vector . For large l, migratory behavior operates on I(p, M)p Ϫ p a much faster timescale than demographic changes, which is the case we have already considered. Provided migration leads to the IFD for each fixed population size (e.g., individuals are ideal or myopic), the dynamics (eq. [11]) have the same equilibrium as equation (10), which does not assume any migration between patches. One difference is that when the migration timescale is short with respect to the population timescale (i.e., l is very large), the IFD at each fixed population size will also be achieved along trajectories of model (11) even before they reach the equilibrium. For general l, it is intuitively clear (and formally proved in app. B) that the IFD at population equilibrium will be globally asymptotically stable in the combined model because there are now two mechanisms (individual migration and population dynamics), each of which independently drives the population distribution to the IFD. If migratory dynamics do not converge to the IFD (for fixed population size), then at the equilibrium of equation (11), population distribution will be shifted off the IFD. This happens, for example, with random migration and is caused by the fact that individuals spill over from patches with a higher payoff to patches with a lower payoff (i.e., undermatching; Holt 1985; Houston et al. 1995 ). In contrast with the result depicted in figure 2 for ideal animals, convergence to the IFD when individuals make errors in patch assessment cannot occur here when the populationmigration dynamics modeled by equation (11) depend continuously on the population distribution. In this article, we show the following important and new results for a single-species IFD. First, the IFD is an ESS because it is stable with respect to spatial perturbations. Second, we give explicit models of migration dynamics (based on individual decisions) that converge to the IFD. These models do not require that individuals are globally omniscient (i.e., ideal), as assumed by Fretwell and Lucas (1970) . Third, we show that under these migratory dynamics, individuals still migrate when the IFD is reached at rates corresponding to balanced dispersal (McPeek and Holt 1992) . Fourth, we show that the IFD can be reached even if individuals move suboptimally either through errors in patch assessment or for reasons other than resource abundance. Fifth, we show that migration rates at the IFD are nonunique when animals are myopic. Sixth, we show that the IFD occurs at the population equilibrium solely due to population dynamics when there is no migration between patches. The original definition of the IFD by Fretwell and Lucas (1970) defines the IFD as a Nash equilibrium of a game against nature (i.e., a game between an individual and an average individual in the population; Maynard Smith 1982). A Nash equilibrium is not necessarily an ESS because it may be unstable with respect to mutants that have the same payoff but use a different strategy (in our model, these mutants spend a different proportion of their time in each habitat than the residents using the IFD strategy). In particular, this instability occurs for some Nash equilibria of two-species habitat models (Cressman et al. 2004) , and it is not clear that this cannot happen in a single-394 The American Naturalist species, multipatch environment too. Thus, it is not enough to show that under the IFD, individuals in all occupied patches achieve the same fitness, as is typically done in the literature on the IFD. In this article, we proved that every Nash equilibrium of the habitat selection game for a single species is automatically an ESS when payoff in every patch decreases with higher occupancy. That is, the original definition of the IFD given by Fretwell and Lucas (1970) is indeed an ESS. This confusion about whether the IFD is an ESS is partially due to the fact that the IFD was defined before the ESS. The IFD is a static concept that does not consider the mechanism that drives the system to the IFD. Models that assume fixed migration rates have been considered in studies on evolution of dispersal rates (Hastings 1983; Holt 1985; McPeek and Holt 1992; Holt and Barfield 2001) . McPeek and Holt (1992; see also Padró n and Trevisan 2006) derived the analytical condition of balanced dispersal that leads to the IFD. In their model, these fixed balanced dispersal rates yield an evolutionarily stable dispersal strategy whereby individuals continue to migrate when the distribution is at the IFD. In this article, we show how frequency-dependent migration rates based on individual decisions also lead to balanced dispersal rates at the IFD. However, such frequency dependence of migration rates inevitably requires discontinuous migration rates (that change abruptly as the population distribution changes) and a new modeling methodology based on discontinuous differential equations (e.g., Colombo and Křivan 1993; Křivan 1997; van Baalen et al. 2001; Meza et al. 2005) . We prove that for fixed population size, the frequency-dependent migration dynamics will converge to the IFD for any migration pattern (with either continuous or discontinuous rates) whereby no individual migrates to a patch with a lower payoff. This considerably relaxes the assumptions behind the IFD because individuals need not know the payoff in all patches. For example, it is enough that individuals are able to compare the payoff in a new patch with the payoff in the patch they just left and, if the latter is higher, move back to the original patch. It is interesting to note that migration rates that vary continuously with payoff differences have been investigated vis-à-vis IFD theory in other contexts. For instance, Cosner (2004) analyzed a spatially continuous habitat (our model assumes that patches are spatially distinct) through a gradient system based on net migration in the direction of the locally highest payoff. More relevant for this article is the two-patch model (with unequal competitors in each patch) of Hugie and Grand (1998, 2003), who also included a random migration component. They surveyed 14 empirical studies on the IFD and found that at the distribution equilibrium, migration between patches was observed in eight cases, was not observed in one case where distance between patches was large, and was not measured in other cases (although it was thought to occur at least in some of these remaining cases). They argued that because an individual in a finite population decreases its fitness by moving to another patch at the IFD, the fact that migration does not cease needs further explanation. They suggested that the observed migration at the IFD is due to some "non-IFD movement" such as random migration. Our models with discontinuous migration rates provide an alternative explanation because individuals now continue to migrate even if their distribution corresponds to the IFD. We also considered the situation where individuals move for non-IFD reasons (Hugie and Grand 1998), incorporating the possibility that individuals make errors in their decisions where to move. It has been observed many times that a combination of migration for both IFD and non-IFD reasons leads to undermatching as described by Holt (1985) , Houston et al. (1995) , and others. In particular, as random migration increases, the difference between the distribution equilibrium and the IFD increases too. However, for our frequency-dependent migration models, this need not be so. Indeed, if migration rules are based on ideal animals who also make occasional mistakes, the resulting distribution can still correspond exactly to the IFD as if there were no errors in individual decisions. This is clearly demonstrated in figure 2. As mentioned at the beginning of this article, there is more empirical evidence (e.g., Hodek and Honěk 1996) to conclude that individual emigration rates are higher for low-quality patches than there is to claim that immigration rates increase as patch quality improves. It is therefore important to consider the emigration rates for our migration dynamics models (see the four cases of fig. 1 ). By comparing patch payoffs with emigration rates at each instant in time, we see that the emigration rate from a patch with a higher payoff is always lower than that from a lower-payoff patch, for all our migration dynamics. This result is true in our models whether the dynamics converge to the IFD (i.e., cases A and B, which have continued migration at the IFD, and case C, where migration ceases) or not (i.e., case D, which includes a suboptimal random migration component and continuously varying migration rates). On the other hand, when trajectories in our models maintain equal payoffs between two (or more) patches (i.e., cases A and B), we see that emigration rates are lower from the high-density patch, in agreement with predictions based on the balanced dispersal method and corresponding experimental results (e.g., Diffendorfer 1998). Moreover, our analyses suggest that it can be difficult to obtain consistent predictions from measuring migration rates. For instance, there may be no one-to-one relationship between animal distribution and migration rates, as our example Ideal Free Distributions 395 with myopic animals shows ( fig. 1B) . Although we do not expect that this is the case in most systems, the actual animal distribution may be a more relevant measurement than the migration rates. The previous paragraphs imply that it is quite difficult to use IFD theory to quantify empirically the relative prevalence of random versus nonrandom migration and of ideal versus suboptimal behavior when the IFD is attained (or nearly attained) at fixed overall population abundance. This problem escalates when the effects of population dynamics are also included. The theoretical approach based on balanced dispersal assumes that the population migration rates will then evolve over evolutionary time to those needed to attain the IFD. However, the evidence to support this assumption is inconclusive at best. For example, Donahue et al. (2003) , who measured dispersal rates for the single-cell ciliate, Colpidium striatum, over several generations, found that long-term dispersal rates did not positively correlate with patch quality (i.e., balanced dispersal did not evolve). The IFD theory has been observed for many higher-level organisms (e.g., Harper 1982; Milinski 1988; Hugie and Grand 1998; Berec et al. 2006) where migration patterns are based on individual decisions during a single generation. In this setup, we showed the following general principles for the combined effects of migration and population dynamics. If individuals do not migrate between patches, the population distribution at the population equilibrium still corresponds to the IFD because the fitness of each individual is then equal to 0. Thus, the IFD condition holds automatically at the population equilibrium even when there is no migration, a simple consequence of the fact that better patches can support higher population numbers. Combining population dynamics with IFD migration dynamics that act on a faster timescale leads to the IFD even if population dynamics are not at an equilibrium. On the other hand, some randomness in migration (i.e., non-IFD migration) can lead to a departure from the IFD at the population equilibrium and to undermatching, especially if the migration rules are such that the IFD movement ceases under the IFD. However, if migration rules assume that individuals continue to sample their environment at the IFD, then some random migration may be present without resulting in a departure from the IFD. If individual migration is always toward better patches, we proved that at the population equilibrium, the population distribution will correspond to the IFD and the equilibrium is globally stable. Although this result seems obvious because both population dynamics and individual migration independently drive the population distribution to the IFD, one must be careful drawing this conclusion, as counterexamples with a two-species ESS given by Cressman et al. (2004) show. In the case of two species, it can happen that when both processes are combined, the resulting population equilibrium (and its corresponding equilibrium distribution) may be destabilized by migration. Specifically, Cressman et al. (2004) give a theoretical example of a two-species, two-habitat competition model where fast individual migration, which drives the twospecies system to the two-species IFD, destabilizes the stable population equilibrium. However, it seems that in many situations, such a phenomenon does not arise, and the combined population dynamics and individual migration will converge to the IFD (e.g., Holt and Barfield 2001; DeAngelis et al., forthcoming). From our theoretical analysis, it seems that several factors must be considered in order to understand the mechanisms that govern animal distribution. First, it is important to know whether the observed (approximate) IFD distributions are primarily due to animal migration or to population dynamics. This requires a knowledge of the biological system's spatial scales and timescales, which are ultimately based on distances between patches and on migration versus demographic rates of change, respectively. When total population size changes slowly and patches are close to each other (these conditions correspond to most typical experimental settings within which the IFD has been observed), it will be predominantly animal migration that drives the population distribution to the IFD. On the other hand, if patches are far apart and migration is a slow process, it is more likely that population dynamics will be the predominant mechanism if the IFD is observed. Second, it is also important to disentangle the effect of migration for IFD reasons from migration for non-IFD reasons. Because migration rates are difficult to measure (but see Donahue et al. 2003) , this is a challenging task for ecologists. However, such a separation is necessary in order to weigh the contributions of random migration, balanced dispersal, and frequency-dependent migration. For instance, we have shown in this article that frequencydependent migration of individuals can continue once the IFD is reached and, conversely, that a combination of ideal animals with random migration does not always lead to undermatching. Moreover, even if animals move only for IFD reasons, migration rates can be difficult to predict (e.g., migration rates for myopic animals are not always uniquely defined; see fig. 1B ). These issues need to be analyzed further to develop individual-based models of habitat choice for particular biological systems.
However, on a formal level, it is only recently that a rigorous proof was given REF , and even this proof was with respect a limited definition of ESS (essentially, in our notation, they proved the first item of the characterization with m π = k − 1, without considering the second item).
Migration dynamics for the ideal free distribution.
The American naturalist
The American naturalist
Biology Medicine