Impact of herbivore preference on the benefit of plant trait variability

We explore the hypothesis that intraspecific trait variability can be per se beneficial for the plant when the curvature of the herbivore response to this trait is concave downwards. This hypothesis is based on a mathematical relation for nonlinear averaging (Jensen’s inequality), leading to reduced herbivory when the trait distribution becomes broader. Our study introduces and investigates a model for plants and their insect herbivores that includes an unequal distribution of nutrient content between leaves. In contrast to earlier publications, we take into account the ability of herbivores to choose leaves, and the associated costs of this preference behavior. By performing computer simulations and analytic calculations, we find that this herbivore preference can considerably alter the conclusion cited above. In particular, we demonstrate that herbivore populations that show preference for leaves on which they grow well can benefit from large nutrient-level variability independently of the curvature of the herbivore response function, despite the cost for preference.

One hypothesis why intraspecific trait variability can have such effects on ecological systems is that it leads to nonlinear averaging according to Jensen's inequality (Okuyama, 2008;Bolnick and Amarasekare et al., 2011;Ruel and Ayres, 1999;Wetzel and Kharouba et al., 2016): If we consider a function that represents a response (for instance herbivore performance) to the trait value, this function can be concave upwards (i.e., increasing slope, positive curvature) or concave downwards (i.e., decreasing slope, negative curvature). Let us assume that the distribution of traits is a peaked function characterized by its mean and variance. Jensen's inequality (Jensen, 1906) states that the mean response calculated for this trait distribution is larger than the response associated with the mean trait value when the function is concave upwards. The opposite is true for a concave downwards function. Hence, populations with the same mean trait but with different trait variances can experience different mean responses (Bolnick and Amarasekare et al., 2011) and therefore different dynamics. Indeed, Jensen's inequality (or Jensen's effect) is cited in various ecological contexts, for example in the case of a nonlinear relationship between attack rates and body sizes or nutrient concentration and chemostat population growth (Bolnick and Amarasekare et al., 2011). Jensen's inequality is also used to explain why variance in temperature elevates poikilotherm metabolic rates (concave upwards function), why variance in light regimes depresses primary production (concave downwards function), and why variance in tissue quality and secondary metabolites affects herbivore response (Ruel and Ayres, 1999). Furthermore, several authors refer to Jensen's inequality to explain the large variability in plant traits (Herrera, 2009;Siefert and Violle et al., 2015;Coleman and McConnaughay et al., 1994;Albert and Thuiller et al., 2010a;Albert and Thuiller et al., 2010b).
In particular, Wetzel and Kharouba et al. (2016) used Jensen's inequality to argue that plant trait variability is per se beneficial for the plant when the herbivore feeding rate is a concave downwards function of this trait. In this case, Jensen's inequality states that the mean herbivore response is smaller when the trait values of plant leaves vary around a mean than when all leaves have this mean trait value. In a meta-study, Wetzel and Kharouba et al. (2016) indeed found that herbivore response is in the majority of cases a concave downwards function of the leaf nutrient level, but linear (Ayres and Suomela et al., 1987) or complex herbivore response functions having both concave upwards and concave downwards regions (Clancy, 1992) were also found. A reason for these divergent results may be that the curvature of the herbivore response function depends on the considered nutrient, herbivore (Ali and Agrawal, 2012), nutrientlevel range (Clancy, 1992;Miles and Aspinall et al., 1982;Ohmart and Stewart et al., 1985), and the age of the herbivore individuals (Scriber and Slansky, 1981;Ohmart and Stewart et al., 1985;Montgomery, 1982;Zalucki and Clarke et al., 2002).
Performance functions for consumers over a very wide range of nutrient concentrations are typically represented by optimum curves with a maximum at intermediate nutrient levels, also known as Bertrand's rule (Bertrand, 1912) and applicable to various micro-and macronutrients (Mertz, 1981;Raubenheimer, 2005;Zehnder and Hunter, 2009;Joern and Behmer, 1997;Fischer and Fiedler, 2000;Joern and Behmer, 1997;Boersma and Elser, 2006;Wetzel and Kharouba et al., 2016). The increasing benefits from an increased uptake of essential nutrients are clear: They accelerate for very low nutrient concentrations from a zero performance and decelerate when approaching the optimum. Depending on the segment along the concentration gradient, the function is concave up, linear or concave down. Beyond the maximum, the costs of excessive nutrient consumption may involve imbalances across different nutrients (Simpson and Raubenheimer, 1993), higher doses of associated defensive chemicals (Simpson and Raubenheimer, 2001;Tao and Berns et al., 2014), dose-dependent toxicity, and even increased mortality (Raubenheimer, 2005). For instance, when leaves with higher nutrient content are more strongly defended, this results in trade-offs between the benefit of higher nutrient content and the cost of dealing with defenses (Boersma and Elser, 2006;Raubenheimer and Simpson et al., 2009). Increased metabolic costs for excreting or storing surplus macronutrients such as carbohydrates may even limit a consumer's total intake despite a resulting limitation of other essential nutrients (Raubenheimer, 2005;Lee and Raubenheumer et al., 2004).
A fact not considered in the studies mentioned above is that herbivores are able to adaptively respond to changes in their environment, such as the plant nutrient-level distribution, via their mobility and foraging behavior. In fact, herbivore preference is one important way to respond to trait distribution in the resource (Via, 1986;Herrera, 2009). It can appear in different forms: Herbivores can have feeding preference for leaves on which they perform best. This requires mobility to reach appropriate leaves (Mody, 2007;Lubchenco, 1978). Different species can have different types of feeding preferences: For example, generalized stick insects (Phasmatodea) prefer older leaves, while specialized species prefer younger leaves within the same food plant (Blüthgen and Metzner, 2007). A third preference pattern is found in specialized lasiocampid caterpillars that move between host plant individuals to achieve a balanced diet (Mody, 2007). Herbivores can also show oviposition preference for leaves on which their offspring perform best (Soto and Goenaga et al., 2012;Tilmon, 2008;Gripenberg abd Mayhew et al., 2010), even though this preference is often imperfect: There can occur mismatches between oviposition preference and offspring performance (Valladares and Lawton, 1991;Gripenberg abd Mayhew et al., 2010;Hufnagel and Schilmiller et al., 2017), for instance be due to limited discrimination capability of parents (Barbosa and Hines et al., 2009) or to avoidance of larval competition (Scheirs and Bruyn et al., 2000;Scheirs and De Bruyn, 2002).
Up to now, theoretical models for adaptive feeding behavior focus on consumers that choose among several prey or resource species: Such models have shown that adaptive behavior can promote the coexistence of competing consumers (Krȋvan, 2003) as well as of competing prey or resources (Krȋvan and Eisner, 2003), but can also prevent coexistence (Feng and Liu et al., 2009). Furthermore, adaptive behavior was shown to affect the link-species relationship (Matsuda and Namba, 1997;Matsuda and hori et al., 1994;Matsuda and Hori et al., 1996) and to promote the persistence of species (Van Baalen and Krȋvan et al., 2001) and the stability of food webs (Genkai-Kato and Yamamura, 1999;Genkai-Kato and Yamamura, 2000;Kondoh, 2006;Uchida and Drossel et al., 2007;Valdovinos and Ramos-Jiliberto et al., 2010;Heckmann and Drossel et al., 2012).
However, less is known about the impact of herbivore preference on an intraspecific (or even intra-individual) level, although several empirical studies find that preference occurs on this level (Whitham, 1980;Mody, 2007;Gutbrodt and Dorn et al., 2012;Rausher, 1979;Herrera, 2009;Herrera, 2017). In particular, it has not been explored so far how herbivore preference affects the impact of intraspecific plant trait variability on herbivore fitness.
In this paper, we want to fill this gap. We propose a plant-herbivore model that includes plant nutrient-level variability and herbivore preference and is valid for intraindividual and inter-individual nutrient-level variability as well as for feeding and oviposition preference. Based on the study of Wetzel and Kharouba et al. (2016), we investigate how plant nutrient-level variability affects the performance of the herbivore population depending on the curvature of the herbivore response function. We couple herbivore preference with corresponding costs for finding appropriate leaves (Tilmon, 2008).
In order to distill the effect of intraspecific trait variability per se, we focus on one trait, namely the nutrient level in the plant leaves, and neglect possible correlated variations in secondary metabolites. For the same reason, we only model the herbivore population and neglect higher trophic levels. Furthermore, we assume that the plant population is sufficiently large that it can be considered as constant over the time span covered by the model.
We show that herbivore preference crucially affects the predictions of Wetzel and Kharouba et al. (2016) that are based on Jensen's inequality. More precisely, we find that when a herbivore population has a strong preference, it benefits from large plant trait variability irrespective of the curvature of the response function. In addition to computer simulations, we show this also analytically. Furthermore, we show that the optimal extent of herbivore preference is larger when the performance function is concave upwards than when it is concave downwards.

