Mark Broom

Andrew D Higginson

Graeme D Ruxton

Optimal investment across different aspects of antipredator defences

Keywords: predation, predator-prey, investment in defences, optimal strategy, costs of defences

We present a simple model of investment across a suite of different anti-predatory defences. Defences can incur an initial construction cost and and/or may be costly each time they are utilised. Our aim is to use a simple, but general, mathematical model to explore when prey that face a single predatory threat where each attack is of the same nature should invest only in a single defence, and when they should spread their investment across more than one defence. This should help to explain the observed variety of defences that a single prey individual may employ during repeated attacks of a similar nature or even at different stages during one attack. Previous verbal reasoning suggested that prey should specialise in investment in defences that can be utilised early in the predation sequence. Our quantitative model predicts that (depending of the relatively properties of different defences), there may be concentrated investment in early-acting, or in late-acting defences, or a spread of investment across both defence types. This variety of predictions is in agreement with the variation in defences shown by natural organisms subjected to repeated predatory attack.

Introduction

Predation is an almost ubiquitous process in the natural world, and very few animals are immune to the risk of predation for at least part of their life history. Since predation is responsible for a large proportion of mortality in many species, it is no surprise that anti-predatory defences are also widespread and intensively studied by behavioural ecologists (see Ruxton et al. 2004 and[START_REF] Caro | Antipredator defenses in birds and mammals[END_REF] for reviews). Caro identified one of the ten most pressing questions in the study of anti-predatory defences as "how can we explain patterns of morphological and physiological defences across taxa?" There is indeed tremendous variety between species in the forms of anti-predatory defences employed. However, there is even substantial variability within an individual in the defences they employ against different attacks (Buskirk 2001 and references therein). The conventional explanation of this variation is that many individuals face risk of predation from a suite of different predatory types for which different defences might be required. For example, a single caterpillar might face attack by avian predators, predatory social wasps, parasitic wasps and flies, ants, spiders, and even insectivorous rodents. Whilst visual crypsis may be an effective defence against detection by birds, it is unlikely to be as effective against ants that rely more on tactile, vibrational and olfactory cues to locate their prey. However, variation in predatory threat (while certainly part of the answer) cannot be the sole driver of within-individual variation in defences, since a single individual can use different defences against the same type of predator in different attacks (reviewed in section 13.6 of [START_REF] Caro | Antipredator defenses in birds and mammals[END_REF].

A c c e p t e d m a n u s c r i p t

5 That a single individual can utilise a suite of different defences is noteworthy for at least two reasons. Firstly, defences are likely to be costly and each defence added to the prey's portfolio potentially adds an associated cost. Secondly, there can be interference between different defences such that implementation of one may impair the performance of another. The different costs of different defences are considered in depth in Chapter 5 of Ruxton et al. 2004. For our purposes, we differentiate between two general types of cost, those that are paid "up-front" such that the cost is paid whether or not attacks occur and regardless of the number of attacks (often called constitutive defences), and costs that are incurred each time the defence is used. For example, a caterpillar that defends itself against birds by being difficult to detect visually pays up-front costs. There may be physiological costs to the production of pigments required to produce the desired appearance. Alternatively or additionally, there may be opportunity costs associated with restricted use of microhabitats and restricted movement required to maximise crypsis. These costs are paid regardless of the number of attacks that an individual caterpillar experiences. In contrast some costs occur whenever the defence is employed in a specific attack [START_REF] Higginson | Dynamic state-dependent modelling predicts optimal usage patterns of responsive defences[END_REF] call these 'responsive' defences) . For example, some insects (notably many ladybirds) exhibit reflex bleeding where toxin-laced blood is exuded from joints in the exoskeleton in response to handling by a potential predator. This blood may deter the predator from pursuing its attack, but the exuded blood and its toxins have been lost, and have to be replaced. Replacement of these is likely to be physiologically costly, and the total cost of using this defence will increase with the number of times it is deployed [START_REF] Grill | Effects of a larval antipredator response and larval diet on adult phenotype in an aposematic ladybird beetle[END_REF]. Notice that this reflex bleeding defence may also incur up-front costs as well, since there may be physiological costs associated with the storage of toxins in a way that avoids autotoxicity, and gaps in the exoskeleton that [START_REF] Bowers | Aposematic caterpillars: life-styles of the warningly colored and unpalatable[END_REF], gland secretions [START_REF] Eisner | Chemical defense of an opilionid (Acanthopachylus aculeatus)[END_REF], urticating hairs [START_REF] Bowers | Aposematic caterpillars: life-styles of the warningly colored and unpalatable[END_REF], ink release by cephalopods [START_REF] Derby | Escape by inking and secreting: Marine molluscs avoid predators through a rich array of chemicals and mechanisms[END_REF], and the explosive defence of the bombardier beetle [START_REF] Eisner | The protective role of the spray mechanism of the bombadier beetle, Brachynus ballistarius[END_REF].

Investment in, or deployment of, one defence can reduce the effectiveness of another defence. For example investment in a tough spiny exterior may provide mechanical protection against handling by predators, but it may make the prey individual more conspicuous (decreasing the effectiveness of camouflage as a defence) and may make it more difficult for the prey to choose to flee from predators that may be able to circumvent the anti-handling defence. Flight and crypsis are two classically interfering defences. If a predator has not yet detected a predator, the prey may increase the chances of remaining undetected by remaining still and trusting to their cryptic appearance. However, if the predator inadvertently comes close to the prey before detecting it, the close spatial proximity of the two individuals will reduce the effectiveness of fleeing by the prey to escape the predator. Conversely, if the prey flees early in the predatory sequence before detection has occurred, then the effectiveness of crypsis is likely to be greatly reduced as the fleeing animal is more vulnerable to detection than when sitting still (Broom & Ruxton 2005).

Implicit in our description above is that an interaction between a prey individual and a predatory individual is generally a sequence of different phases. The most commonly used articulation of this is the sequence laid out by [START_REF] Endler | Interactions between predators and prey[END_REF], who suggested that a predation event involves a sequence of six stages: encounter, detection,

A c c e p t e d

m a n u s c r i p t 7 identification, approach, subjugation and consumption. Defences differ in which of these stages they can be utilised in. Clearly crypsis only works in the initial "encounter" stage prior to detection of the prey by the predator. In contrast, antipredatory vigilance to allow detection of the predator by the prey may be of use to the prey throughout all of the first four of Endler's six stages. Here we will simplify Endler's six stages: subsuming the first four into a "pre-capture" stage and the last two into "post-capture. Our aim is to use a simple, but general, mathematical model to explore when prey that face a simple predatory threat, where each attack is of the same nature, should invest only in a single defence; and when they should spread their investment across more than one defence.

Methods

Model description

The key to our model is the idea that to successfully exploit an encountered prey item, the predator must capture it and then subdue and consume it. Thus, successful predation requires success at each of a sequence of stages. Different defences act at different stages of the predation process, and we will simply characterise these as precapture and post-capture defences, simplifying predation to a two stage process.

Pre-capture defences minimise the probability that a predator that comes spatially close to (hereafter, "encounters") the prey is able to capture it. These might be defences that minimise the chance that the prey is detected and recognised (such as camouflage or disguise) or defences that reduce the chance that an attack will lead to capture (swiftness of movement, vigilance, manoeuvrability). We characterise all these pre-capture defences in a single parameter D 1 . D 1 is a non-negative number Post-capture defences involve such things as fighting ability, venomous stings, armoured integument and production of mucus. All these defences have in common the fact that they reduce the probability (P 2 ) that capture leads to the death (and thus consumption) of the prey (i.e. capture leads to successful predation). We describe increasing investment in post-capture defences by increasing values of D 2 , with P 2

declining with increasing values of D 2 . That is, increasing investment in post-capture defences reduces the probability that a predator that physically captures the prey is able to subdue, kill and consume it.

We are interested in finding the optimal strategy in terms of investment in these two defences. There are costs, as well as benefits, to investment in defence. We first of all assume that there are fixed costs to the creation of the defences. Thus, even if the prey individual never encounters a predator, it pays a cost for its investment in defences.

This occurs because these defences are constitutive (at least in part). The fecundity of an individual that never encounters any predators is given by F(D 1 ,D 2 ) where F declines with increasing values of both D 1 and D 2 . This represents the fixed costs of investment in the two types of defence. As investment in a defence increases so the fitness cost increases.

A c c e p t e d m a n u s c r i p t

9 However, as well as fixed costs, we assume that there can be additional costs every time a defence is used. For example, for pre-capture defences, we can imagine that there is a fixed cost to building and maintaining the muscle structure required for fast escape, but there is an additional cost (say in energy expended and/or feeding time lost) every time that defence is used and the prey has to flee. Specifically we assume that if the prey encounters a predator on a number of occasions N a , then it has to use its pre-capture defence on N a occasions. The cost of these encounters is represented by multiplying the fecundity of the prey individual by [C 1 (D 1 )] Na , where C 1 (0) = 1 (that is unaffected if there is no investment in defence) and C 1 declines with increasing values of D 1 (and thus fecundity declines both the investment in defence and with how often the defences are used). This formulation captures the assumptions that the costs of using pre-capture defences increase both with the number of times these defences are used and with the extent of these defences. That is, greater investment in pre-capture defence reduces the risk of capture, but also incurs higher fixed costs and costs that increase with the number of time these defences are used.

Let us assume that of these N a encounters, a number N c lead to capture of the prey and a number N n lead to no capture and the prey escaping. Thus, we assume that to successfully survive these attacks the prey will have to successfully use its postcapture defences on N c occasions (N c ≤ N a ). The cost of these is represented by multiplying the fecundity of the prey individual by [C 2 (D 2 )] Nc .

Where C 2 (0) = 1 and C 2 declines with increasing values of D 2 . This formulation captures the assumptions that the costs of using post-capture defences increases both with the number of times these defences are used and with the extent of these That is greater investment in post-capture defence reduces the risk that capture leads to death, but also incurs both higher fixed costs and higher costs each time these defences are used.

If a number of encounters with predators occur, then the fecundity of the prey individual is zero if it is killed in any one of these. The probability of it not being killed in any of the encounters is (1-P 2 ) Nc .

Thus, the total payoff to an individual playing a certain strategy (in terms of investment across its two possible defences) is given by the fecundity multiplied by the probability of surviving:

( ) ( ) [ ] c n c c a N N N N N P C C FC P C FC R 2 2 1 1 2 2 1 1 1 - = - =
where for notational convenience, we have omitted writing out functional dependences on D 1 and D 2 . However, N c (and so N n ) depends upon the value of D 1 . Let us assume that encounters with a predator occur as a Poisson process at rate ε, and that reproduction requires that an individual first avoid being consumed by a predator for a time period T. From the general properties of the Poisson process, this can be broken down into two independent Poisson processes. Namely, encounters that lead to capture (which are Poisson with rate εP 1 ) and encounters that do not lead to capture (which are Poisson with rate ε(1-P 1 )). Thus N c takes values drawn from a Poisson distribution with mean εP 1 T, and N n from a Poisson distribution with mean ε(1-P 1 )T.

A c c e p t e d m a n u s c r i p t 11

Since N c and N n are generated by independent processes, we can write the payoff as

( ) { } ] 1 [ ] [ 2 2 1 1 c N Nn P C C E C FE R - =
,

where E[] denotes the expectation of a stochastic process.

From the properties of the Poisson process, if x is Poisson with mean λ, then

[ ] ( ) (

).

1 exp - = t t E x λ
and using this, we can eliminate N n and N c from our expression for the payoff, giving

R = F exp ε 1-P 1 ( )T C 1 -1 ( ) ( ) exp εP 1 T C 1 C 2 1-P 2 ( )-1 ( ) ( ) .
If we take logs and divide by εT, we can simplify this to

R l = ln R ( ) εT = ln F ( ) εT -1+ C 1 1-P 1 ( )+ P 1 C 1 C 2 1-P 2 ( ) (1)
Maximising the above function, maximises the payoff. In order to make further progress, we must now specify the following functional forms.

( ) ( ) 2 2 1 1 max 2 1 exp , D f D f F D D F - - =
. Thus, we assume that maximum fecundity (before any predator encounters) is a decreasing decelerating function of both D 1 and

A c c e p t e d m a n u s c r i p t

12 D 2 . The higher the values of f 1 and f 2 , the higher the fixed costs of pre-capture and post-capture defences respectively.

) 1 , 0 max( 1 1 1 D p P - = ( ) 2 2 2 1 , 0 max D p P - =
That is, we assume that the probability of an attack succeeding decreases linearly with investment in defences. The higher the values of p 1 and p 2 the higher the antipredatory efficacy of pre-capture and post-capture defences respectively.

(

)

1 1 1 1 , 0 max D c C - = ( ) 2 2 2 1 , 0 max D c C - =
We assume that the cost of defences increases linearly with the investment in defences. The higher the values of c 1 and c 2 the higher the per-use costs of pre-capture and post-capture defences respectively. These are perhaps the simplest functions that have the required properties outlined in the description above, Clearly, this restricts investment in defences such that p 1 D 1 , p 2 D 2 , c 1 D 1 and c 2 D 2 must all be less than one for the model to give sensible predictions. Thus as D 1 approaches 1/c 1 for example, any use of the first defence would cost an individual almost all of its fitness. Provided that p 1 is not much smaller than c 1 , and p 2 not much smaller than c 2 , these upper boundaries will not be approached for any reasonable strategy.

Model predictions

A c c e p t e d m a n u s c r i p t 13

We begin by identifying the types of different solutions (in terms of investment across the two defences) that are optimal in different circumstances. We define the following two terms that are central to the work that follows.

1

1 1 1 - = T p f ε β 1 2 2 2 - = T p f ε β
β can be thought of as the ratio of the constutive cost to the benefit of defences. Note that it immediately follows that β 1 ≥ -1 and β 2 ≥ -1. First, let us ask if it is ever optimal for the prey never to make any investment in these costly defences. In all analyses we explore the effect of f 1 and f 2 , which control the constitutive impact of defences on maximum fecundity.

No investment: (D 1 , D 2 ) = (0,0).

This occurs when both the derivatives of equation ( 1) with respect to D 1 and D 2 are negative at (0,0). It is easy to show that this occurs whenever we satisfy two conditions:

β 1 > 0 (2)
and

β 2 > 0 (3)

A c c e p t e d m a n u s c r i p t

14 For this solution, the stability condition is the same as the existence condition, so whenever this solution is valid it is also stable. The above conditions are equivalent to

T p f ε 1 1 > and T p f ε 2 2 > .
This is shown graphically in Figure 1 with example values for parameters. These conditions make intuitive sense. Increasing the f values increases the constitutive cost of defence. If the p value is small then the effectiveness of the associated defence is low, if ε is small then attacks rarely occur, and if T is small then individuals only have a short pre-reproductive period to survive: all of which should make investment in defences less attractive. That is, if the constitutive cost of defence has a larger impact on fitness than the increase in the probability of survival, prey should never invest in defences. Notice, that the occurrence of this no-defence equilibrium is influenced only by the constitutive costs of defence (f 1 and f 2 ) not by the costs of utilising the defences (c 1 and c 2 ).

Investment only in pre-attack defences: (D 1 , D 2 ) = (D 1 ,0).

This occurs when both the derivative of equation ( 1) with respect to D 1 is zero and the derivative with respect to D 2 is negative at (D 1 ,0). Evaluation of these derivatives leads to two conditions again: (  )

0 1 1 2 1 1 1 1 2 < - - + - p D c D p T f ε
Expressed in terms of β 1 and β 2 this becomes

β 2 > p 1 β 1 4c 1 ⎛ ⎝ ⎜ ⎞ ⎠ ⎟ β 1 + 2+ 2c 1 p 1 ⎛ ⎝ ⎜ ⎞ ⎠ ⎟ = β 1 4a 1 ⎛ ⎝ ⎜ ⎞ ⎠ ⎟ β 1 + 2+ 2a 1 ( ) (4)
where

a 1 = c 1 p 1
The derivative with respect to D 1 gives 0 2

1 1 1 1 1 = - + - D c p p T f ε . Expressed in terms of β 1 and β 2 this becomes 1 1 1 2c D β - = ,
which is positive providing β 1 < 0.

For (D 1 ,0) to be stable we need the second derivative of R with respect to D 1 to be negative at (D 1 ,0). It is easy to demonstrate that this is always true. Thus, again this

A c c e p t e d m a n u s c r i p t

16 solution is stable any time that it is valid. So, biologically we can conclude that it is also possible for all investment to be concentrated in pre-attack defences.

However there are further conditions on β 1 , since the optimal level of investment in defence in this case is given by

1 1 1 2c D β - =
The condition c 1 D 1 < 1, together with β 1 ≥ -1, leads to the restriction -1 < β 1 < 0 ; and the condition p 1 D 1 < 1 leads to the restriction -2a 1 < β 1 < 0. This gives -2min(0.5,a 1 ) < β 1 < 0 (5) which in addition to (4) gives the conditions for the (D 1 ,0) solution.

These conditions are summarised graphically in Figure 1. Again, the results make intuitive sense. From our arguments in the previous section, this solution is more likely to occur under conditions where β 1 is negative and β 2 is positive (or only just negative). The other parameter group that affects the likelihood of obtaining this solution is a 1 . a 1 takes a high value if the costs of using pre-attack defences is high and/or if the effectiveness of such defences is low. Hence, it is logical that increasing a 1 restricts the area of (β 1 ,β 2 ) space where such solutions occur. From the arguments laid out already it is no surprise that the level of investment in pre-attack defences This occurs when the derivative of equation ( 1) with respect to D 1 is negative and the derivative with respect to D 2 is zero at (0,D 2 ). Evaluation of these derivatives leads to two conditions again:

Firstly, the derivative with respect to D 1 gives ( )( )

0 1 2 2 2 2 1 1 1 1 < - + - + - D p D c c p p T f ε
Expressed in terms of β 1 and β 2 this becomes

β 1 > p 2 4c 2 ⎛ ⎝ ⎜ ⎞ ⎠ ⎟ 1+ c 1 p 1 ⎛ ⎝ ⎜ ⎞ ⎠ ⎟ β 2 β 2 + 2 ( )= 1+ a 1 4a 2 ⎛ ⎝ ⎜ ⎞ ⎠ ⎟ β 2 β 2 + 2 ( ) (6)
where

a 2 = c 2 p 2 .
The derivative with respect to D 2 gives 0 2 For this solution to be stable we need the second derivative of R with respect to D 2 to be negative at (0,D 2 ). It is easy to demonstrate that this is always true, and thus again this solution is always stable when it exists. This means that it is possible to find combinations of parameter values where investment in post-attack defences occurs without any investment in pre-capture defence.

Since this is the mirror image of the case above, it will not be surprising to find very analogous conditions for this case. The conditions for the existence of this solution are

-1 < β 2 < 0 -2a 2 < β 2 < 0 giving -2min(0.5,a 2 ) < β 1 < 0 (7)
which together with (6) gives the conditions for the (0,D 2 ) solution.

These limits can again be interpreted intuitively as above, and are shown graphically in Figure 1.

A c c e p t e d m a n u s c r i p t

19 Note, however, a significant difference between conditions ( 4) & ( 6); whilst a 2 had no effect on the boundaries of the pre-attack only case, a 1 (as well as a 2 ) does affect the boundaries of the post-attack only case. This asymmetry arises from the fundamental asymmetry between the two types of defences, pre-attack defences occur before postattack defences, and thus influence the frequency with which post-attack defences are used. However, post-attack defences do not affect the frequency with which preattack defences are used. Increasing a 1 (increasing the costs of utilising a pre-attack defence or decreasing its efficacy) increases the extent of (β 1 ,β 2 ) space where this post-attack only investment strategy occurs -again this is just as we would expect.

Non-zero investment in both forms of defence

At such a solution, the derivatives of equation ( 1) with respect to both D 1 and D 2 will be zero. Substituting the specific functional forms and differentiating gives:

-f 1 εT + p 1 -2p 1 c 1 D 1 + 2p 1 c 1 D 1 -p 1 -c 1 ( )1-c 2 D 2 ( )p 2 D 2 = 0 (8) -f 2 εT + 1-p 1 D 1 ( )1-c 1 D 1 ( ) p 2 -2p 2 c 2 D 2 ( )= 0 (9)
These can be solved simultaneously for the non-zero combination of D 1 and D 2 that maximises the payoff.

Using (9) we can get an expression for D 2 in terms of D 1 :

A c c e p t e d m a n u s c r i p t

20 ( )( ) ⎟ ⎟ ⎠ ⎞ ⎜ ⎜ ⎝ ⎛ - - - ⎟ ⎟ ⎠ ⎞ ⎜ ⎜ ⎝ ⎛ = 1 1 1 1 2 2 2 2 1 1 1 2 1 D c D p T p f c D ε (10)
Using this substitution, and rearranging equation ( 8) gives

( )( ) ( ) ( ) 1 1 1 1 1 1 1 1 2 1 1 1 1 2 2 2 2 2 1 2 1 1 1 1 4 D c p c D c p T f D c D p T p f c p - + - - = ⎟ ⎟ ⎠ ⎞ ⎜ ⎜ ⎝ ⎛ ⎥ ⎦ ⎤ ⎢ ⎣ ⎡ - - - ⎟ ⎟ ⎠ ⎞ ⎜ ⎜ ⎝ ⎛ ε ε (11)
It is relatively easy to show that as D 1 increases the RHS of this always increases, because the nominator gets larger and the denominator gets smaller, and the LHS always decreases (providing c 1 D 1 < 1 and p 1 D 1 < 1: which we have assumed to hold earlier). Thus there can be at most one solution where the two sides balance and so at most one solution with D 1 > 0 and D 2 > 0.

Thus, for any parameter value combination, if a solution (D 1 ,D 2 ) exists, then this solution is unique.

Using the standard methodology of considering the determinant of the Hessian matrix, the solution will be stable when this determinant is negative, so that

∂ 2 R l ∂D 1 2 ∂ 2 R l ∂D 2 2 > ∂ 2 R l ∂D 1 D 2 ⎛ ⎝ ⎜ ⎞ ⎠ ⎟ 2 , ∂ 2 R l ∂D 1 2 < 0, ∂ 2 R l ∂D 2 2 < 0
at the solution values (D 1 ,D 2 ). We obtain

A c c e p t e d m a n u s c r i p t

21

∂ 2 R l ∂D 1 2 = 2p 1 c 1 ( p 2 D 2 (1-c 2 D 2 )-1) ∂ 2 R l ∂D 2 2 = -2p 2 c 2 (1-p 1 D 1 )(1-c 1 D 1 ) ∂ 2 R l ∂D 1 D 2 = (2p 1 c 1 D 1 -p 1 -c 1 )( p 2 -2p 2 c 2 D 2 )
It is clear that both second derivatives are negative and so we only need the first condition to be solved. Substituting for D 2 in (8) and tidying yields

4 p 1 c 1 p 2 c 2 v 1 -p 2 2 p 1 c 1 v 1 + f 2 εTv 1 ⎛ ⎝ ⎜ ⎞ ⎠ ⎟ 2 ( p 1 c 1 v 1 -( p 1 + c 1 -2p 1 c 1 D 1 ) 2 ) > 0 (12)
where D 1 is given by the solution of ( 11) and

v 1 = 1-p 1 D 1 ( )1-c 1 D 1 ( ).
Thus a stable non-zero investment occurs if the solutions of ( 10) and ( 11) yield values of D 1 and D 2 such that and (12) holds. An unstable solution occurs if ( 10) and ( 11) yield such values and ( 12)

0 < D 1 < min 1 p 1 , 1 c 1 ⎛ ⎝ ⎜ ⎞ ⎠ ⎟ , 0 < D 2 < min 1 p 2 , 1 c 2 ⎛ ⎝ ⎜ ⎞ ⎠ ⎟
does not hold. Unlike the other strategies discussed so far, this mixed-defences strategy is not guaranteed to be stable whenever it exists.

Co-existence of solutions

We It is clear from equations ( 2), (3), ( 5) and ( 7) that (0,0) cannot co-exist with either of the single defence strategies, and by noticing that the left hand side of equation ( 9)

decreases with increasing levels of either defence, it is also clear that it cannot coexist with either of the two-defence solutions (either the two-defence solution is stable when it exists or it is unstable).

We shall now consider the two single-defence solutions. The lower boundary to the pre-attack only solution (D 1 ,0) is given when the inequality in ( 4) is replaced by an equality i.e.

( )

1 1 1 1 2 2 2 4 a a + + ⎟ ⎟ ⎠ ⎞ ⎜ ⎜ ⎝ ⎛ = β β β . ( 13
)
The left-most boundary of the post-attack-only solution in Figure 1 is attained using (6) in a similar way to give:

β 1 = 1+ a 1 4a 2 ⎛ ⎝ ⎜ ⎞ ⎠ ⎟ β 2 β 2 + 2 ( ) . ( 14
)
The gradient dβ 2 /dβ 1 of the boundary of the (D 1 ,0) solution, evaluated at the origin is simply 1/(2a 1 ). For the left-most boundary to the (0,D 2 ) solution, the gradient dβ 1 /dβ 2 evaluated at the origin is simply (1+a 1 )/(2a 2 ). Thus, the gradient dβ 2 /dβ 1 at this point is 2a 2 /(1+a 1 ).

A c c e p t e d m a n u s c r i p t 23

From Figure 1, we can see that there will be an area of overlap of the two regions if the gradient of the (0,D 2 ) boundary is less steep than at the of the (D 1 ,0) boundary at the origin, i.e. if

1 1 2 2 1 1 2 a a a < + . ( 15
)
However if ( 15) is not satisfied for a particular set of parameter values then the two single-defence-only solutions cannot co-exist.

From before, the conditions for a solution (0,D 2 ) are given by ( 6) and ( 7) and the conditions for a solution (D 1 ,0) are given by ( 4) and ( 5). If we look at the simplifying case where 5 . 0

1 2 = = a a
, then (4) becomes ( )

3 2 1 1 2 + > β β β (5) becomes -1 < β 1 < 0, (6) becomes ( ) 2 4 3 2 2 1 + > β β β
, and (7) becomes -1 < β 1 < 0.

A c c e p t e d m a n u s c r i p t 24

In general, β 1 > -1 and β 2 > -1 is the allowable region if c 1 ≥0.5 p 1 , c 2 ≥ 0.5 p 2 and p 1 β 1 > -2c 1 (or p 2 β 2 > -2c 2 ) if c 1 <0.5 p 1 (c 2 <0.5 p 2 ). So if p 1 ≤ 2c 1 and p 2 ≤ 2c 2 then the full range of possible βs are valid (and so any parameter sets of this type give solutions as above), but if p 1 > 2c 1 and/or p 2 > 2c 2 then there will be parameter combinations that we cannot solve in this way; these cases correspond to defences which are so effective that a reasonable investment can reduce the probability of capture to zero, and we ignore this possibility here.

We now show that (D 1 ,D 2 ) cannot occur with (D* 1 ,0). For both of these to be solutions, each must satisfy equation ( 8), and we can see from this that D* 1 >D 1 . . For (D 1 ,D 2 ) to be a solution we need these values to solve ( 10) and ( 11). For (D* 1 ,0)

we need equation ( 11) to be solved with the left-hand side replaced by 0. However this means that in this second solution the left-hand term is less than in the first, but the right-hand term is greater than the first (D* 1 >D 1 and the right-hand term increases with D 1 ); which yields a contradiction. Thus the two solutions cannot occur for the same parameters.

Hence (D 1 ,D 2 ) can only occur together with (0,D 2 ) (see Figure 1), or as a unique solution.

In all of our numerical calculations (see the following section) a stable solution of this type (with investment in both defences) exists whenever none of the other three types do, although we have been unable to prove that this must always be the case.

A c c e p t e d m a n u s c r i p t 25

We have shown there are five possible equilibrium solutions, four of which are ESSs ((0,0), (D 1 ,0), (0,D 2 ), stable (D 1 ,D 2 ), together with the unstable (D 1 ,D 2 ) which is not an ESS). Thus without restrictions, there would be 32 possible combinations of solutions. However, we have shown that (0,0) can only exist as the sole solution, and that there can never be more than one solution from (D 1 ,0), stable (D 1 ,D 2 ) and unstable (D 1 ,D 2 ). This leaves nine possible combinations, which we consider below.

The following five combinations are all observed in Figure 1:(0,0);

(D 1 ,0); (0,D 2 ); stable (D 1 ,D 2 ); (0,D 2 ), stable (D 1 ,D 2 ).
In addition to some of these, both (D 1 ,0) , (0,D 2 ) and (0,D 2 ), unstable (D 1 ,D 2 ) are observed in Figure 3.This leaves the two possibilities of only unstable (D 1 ,D 2 ) and no solution, which are the two possibilities leading to no ESS. We have been unable to prove that these cannot occur, but have not observed them in any of our numerical investigations.

Numerical Investigation of the Model

Recall our definitions:

1 1 1 1 - = T p f ε β and 1 2 2 2 - = T p f ε β .
We know that (0,0) occurs when β 1 and β 2 are both positive, and under these circumstances (0,0) can be the only solution. This translates to conditions For the situation where the prey should invest only in pre-capture defences, there are two restrictions on f 1 : -2 < β 1 < 0 and -2a 1 < β 1 < 0. As before, the prey should not invest in post-capture defences where

T p f ε 1 1 > and T p f ε 2 2 > .
T p f ε 2 2 >
. Under our default parameters values, c 1 = 0.2, and thus a 1 = 2, since a 1 = c 1 /p 1 . and therefore the most restrictive condition is that not involving a 1 . The region of (f 1 ,f 2 ) parameter space where only pre-capture defences are predicted therefore occurs when β 1 is negative and (by rearrangement) f 1 >-pεT. Since 1

1 1 1 + = β εT p f
, for our default values these fall at f 1 values of 1 and -1. However, we are only interested in non-negative values of f 1 and f 2 , so the critical f 2 values become 0 and 1.

There is also a restriction on f 2 given by ( )

1 1 1 1 2 2 2 4 a a + + ⎟ ⎟ ⎠ ⎞ ⎜ ⎜ ⎝ ⎛ > β β β
In order to find this line, we simply take a range of f 1 values, between the two extreme values (0 and 1), convert these to β 1 values, and hence to β 2 values, before converting these to f 2 values. Since we need to specify the value of p 2 . We assume this takes the value 0.1. Thus, the curved broken line and the vertical lines at f 1 equals 0 and 1 in Figure 1 enclose the region where investment in pre-capture defences makes post-capture unnecessary. This is the top, left region of Figure 1.

A very similar situation occurs for the (0,D 2 ) solution. Here, there are two restrictions on f 2: -2 < β 2 < 0 and -2a 2 < β 2 < 0. Let us assume that c 2 = 0.3, and thus a 1 = 3, since a 2 = c 2 /p 2 . Thus, the most restrictive condition does not involve a 2 .

Since 1

2 2 2 + = β εT p f
, for our default values these fall at f 2 values of 1 and -1.

However, we are only interested in non-negative values of f 1 and f 2 , so the critical f 2 values become 0 and 1.

There is then a restriction on f 1 given by ( )

2 4 1 2 2 1 1 1 + ⎟ ⎟ ⎠ ⎞ ⎜ ⎜ ⎝ ⎛ + > β β β a a
In order to find this line, we simply take a range of f 2 values, between the two extreme values, convert these to β 2 values, and hence to β 1 values, before converting these to f 1 values. Thus, the solid curved line and the horizontal lines at f 2 = 0 and f 2 = 1 to the right of the curved line enclose the parameter values that yield this solution (in the bottom, right part of Figure 1). at f 1 = 0.4. Generally as f 1 increases, so D 2 increases and D 1 decreases. Eventually, at an f 1 value around 1.05 the D 1 value falls to zero, when this occurs, then Figure 2 predicts the D 2 value to be close to the 0.667 value predicted for the solution with no investment in D 1 at this point.

In Figure 3 we present the result of the same evaluation as in Figure 1 but where c 2 is reduced six-fold to 0.05. Although the predictions are superficially similar, there are several interesting differences. Firstly, there is now a region of f 1 -f 2 space where both A c c e p t e d m a n u s c r i p t 29 the (0,D 2 ) and (D 1 ,0) solutions are valid and stable. We must also consider the stability of the solution of investment across both defences. In figure 3, we only plot such solutions where they are stable. In Figure 1, the interior solution is stable whenever it exists. This is not true for the parameters chosen for Figure 3. As in Figure 1, when f 1 < 1, the interior solution exists for all f 2 values below the broken line marking the region of ((D 1 ,0) solutions. However, it is only stable for a subset of lower f 2 values. Thus, there can be a region where both (0,D 2 ) and (D 1 ,D 2 ) are potential solutions but only the first of these is stable. As we have seen in Figure 1, it is possible also to find regions of parameter space where both solutions are stable simultaneously.

Discussion

In his influential work, [START_REF] Endler | Interactions between predators and prey[END_REF] suggested that it may be more attractive for prey to interrupt the predation sequence as early as possible (see also Planque et al (2002) who argue the same relating to successive defences against brood parasitism). He argues this for a number of reasons. Firstly, failure of a later defence may be more likely to be catastrophic for the prey. Secondly, later in the sequence the performance of the prey may be weakened or exhausted by implementation of defences earlier in the sequence. Thirdly, the lost time and energy spent in repelling the attack will be reduced if the attack is resolved early in the sequence. Finally, investment in defences later in the sequence may be inefficient, if these defences are seldom used because defences used earlier in the sequence are generally successful in repelling attacks before the later-acting defences are implemented. The last point especially argues that we should expect investment in early (pre-capture) defences, but not in later defences. Our model predicts that there can be circumstances where it is optimal for the prey to invest in neither defence. This occurs if the constitutive costs of the defences are high, if the defences have low efficacy (per unit of investment), if attacks are rare and if the period during which the prey is exposed to predation is short. There are also circumstances where we predict investment in pre-capture defences but not post capture defences. This solution is more likely to occur under conditions where β 1 is negative and β 2 is positive (or only just negative). The parameter β for a given defence can be seen as a description of the cost-benefit ratio of the defences: β becomes larger (more positive) if the constitutive costs of the defence are high. β also becomes larger if the attack rate, the period that must be survived by the prey and/or the efficacy of the defence are low. Whether or not we predict investment in precapture defences only is also affected by the value of a 1 . This parameter takes a high value if the costs of using pre-capture defences are high and/or if the effectiveness of pre-attack defences is low. Increasing a 1 restricts the area of (β 1 ,β 2 ) space where investment only in pre-capture defences is optimal. The level of investment in precapture defences increases as β 1 becomes more negative and/or as c 1 is reduced.

In circumstances where the asymmetry of the cost/benefit ratios are opposite (that is β s is negative and β 1 is positive (or only just negative), then we get investment in are likely where f 1 and f 2 are small, which might be reasonable for defences such as colouration and sequestering of defences. Many defences serve other, perhaps primary functions, such as catching or subduing prey, and so their marginal canonical costs in terms of defence might be small. We find that the costs of one defence affects the likelihood of investment in the other (cf Figure 3 and 1).

Further, there are combinations of parameter values for which different strategies are both stable. In such circumstances the strategy to which the population settles will depend on the history of the population. Thus, the model predicts that it is difficult to make generalisations about how many and which defences a certain prey type will invest in without quantitative evaluation of the different properties of each of the alternative defences, as we discuss above. Our model might therefore provide insight in to, for example, the evolution of aposematism in the lepidoptera. Many closely related species have differing defensive strategies, with some investing heavily in precapture defences (excellent crypsis paying opportunity costs) and others having both pre-capture (warning coloration) and post-capture (aversive chemistry) defences. Our model shows how easily these might be equally fit, and so divergent selection might occur based initially on very minor differences, or even genetic drift.

There is a significant difference between the two types of defence, in that pre-attack defences occur before post-attack defences, and thus influence the extent to which post-attack defences are used. However, post-attack defences do not affect the frequency with which pre-attack defences are used. This results in the co-existence of by plants (e.g. [START_REF] Biere | Plant chemical defense against herbivores and pathogens: generalised defense or trade-off?[END_REF], Ode 2006). We suggest that a useful next development for our understanding of anti-predator behaviours would be to explore how applicable current understanding of anti-herbivore defences is to the different system.

The diversity of possible solutions to investment across only two defences in our simple model where prey face only one type of attack demonstrates that a general understanding of the diversity of anti-predatory suites used by different prey will be a challenge. However, to meet that challenge, we feel that we have demonstrated that simple verbal reasoning will be insufficient and models that allow quantitative evaluation of a complex of different costs and benefits (as well as interaction between the effectiveness of defences, not considered here) will be required.

  to leave may impose costs in terms of, for example, water loss or risk of fungal disease. Other examples of responsive defences are regurgitation

  in pre-capture defences, with increasing values indicating increasing investment. The probability that an encounter with a predator leads to capture (P 1 ) is a decreasing function of D 1 . That is, increasing investment in preencounter defences reduces the probability that the prey individual will be successfully captured by any predator that encounters it.

Firstly

  β 1 becomes more negative (because constitutive costs decrease or benefits increase) and/or as c 1 is reduced (because responsive costs decrease).Investment only inpost-capture defences: (D 1 , D 2 ) = (0,D 2 )

  consider the five possible solutions Stable (D 1 , D 2 ); Unstable (D 1 , D 2 ); (D* 1 ,0); Stable (0, D* 2 ); (0,0) where we use D* 1 and D 2 * to indicate that if one of these single to coexist for the same parameters as (D 1 , D 2 ), the levels would in general be different to that of the same defence in the two-defence solution.

  the examples that follow we assume the values p 1 = 0.1, p 2 = 0.1, εT = 10 and c 2 =0.2. Then (0,0) is the unique solution when f 1 > 1 and f 2 > 1. The boundaries of these conditions are shown by the dotted lines in Figure1, and the region of no investment in defences lies above both these boundary values of f 1 and f 2 in the top right corner of Figure1(note the dotted lines will be partially covered by other lines).

  Figure 2 is close to the value 1.5 predicted for the solution with zero investment in D 2

  defences are more often constitutive, in that the prey does not have to detect the predator to be undetected, and so predator encounters might not affect the cost of early defences . In contrast, post-encounter defences are more often responsive, involving defensive behaviours or other physiological costs, such as regurgitation or reflex bleeding that are triggered by a specific attack.

  defences only. Where the two β values are generally similar and not too large and positive, we predict investment across both defences. Indeed, such solutions

  defences and in only post-attack defences, but not in both defences and only pre-attack defences.An interesting extension of our model would be to include a range of predator types (or equivalently a range of different predatory situations), with different defences differing in their rank order of efficacy against these different predators. In particular, this would allow exploration of generalism and specialism in defences and in particular the general trend (noted by both[START_REF] Endler | Interactions between predators and prey[END_REF][START_REF] Caro | Antipredator defenses in birds and mammals[END_REF]) that defences used later in the predation sequence are more likely to be specialised for a particular type of predator than more general defences used earlier in the sequence. Again, the role of multi-functional defences was identified by[START_REF] Caro | Antipredator defenses in birds and mammals[END_REF] as another of his ten most pressing questions in predator-prey interactions.[START_REF] Endler | Interactions between predators and prey[END_REF] categorisation of different anti-predatory defences in animals has been highly influential, but development of theoretical underpinning for his predictions and empirical testing of these predictions has been lacking. We hope our work will be a useful early step in developing a more solid theoretical base for understanding diversity of anti-predatory traits. There have been developments on the empirical side. Low (1998) carefully demonstrated investment across a range of defences by the leaf-mining larvae of a moth (Antispila nysaefoiella) against a specialist parasitoid. Langridge et al (in prep) demonstrated that the anti-predatory behaviours of cuttlefish (Sepai officinalis) accords with three of Endler's specific predictions: that later in the sequences of an attack, defences become more predatorspecific, more risky if unsuccessful in deterring attack and more costly to mount.More empirical and theoretical work to explore and develop these predictions would In this, an important resource may be the comparatively much more extensive literature seeking to understand the diversity of anti-herbivore traits shown

  . 2008. Grouping increases visual detection risk by specialist parasitoids. Behavioral Ecology 19, 532-538 Ode, P.J. 2006. Plant chemistry and natural enermy fitness: effects on herbivore and natural enemy interactions. Annual Reviews in Entomology 51, 163-185 Planque, R., Britton, N.F., Franks, N.R., Peletier, M.A. 2002. The adaptiveness of defence strategies against Cuckoo parasitism. Bulletin of Mathematical Biology 64, 1045-1068. Ruxton, G.D., Sherratt, T.N., Speed M.P. 2004 Avoiding attack: the evolutionary ecology of crypsis, warning signals and mimicry. Oxford University Press, Oxford. Van Buskirk, J. 2001. Specific induced responses to different predator species in anuran larvae. Journal of Evolutionary Biology 14, 482-489.

Figure 1 :

 1 Figure captions

Figure 2 :

 2 Figure 2: D 1 (broken line) and D 2 (solid line) values for the mixed solution shown in

Figure 3 :

 3 Figure 3: Different optimal solutions in terms of investment in pre-capture and post-

  Fig. 1