Model
Our model is a phenomenological model that evaluates herbivore fitness based on its biomass increase during a season, which in turn depends on the distribution of the nutrient level and on herbivore preference. We consider insect herbivores feeding on a plant population whose leaves show a distribution p(n) of the nutrient level n. The model does not include interspecific interactions or intraspecific density dependence, in contrast to the study by Whitham (1980). It thus describes situations where there is abundant consumable plant material, that allows exponential growth. However, part of the effects of competition could be accounted for by adjusting the herbivore performance and preference functions, and factors external to the model can be presumed to limit overall growth. By focusing on nutrient concentration as the only trait, we make an unrealistic simplification. Nutrients represent a trait that is costly and has a positive effect on consumers. We do not include mechanical (e.g., leaf thickness, hairs, thorns) or chemical defenses which will require different model approaches. Nutrients and defenses always occur together and may face various trade-offs. Nevertheless, studying the consumer's response to nutrients is a meaningful first step that provides valuable insights.
The model also ignores details of the search and growth dynamics during the season and changes in the nutrient distribution p(n), as neither is relevant for the overall message.

Herbivore fitness
The central quantity to be evaluated is herbivore population fitness, since it is a direct indicator of herbivore population growth. The mean fitness W H of a herbivore population is defined as the mean number of offspring per herbivore individual reaching reproductive age. Denoting the distribution of herbivore individuals on leaves with nutrient level n as Φ(n) and the fitness of a herbivore individual feeding on a leaf with nutrient level n as W H (n) , the mean population fitness can be expressed as with n ∈ [0, n max ] . Note that the nutrient level n can also be understood as a mean when herbivores consume multiple leaves from hatching to pupation. The fitness W H (n) of a herbivore individual feeding on a leaf with nutrient n depends on the growth of the herbivore on this leaf, which we will express in terms of a performance function f(n). We define the performance function f(n) as the weight gain of a herbivore individual feeding on a leaf with nutrient level n from hatching to pupation. The different types of performance functions used in our study will be specified further below. If we assume that the number of offspring that reach reproductive age is proportional to this weight gain, the fitness W H (n) of a herbivore individual feeding on a leaf with nutrient level n is given by with H being the number of offspring per unit of weight gain.

Distribution of herbivore individuals on leaves
The distribution Φ(n) of herbivore individuals on leaves with nutrient level n depends on the one hand on the nutrient-level distribution p(n), and on the other hand on a preference function Φ p (n) that quantifies the extent of preference for leaves with nutrient level n. Since we assume that intraspecific competition for food is negligible, the distribution is obtained by multiplying the preference function with the leaf abundance and normalizing the result, leading to

Nutrient distribution
For the nutrient level distribution p(n) among leaves, we assume a Gaussian distribution with a mean in the middle of the considered nutrient-level interval n ∈ [0, n max ] , i.e., at n = n max ∕2 . This is motivated by the fact that continuous traits often show a Gaussian distribution (Meglioli and Villagra et al., 2016) or are assumed to be Gaussian distributed (Kattge and Knorr et al., 2009;Barber and Kiers et al., 2013). If the distribution is different, for instance lognormal, the logarithm of the trait is Gaussian distributed and should be chosen as variable n.
The variance V S of this distribution determines the degree of heterogeneity of the nutrient distribution. We introduce the trait variability parameter such that S = 1 represents a uniform distribution over the considered nutrient-level interval, i.e., that all nutrient levels in the considered range appear with equal frequency. A variability parameter S = 0 represents a delta distribution, meaning that all leaves of all plant individuals have the nutrient level n =n . Fig. 1(c) shows the nutrient distribution p(n) for different plant trait variability parameters S.
The total amount of nutrients being available for the herbivore population is kept constant in our investigation, so that a change in trait variability S arise solely from a redistribution of nutrients between the leaves.

Preference function
The preference function Φ p (n) can be interpreted as the probability that an adult herbivore lays eggs on a leaf with a nutrient level n when encountering it. We model this function via a Gaussian distribution with its mean at the performance maximum of the herbivore population and a variance V p that is smaller when the preference is stronger.
Since preference is a quantitative trait, a Gaussian distribution is the natural distribution to choose; for other distributions, we do not expect a qualitative change of our results. We define the preference parameter such that = 0 stands for no, and = 1 for full preference.
In the latter case, preference function is a delta distribution which describes the unrealistic extreme case that only those leaves are used for oviposition on which the herbivore population reaches its performance maximum. Fig. 1(e) and (f) shows the preference function Φ p (n) for different preferences for the case that the performance maximum occurs at maximum nutrient level (e) or at intermediate nutrient level (f). Instead of oviposition preference, the preference function can also indicate a feeding preference. In this case, the preference function Φ p (n) describes the probability that a herbivore feeds on a leaf with nutrient level n when encountering it. Note that the preference function is a population average, such that diverging preferences of herbivore individuals or an incapability to discriminate leaf traits properly lead to a low population preference . Furthermore, fewer herbivore individuals feed on high-quality leaves when these become rare (i.e., with decreasing plant trait variability parameter) S, even when the value of (i.e., the degree of preference) is not changed, since less herbivore individuals encounter these high-quality leaves (cp. Fig. 1(g)).
Preference comes with a cost for finding appropriate leaves. We take this cost into account in form of a mass loss of the herbivore population. Other types of costs for finding leaves, for instance an increased loss to predation or the laying of less eggs, would also lead to reduced offspring production and therefore to a similar expression for the reduction of mean fitness.
Since we want to explore the effect of this cost, we describe the relative mass loss of the herbivore population by a function that allows us to interpolate between 0 and 1 in different ways by changing the parameters of this function. In this way, we can make sure that unrealistic extreme cases of the preference function, such as a delta distribution, do not lead to survival of the herbivore population. We thus define the relative mass loss due to preference as  5)) for the case that performance is best at high nutrient concentrations (c) and at intermediate nutrient concentrations (d)

. (g), (h)
Distribution Φ(n) of herbivore individuals on leaves with nutrient level n (cp. Eq. (3)) for different trait variability parameters S (cp. Eq. (4)) and a herbivore preference = 0.25 (cp. Eq. (5)) for the two situations that performance is best for high or intermediate nutrient concentrations. This is the (normalized) product of the orange curve in (e), (f) with the three different curves in (c), (d). (i), (j) Distribution Φ(n) of herbivore individuals on leaves with nutrient level n (cp. Eq. (3)) for different herbivore preferences (cp. Eq. (5)) and a trait variability parameter S = 0.25 (cp. Eq. (4)) for the two situations that performance is best for high or intermediate nutrient concentrations. This is the (normalized) product of the orange curve in (c), (d) with the three different curves in (e), (f) where larger means that the cost of preference is larger, and large k means that the costs are mainly incurred when preference is large. Fig. 5 in Appendix shows the factor 1 − ( ) by which mass is decreased due to preference for different values for and k.
Including this cost changes the expression Eq. (1) for the mean fitness of the population to where Γ normalizes again the distribution Φ(n) of herbivore individuals on leaves with nutrient n to 1. Fig. 1(g)-(j) shows the distribution Φ(n) of herbivore individuals on leaves with nutrient content n for varying plant trait variability parameter S and varying preference , respectively. Wetzel and Kharouba et al. (2016) argued that the curvature of the herbivore performance function determines whether a herbivore benefits or suffers from plant trait variability. In order to test this idea, we will use performance functions with different shape. These performance functions are shown in Fig. 1(a) and (b). On the one hand, we choose monotonically increasing functions with different curvature; on the other hand, we choose parabolic functions with the maximum at an intermediate nutrient level. Since the nutrient-level distribution in our model is a Gaussian function around a mean nutrient level, a monotonically increasing performance function means that the range of nutrient concentrations present in the plant is below the value that is optimal for the herbivore, i.e., the best leaves are rare and leaves of intermediate quality are most common. When, however, the range of nutrient concentrations of the plant is that of maximum herbivore performance, the performance function should have its maximum at intermediate nutrient level in our model.

Performance function
The latter unimodal curves are assumed in many studies focusing on variation in single macro-or micronutrients over a broad range of concentration levels, including direct or indirect costs of nutrient excess at high doses (Mertz, 1981;Raubenheimer, 2005;Zehnder and Hunter, 2009;Joern and Behmer, 1998;Wetzel and Kharouba et al., 2016). However, monotonically increasing performance functions are similarly realistic and informative depending on the segment of the concentration levels chosen, or for specific definitions of nutrient levels (e.g., as a measure of proximity to a consumer's optimal nutritional target, (see Simpson and Raubenheimer, 1993)). Note that trade-offs with defenses or among competing nutrients may not be pronounced or may be disregarded when trying to understand nutrient variability alone.
The performance curves are parametrized such that the mean performance is the same in all cases, so that the resulting mean fitness values are of the same order of magnitude.

Choice of parameter values
We chose the nutrient level range to be n ∈ [0, 10] , such that the mean nutrient level is n = 5 . By choosing appropriate units for the nutrient level, every nutrient level interval can be mapped onto this one. As we want to investigate whether nutrient-level variability is per se beneficial or disadvantageous for the herbivore population, we keep the mean nutrient-level constant and just alter the plant trait variability parameter S, i.e., the variance of the nutrient-level distribution.
For the cost of preference, Eq. (6), we choose the parameters = 1 and k = 2 , such that the costs for a moderate level of preference remain moderate, but become considerable for high preference. In order to find an appropriate value for the number of offspring per unit of growth, H , we choose the forest tent caterpillars (Malacosoma disstria) as model species. Malacosoma disstria has a typical mass gain until pupation of 300 mg and produces around 300 eggs with a survival rate of 1/100 resulting in a number of offspring reaching the reproductive age per growth unit of H = 0.01 1 mg (Hemming and Lindroth, 1999). Furthermore, we normalize the mean performance of all functions to 300 mg, i.e., ∫ n max 0 f (n) dn = 300 . The Discussion section makes clear that the general results depend only on the general features of the model, but not on the detailed choice of parameter values. Nevertheless, we present in Appendix a robustness study, where we vary several features of the model.

Results
We divide our investigation into two parts. In a first step, we analyze the herbivore fitness (cp. Eq. (7)) in dependence of the trait variability parameter S (cp. Eq. (4)) and the shape of the performance function without herbivore preference, i.e., for = 0 (cp. Eq. (5)). These results can be compared to previous studies (Wetzel and Kharouba et al., 2016;Ruel and Ayres, 1999;Bolnick and Amarasekare et al., 2011) and will serve as a reference for the second part of our investigations. In the second step, we investigate the effect of herbivore preference, > 0 , on these results, and we will show that herbivore preference modifies the conclusions and assumptions in (Wetzel and Kharouba et al., 2016;Ruel and Ayres, 1999;Bolnick and Amarasekare et al., 2011).

The effect of plant trait variability on herbivore fitness in absence of herbivore preference
We first consider the situation that the herbivore population shows no preference, i.e., = 0 and therefore the massloss factor ( ) = 0 , see (6). Hence, the preference function Φ p (n) is a uniform distribution such that the distribution of herbivore individuals on leaves with nutrient level n is Φ(n) = Γp(n) (cp. Eq. (3)) and the expression for the mean fitness (cp. Eq. (7) and Eq. (2)) simplifies to Herbivore fitness for the case = 0 is shown in Fig. 2 along the left edge of the five subfigures. One can see that the curvature of the performance function determines whether the herbivore population benefits or suffers from high nutrientlevel variability (i.e., high S). The result is as expected: In the case of a concave upwards performance function the herbivore population is fitter (i.e., the color indicating fitness becomes darker) when nutrient-level variability is larger, while the opposite is true in the three cases of a concave downwards performance functions. For the linear performance function f lin , the trait variability parameter S has no influence on herbivore population fitness.
These results can be understood using Jensen's inequality (Jensen, 1906), which states that a concave upwards function of the mean value of a set of points x i is less or equal to the mean value of the concave upwards function of these points, i.e., f The opposite is true for a concave downwards function, and for a linear function f both values are the same. Consequently, we can deduce that ∫ f (n)p(n) dn ⪌ ∫ f (n) (n −n) dn = f (n) , depending on the curvature of f, whenever S > 0 , which means that the Fig. 2 Herbivore fitness (i.e., mean number of offspring per herbivore individual reaching reproductive age; cp. Eq. (7)) displayed in color code in dependence of the plant trait variability parameter S (cp. Eq. (4)) and herbivore preference (cp. Eq. (5)) for the five different performance functions shown in Fig. 1(a) and (b). The performance functions are shown in the small insets nutrient distribution has a nonzero width (cp. Eq. (4)). The difference between the two sides of the inequality becomes larger when the curvature of f is larger in the relevant range of n values, as can be seen in Fig. 2, where the color change along the = 0 axis is largest in (a) and (d).
For further understanding, we reconstruct these results analytically. Additionally, the calculation will act as a basis for the following part, where we investigate the impact of preference on these results. We calculate the mean fitness (cp. Eq. (8)) as a function of the trait variability parameter S (cp. Eq. (4)) when the herbivore has no preference (i.e., = 0 ). In order to do this, we approximate the performance functions by a polynomial in n, the curvature of which depends on a parameter c, i.e., with the curvature parameter c and a ≥ 0 . The performance function is concave upwards when c > 0 , linear when c = 0 , and concave downwards when c < 0 . Both performance functions f pos and f neg (cp. Fig. 1(a)) can be transformed to the performance function defined above with c > 0 and c < 0 , respectively, by using a Taylor expansion around the mean nutrient level n , appropriately choosing the parameter a, and neglecting constant terms since they have no qualitative impact on the fitness landscape. Starting with Eq. (8), we find where we substituted b = 1 2V S , x = n −n , and I = Γ ∫̄n −n x 2 e −bx 2 dx . Remember that Γ −1 = ∫̄n −n e −bx 2 dx is the normalization factor. For b = ∞ , which is equivalent to V S = 0 , we have W H = W 0 , which means that W 0 is the mean herbivore fitness when all plant leaves have the trait value n . As we want to know how an increase of V S changes the mean herbivore fitness, we can focus on the case of small V S , where the integration limits can be moved to ±∞ , since the nutrient distribution is very close to 0 at the boundaries of the integration interval. This approximation is consistent with the Taylor expansion of the performance function, which is a good approximation only if relevant interval of n values is small. The integral can be executed for instance by integration by parts, giving I = 1∕2b . By inserting b = 1−S 2S (cp. Eq. (4)) we find a particularly instructive form of the result, This result shows that the curvature parameter c determines whether the mean fitness increases or decreases with increasing V S , i.e., with decreasing b. This increases for positive c and decreases for negative c, as it must be according to Jensen's inequality. This holds also for larger V S , since dI∕db < 0 also for finite integration limits. The result (11) also shows why mean herbivore fitness does not depend on the nutrient-level variability when considering a linear performance function f lin (i.e., c = 0 ). This calculation applies also for performance functions that do not increase monotonically, as the performance function for negative c becomes a concave downwards parabola over the considered range of nutrient concentrations when |c| is sufficiently large.

The effect of herbivore preference
As a second step, we now take herbivore preference into account. Fig. 2 shows the mean herbivore population fitness W H (cp. Eq. (1)) displayed in color code as a function of the herbivore preference (cp. Eq. (5)) and the trait variability parameter S (cp. Eq. (4)) using the five different performance functions shown in Fig. 1(a) and (b). When herbivores have a preference for leaves on which they perform better, the curvature of the performance function is not the only factor determining whether the herbivore population benefits or suffers from large plant nutrientlevel variability. The mean herbivore fitness increases with increasing trait variability parameter S for all possible preferences ∈ (0, 1) when the performance function is concave upwards f pos (cp. Fig. 2(a)), as can be seen from the change from lighter to darker color with increasing S. For the linear performance function, herbivore fitness becomes dependent on plant trait variability as soon as there is a nonzero preference, see Fig. 2(b). Just as for the concave upwards performance function, herbivore fitness then increases with plant trait variability.
For the three concave downwards performance functions, herbivore fitness decreases with increasing plant trait variability for small preference values , as for the case = 0 . However, when the preference becomes stronger, this trend can be reversed. It is reversed for the monotonically increasing performance function (cp. Fig. 2(c)) as well as for the second of the two peaked performance function (cp. Fig. 2(e)). This means that preference for leaves on which performance is better can undo the disadvantage that herbivores experience when plant traits are distributed more broadly. However, when the performance maximum coincides with the maximum of the nutrient distribution, an increased plant trait variability always reduces herbivore fitness, irrespective of the extent of preference (cp. Fig. 2(d)).
The preference value at which herbivore fitness has its maximum value in the different graphs is largest for the concave upwards performance function and much smaller for the concave downward ones. This means that the benefit for the herbivore of having a preference is largest when its performance function is concave upwards. This must be due to the fact that the performance gain due to preference is largest in this case, so that it can override the cost of having a preference.
Furthermore, Fig. 2 shows interesting trends with S of the fitness maximum at a given S: Of course, if there is no plant trait variability herbivore fitness is largest in the absence of preference. Therefore, the darkest color along the S = 0 axis occurs at = 0 . The fitness maximum at a given value of S is found by following the horizontal line for this S value and finding the range with the darkest color. For the concave upwards and linear performance functions, the preference value that maximizes fitness increases with S when S is small and decreases again with S when S is large. This decrease for large S must be due to the fact that already a small increase in preference leads to a substantial fitness increase when plant trait variability is large. In this situation, the benefit of increasing further is not large and is compensated by the costs of preference. These trends can be seen even more clearly in Fig. 4(c) in Appendix. The other subfigures of this figure show additionally how a change of the parameters that determine the cost of preference affects these trends.
In contrast, the fitness-maximizing preference value increases with S for all three concave downwards performance functions. This means that the herbivore can compensate best for increased plant trait variability by increasing its strength of preference. Nevertheless, the maximum fitness that the herbivore can achieve in this way decreases with increasing plant trait variability.

Analytic calculations with preference
In the previous section, we found that herbivore populations benefit from large nutrient-level variability irrespective of the curvature of the performance function when having considerable preference for leaves with high nutrient level. In order to understand this result and to demonstrate that this finding is generic, we calculate the mean fitness W H (cp. Eq. (1)) under the assumption that the nutrient-level distribution is narrow. In this case, the preference function Φ p (n) can be Taylor expanded, and for a small preference value we have where is a scaling factor. As in the previous section, we use the performance function f (n) = an + cn 2 , with the curvature parameter c. We find (12) Φ p (n) = ( n + 1) , where we again defined b = 1 2V S , x = n −n , and I = Γ ∫̄n −n x 2 e −bx 2 dx . The mass loss due to preference must be proportional to the preference for small , i.e., = .
Hence, by keeping the leading terms in c and and simplifying again the integral by sending the integration limits to ±∞ so that I → 1∕2b = S∕(1 − S) , we obtain Consequently, as soon as the herbivore population exhibits some preference ( > 0 ), the mean fitness W H increases with increasing nutrient-level variability (i.e., increasing S or decreasing b) when the performance function is linear (i.e., c = 0 ). This means that the herbivore population benefits from large nutrient-level variability. Furthermore, when we consider a concave downwards performance function f neg (i.e., c < 0 ), the mean fitness increases with increasing variability (i.e., increasing S or decreasing b) when |c| < a . Hence, when |c| = a , herbivore fitness is independent of the trait variability parameter S. This corresponds to the observations from computer simulations shown in the previous section. Again, the result is still valid when the integration limits are finite since dI∕db < 0.

Discussion
In the present paper, we proposed a plant-herbivore model that includes herbivore preference and plant nutrient-level variability, and we investigated the impact of these features on herbivore fitness depending on the curvature of the herbivore performance function. Since our model is generic and includes the relevant features in a general and plausible form, it is valid for intra-and inter-individual nutrient-level variability as well as for oviposition preference and feeding preference in the larval stage. The trait variability in our model describes spatial (and not temporal) variation of the nutrient concentration, although several factors that influence nutrient content, such as leaf age, position and exposition to light vary in time as well as in space (Blüthgen and Metzner, 2007;Coley and Barone, 1996). If the nutrient concentration changed considerably (13) 2V S an + cn 2 ( n + 1) =qΓ(1 − ) ∫̄n −n dx e −bx 2 a(x +n) + c(x +n) 2 ( (x +n) + 1) =q(1 − ) W 0 (n + 1) + (c + (a + 3cn))I , during the ontogeny of a herbivore individual, a time-integrated version of our model would be appropriate.
In the context of our modelling framework, we neglected intra-or interspecific competition among herbivores. For most herbivorous insects, this assumption is realistic under many circumstances, given that their biomass and consumption is very small compared to a large amount of plant material except for a few species or outbreaks. Consistent with the "green world hypothesis" (Hairston and Smith et al., 1960;Slobodkin and Smith et al., 1967), this suggests that herbivore populations are regulated by predators, plant defenses, or unfavorable weather rather than competition for food. Despite their importance, the present model also neglects these density-limiting factors. Therefore, it only applies to situations where density-limiting factors affect all individuals in the same way, regardless of their specific characteristics. In an accompanying paper (Thiel and Gaschler et al., 2020), we include variation in defenses and predation pressure.
In the case of no herbivore preference ( = 0 ), we found that the fitness of the herbivore population decreases with increasing plant nutrient-level variability when the herbivore performance function is concave downwards (i.e., decreasing slope, negative curvature), but increases in the case of a concave upwards performance function (i.e., increasing slope, positive curvature). Indeed, this can be shown by a simple analytic calculation. So far, our findings agree with other authors who attribute this effect to Jensen's inequality (Wetzel and Kharouba et al., 2016;Bolnick and Amarasekare et al., 2011;Ruel and Ayres, 1999).
This calculation shows also that two conditions must be satisfied for the conclusion to be valid: The effect of plant trait variability must be considered at constant mean trait value and the plant trait distribution must be peaked around this mean. These two conditions are satisfied by our model. When mean nutrient concentrations change in addition to the variance, this leads to additional effects (Wetzel and Thaler, 2018).
The straightforward conclusion by Wetzel and Kharouba et al. (2016) and Ruel and Ayres (1999) becomes less convincing when herbivore preference is taken into account. We found that herbivore populations benefit from high nutrient-level variability irrespective of the curvature of the performance function when having a suitable extent of preference for leaves on which their performance is high. The intuitive explanation for these findings is that a herbivore having a sufficiently strong preference can obtain more leaves with higher nutrient level when variability is larger, leading to a fitness increase as long as the cost for preference is not too high. Indeed, this type of herbivore preference is often observed (Via, 1986;Herrera, 2009;Herrera, 2017;Tabashnik and Whellock et al., 1981;Travers-Martin and Müller, 2008;Despres and David et al., 2007;Rausher, 1979;Leyva and Clancy et al., 2003;Lubchenco, 1978;Mody, 2007).
The only exception to these findings is the case where the performance function has a local maximum that coincides with the mean nutrient level, see Fig. 2(d). In this case herbivore fitness decreases with increasing nutrient-level variability irrespective of the extent of preference.
We tested the robustness of our results under changes of the preference mean in order to mirror the case that herbivores cannot assess perfectly leaf quality. We found qualitatively the same results as long as herbivores prefer highquality leaves (i.e., leaves where herbivore performance is high).
All this means that the relation between the curvature of the herbivore performance function and the effect of nutrient-level variability on herbivore fitness is more complex than previously thought. It requires a closer look at herbivore preference, the effect of which depends on (i) the cost for finding appropriate leaves (s. Fig. 4 in Appendix), (ii) the sign and magnitude of the curvature of the performance function in the relevant trait range (s. Fig. 3 in Appendix), and (iii) the plant nutrient-level variability.
Indeed, empirical studies support these dependencies: They find that more specialized species have a stronger preference for leaves on which their performance is high than more generalized species (Gripenberg abd Mayhew et al., 2010;Tilmon, 2008;Soto and Goenaga et al., 2012). In our model, herbivores that can grow well only on a relatively small nutrient-level interval (because the performance function is concave upwards, or because its curvature is large) are the ones with the larger optimum preference because they benefit most from preference. Some studies find furthermore that the preference to lay eggs on leaves where the offspring performs well is stronger when high-quality resources are rare (Tilmon, 2008), in agreement with our finding that optimal herbivore preference increases with decreasing plant nutrient-level variability when the performance function is concave upwards or linear as long as variability is not too low (which would probably be unrealistic anyway). Additionally, some studies show that herbivores that perform best on the most frequent leaves (i.e., that have a peaked performance function) benefit less from showing preferences than those that perform best on rare leaves (i.e., that have a monotonically increasing performance function) (Tilmon, 2008). This is in agreement with the trends observed in our model.
Our results do not necessarily imply that plant trait variability is a disadvantage for the plant when herbivores can exploit this variability by showing preference for high-nutrient leaves. Plant trait variability may benefit the plant population for reasons independent of the herbivore. For example, Kotowska and Cahill et al. (2010) found that plant genetic diversity increases both plant and herbivore survival and biomass. Furthermore, the increase in plant biomass and survival was found in both the presence and absence of herbivory, whereby the percentage increase was lower in the presence of the herbivore (Kotowska and Cahill et al., 2010). Hence, Fig. 3 (a),(c) The considered performance functions that differ in the magnitude of their curvature: (a) f opt,low = 9 11 (14n − n 2 ) , (c) f opt,high = max(0, 900 63+20 √ 10 � 14n − n 2 − 39 � ) .
(b),(d) Herbivore fitness (i.e., mean number of offspring per herbivore individual reaching reproductive age; cp. Eq. (7)) displayed in color code in dependence of the plant trait variability parameter S and herbivore preference considering f opt,low in (b) and f opt,high in (d) as performance function Fig. 4 Herbivore preference for which herbivore fitness is maximized for a given plant trait variability parameter S considering different parameters ((a), (c), (e)) and k ((b), (d), (f)), that shape the mass loss due to preference ( ) between the limits → 0 and → 1 (cp. Eq. (6)). Larger means that the cost of preference is larger, and large k means that the costs are mainly incurred when preference is large. The different markers represent the three different performance functions f(n) shown in Fig. 1(a). The color shades in the markers display the mean fitness of the herbivore population under the particular circumstances genetic diversity is beneficial for a plant population for other reasons than herbivory. Due to non-additive effects, the productivity in genetic mixtures is not predictable by the productivity of the corresponding monocultures (i.e., each consisting of a genotype used in the genetic mixtures) (Kotowska and Cahill et al., 2010). For instance, different resource uptake strategies may decrease intraspecific competition in genetic mixtures (Kotowska and Cahill et al., 2010;Crutsinger and Collines et al., 2006).
Additionally, the plant population may benefit from large intraspecific plant trait variability in spite of herbivore preference when different herbivores have preference for different associated traits for instance due to differing specialization strategies (generalist vs. specialist) (Gutbrodt and Dorn et al., 2012) or as a response to drought and associated changes in secondary defense compounds (Gutbrodt and Mody et al. , 2011). In this case the mean preference of these herbivores is low.
To summarize, our study yields conditions for the validity of the hypothesis by Wetzel and Kharouba et al. (2016) that the large plant nutrient-level variability found in nature leads to decreased herbivory since herbivore performance functions typically have a concave downwards curvature. We showed that this is true when the herbivore population has low preference for high-nutrient leaves, when cost for preference is high, or when herbivores perform best on the most frequent leaves. However, when herbivore preference is strong, nutrient-level variability may not per se lead to decreased herbivory. As discussed above, this, however, does not necessarily imply that large nutrient-level variability is a disadvantage for the plant. In order to investigate this issue, a different approach is needed that considers coevolution of plant nutrient-level variability and herbivore preference, and the complex interaction with co-varying traits such as defenses or trade-offs between single macro-and micronutrients.
Funding Open Access funding enabled and organized by Projekt DEAL.
Open Access This article is licensed under a Creative Commons Attribution 4.0 International License, which permits use, sharing, adaptation, distribution and reproduction in any medium or format, as long as you give appropriate credit to the original author(s) and the source, provide a link to the Creative Commons licence, and indicate if changes were made. The images or other third party material in this article are included in the article's Creative Commons licence, unless indicated otherwise in a credit line to the material. If material is not included in the article's Creative Commons licence and your intended use is not permitted by statutory regulation or exceeds the permitted use, you will need to obtain permission directly from the copyright holder. To view a copy of this licence, visit http://creat iveco mmons .org/licen ses/by/4.0/.

Appendix A Robustness tests
A.1 Influence of the magnitude of the curvature of the performance function We showed in Section 3.2 that the sign of the curvature affects the extent of optimal herbivore preference. It is plausible that the magnitude of the curvature also has an effect on optimal herbivore preference. In order to test this hypothesis, we use the performance functions shown in Fig. 3(a), (c). The curvature is higher in (c) than in (a). A performance function with a larger curvature is for instance appropriate when the herbivore is more specialized since it can only grow well on a smaller range of nutrient concentrations. We normalized again the mean performance of the two functions to 300 mg, i.e., ∫ n max 0 f (n) dn = 300 , but the results do not depend qualitative in this normalization. Fig. 3(b), (d) shows the mean fitness of a herbivore population W H (cp. Eq. (1)) displayed in color code as a function of the herbivore preference (cp. Eq. (5)) and the trait variability parameter S (cp. Eq. (4)), using these two performance functions.
The optimal herbivore preference is higher for all variability parameters S when the herbivore performance function has a higher curvature, i.e., f opt,high (cp. Fig. 3(a), (c)) as can be seen by the location of the darkest color on the x-axis representing the preference . Furthermore, the fitness increase that can be achieved by having a preference is much larger when the curvature of the performance function is stronger. In this case, the herbivore benefits strongly from a broader nutrient distribution as there are many more leaves with the preferred nutrient content.

A.2 Influence of the shape of the mass loss due to preference
The optimal herbivore preference for a given trait variability parameter S (cp. Eq. (4)) depends on its costs. The shape of the mass loss due to preference ( ) between the limits → 0 and → 1 is determined via the parameters and k (cp. Eq. (6)). Larger means that the cost of preference is larger, and large k means that the costs are mainly incurred when preference is large. Fig. 4 shows the optimal herbivore preference (cp. Eq. (5)) for a given trait variability parameter S (cp. Eq. (4)) for different values for k (left column) and for (right column) considering the concave upwards f pos (n) (diamonds), linear f lin (n) (circles), and concave downwards f neg (n) (triangles) performance function shown in Fig. 1(a). The color shades in the markers display the mean fitness of the herbivore population under the particular circumstances.
As before, we find that the optimal preference value is largest for the concave upwards performance function f pos (n) , followed by the linear performance function f lin (n) , and is smallest for the concave downwards performance function f neg (n) independent of the trait variability parameter S.
The fitness that is reached with optimal herbivore preference increases with decreasing S when k = 1 and herbivore performance is a concave downwards function f neg (cp. Fig. 4(a)), since the herbivore population has very low or no preference in this case and thus benefits from low nutrient-level variability.
The larger , the lower is the optimal preference for a given trait variability parameter S (cp. Fig. 4(b), (d), (f)) since the parameter determines where the mass loss ( ) reaches its half saturation maximum (HSM). Half of the available mass will be lost to the cost of preference when Hence, a larger value for implies a higher mass loss for a given preference (cp. Fig. 5(a)).
The exponent k determines the slope in the half saturation maximum (cp. Fig. 5(b)) and has a more divers impact on the optimal herbivore preference for a given trait variability parameter S. More precisely, the optimal preference curves for different performance functions approach each other for increasing k. Under the assumption of a linear f lin or a concave downwards f neg performance function, the optimal herbivore preference decreases with decreasing k (cp. Fig. 4(d), (f)). In these cases, relatively low preferences lead to the highest fitness for a given trait variability parameter S and in this preference range decreasing values for k lead to considerably higher losses due to preference (cp. Fig. 5(b)). The same is true in the case of a concave (15) HSM = 1 1 + 1∕k .
upwards performance function f pos (cp. Fig. 4(b)) when S is small or high. For intermediate S, optimal preference is higher for k = 4 than for k = 2 , since the resulting mass loss is smaller; however, optimal preference is highest for k = 1 . In this range of S, optimal herbivore preference reaches higher values (near = 0.5 ), such that the relative mass loss ( ) changes much faster with for increasing k. As a consequence, it pays off to have a stronger preference when k = 1 . Nevertheless, one has to keep in mind that the maximal fitness values reached in this range for S are higher for larger values for k. Fig. 5 Proportion of mass that remains considering preference 1 − ( ) for different values for (a) the parameters and (b) k that shape the mass loss due to preference between the limits → 0 and → 1 . We chose k = 2 in (a) and = 1 in (b)