Diversity of Sharp Restart

When applied to a stochastic process of interest, a restart protocol alters the overall statistical distribution of the process' completion time; thus, the completion-time's mean and randomness change. The explicit effect of restart on the mean is well understood, and it is known that: from a mean perspective, deterministic restart protocols -- termed sharp restart -- can out-perform any other restart protocol. However, little is known on the explicit effect of restart on randomness. This paper is the second in a duo exploring the effect of sharp restart on randomness: via a Boltzmann-Gibbs-Shannon entropy analysis in the first part, and via a diversity analysis in this part. Specifically, gauging randomness via diversity -- a measure that is intimately related to the Renyi entropy -- this paper establishes a set of universal criteria that determine: A) precisely when a sharp-restart protocol decreases/increases the diversity of completion times; B) the very existence of sharp-restart protocols that decrease/increase the diversity of completion times. Moreover, addressing jointly mean-behavior and randomness, this paper asserts and demonstrates when sharp restart has an aligned effect on the two (decreasing/increasing both), and when the effect is antithetical (decreasing one while increasing the other). The joint mean-diversity results require remarkably little information regarding the (original) statistical distributions of completion times, and are remarkably practical and easy to implement.


Introduction
a positive deterministic timer τ, is applied.
Step I: initiate simultaneously the task and the timer.
Step II: if the task is accomplished up to the timer's expiration -i.e. if T ≤ τ -then stop upon completion.
Step III: if the task is not accomplished up to the timer's expiration -i.e. if T > τ -then, as the timer expires, go back to Step I.
The sharp-restart algorithm generates an iterative process of independent and statistically identical task-completion trials. This process halts during its first successful trial, and we denote by T R its halting time. Namely, T R is the overall time it takes -when the sharp-restart algorithm is applied -to complete the task. The sharp-restart algorithm is a non-linear mapping whose input is the random variable T , whose output is the random variable T R , and whose parameter is the deterministic timer τ.
Henceforth, we set the task-completion process to start at time t = 0; thus, the process takes place over the non-negative time axis t ≥ 0. Along this paper we use the following notation regarding the input's statistics: distribution function, F (t) = Pr (T ≤ t) (t ≥ 0); survival function, F (t) = Pr (T > t) (t ≥ 0); and density function, f (t) = F (t) = −F (t) (t > 0). The input's density function is considered to be positive-valued over the positive half-line: f (t) > 0 for all t > 0.
In terms of the input's survival and density functions, the output's density function f R (t) admits the following representation [20]: where n = 0, 1, 2, · · · , and where 0 ≤ u < τ. Indeed, in order that the output T R be realized at time t = τn + u we need that: A) the first n task-completion trials be unsuccessful; and B) the task be accomplished right at the time epoch u of the (n + 1) th task-completion trial. Event A occurs with probabilityF (τ) n , event B occurs with likelihood f (u), and hence: the likelihood that the output be realized right at time t = τn + u is given by the right-hand side of Eq. (1). Due to the structure of the sharp-restart algorithm, its output admits the stochastic representation where: N = T R /τ is the number of unsuccessful task-completion trials; and U = T R −τN is the time epoch, within the successful trial, at which the task is accomplished. The random variables N and U are mutually independent, and their statistics are as follows [20]. The random variable N is Geometrically-distributed with success probability p = F (τ), i.e.: Pr (N = n) = (1 − p) n p (n = 0, 1, 2, · · · ). The random variable U is equal, in law, to the input T -given the information that the input is no-larger than the timer, {T ≤ τ}; consequently, the statistical distribution of the random variable U is governed by the density function f (u) /F (τ) (0 < u < τ).

Diversity
Perhaps the most common quantitative gauge of randomness is the standard deviation. Specifically, the standard deviation σ [X] of a real-valued random variable X is the square root of the random variable's variance. A principal property of the standard deviation is its response to affine transformations: σ [aX + b] = |a| · σ [X], where a and b are real parameters. The aforementioned principal property captures four different features that one would reasonably expect from any non-negative gauge of randomness (of real-valued random variables). I) The randomness of a deterministic, i.e. constant, random variable is zero. II) Translating a random variable does not change its randomness: σ [X + b] = σ [X], where b is a real translation parameter. III) Mirroring a random variable does not change its randomness: σ [−X] = σ [X]. IV) Changing the scale of a random variable changes its randomness by the very same scale: σ [s · X] = s · σ [X], where s is a positive scale parameter.
The standard deviation is constructed from a Euclidean-geometry perspective. Shifting the perspective from geometric to probabilistic -while maintaining the aforementioned principal property in mind -we shall now show how to construct a gauge of randomness that quantifies the inherent 'determinism'/'stochasticity' of random variables.
Consider a real-valued random variable X, whose statistical distribution is governed by the density function ϕ (x) (−∞ < x < ∞). Further consider a sample {X 1 , · · · , X ε } comprising ε IID copies of the random variable X, where ε is an integer that is greater than one (ε = 2, 3, · · · ). The likelihood of the coincidence event X 1 = · · · = X ε is: The term C ε [X] appearing in Eq. (3) is a coincidence likelihood that can be interpreted as follows: it is the likelihood that the sample {X 1 , · · · , X ε } will appear as if it was generated deterministically. Hence, the coincidence likelihood C ε [X] is a measure of the inherent 'determinism' of the random variable X. In turn, the reciprocal of the coincidence likelihood, , is a measure of the inherent 'stochasticity' of the random variable X. Now, consider the aforementioned affine transformation, X → aX + b, where a and b are real parameters. It is straightforward to check that the response of the randomness measure 1/C ε [X] to the affine transformation is: . Consequently, if we want to obtain a response (to the affine transformation) that is identical to that of the standard deviation -we need to raise the randomness measure 1/C ε [X] by the power 1/(ε − 1). Doing so we arrive at the diversity [27]- [31]: The diversity D ε [X] is a measure of the inherent 'stochasticity' of the random variable X. The diversity D ε [X] exhibits the principal property that the standard deviation exhibits -the following response to affine transformations: , where a and b are real parameters.
In the special case ε = 2 -which manifests a sample comprising two IID copies of the random variable X -the diversity is the reciprocal of the coincidence likelihood: . This diversity is known as: Simpson's index [22] in biology and ecology -where it is used as a measure of biodiversity; Hirschman's index [23] in economics and competition lawwhere it is applied as a measure of concentration; 1 and participation ratio [24]- [25] in physics -where it is used as a measure of localization. Also, this diversity has a profound relation to the overall correlation of moving-average random processes [50].
Observing Eq. (4) it is evident that the inverse relationship between the diversity D ε [X] and the coincidence likelihood C ε [X] holds for all ε > 1. Thus, mathematically, we can extend Eq. (4) from the integer range ε = 2, 3, · · · to the continuous range ε > 1. Doing so, the logarithm of the diversity ln(D ε [X]) is the Renyi entropy of the random variable X [32]- [34], and ε is the corresponding Renyi exponent. In the special case ε = 2 -which manifests a sample of size two -the logarithm of the diversity, ln(D 2 [X]) = − ln(C 2 [X]), is the collision entropy of the random variable X [26].
Yet another special case of the Renyi entropy is obtained in the Renyi-exponent limit ε → 1, which manifests a sample of size one. Indeed, in this limit the diversity D ε [X] converges to the perplexity of the random variable X [51]. And, the Renyi entropy ln(D ε [X]) converges to the Boltzmann-Gibbs-Shannon entropy of the random variable X [35]- [37].
The first part of this duo [1] explored the effect of the sharp-restart algorithm on randomness via the perspective of the Boltzmann-Gibbs-Shannon entropy. Elevating from this particular entropy to the general Renyi entropy, this part shall explore the effect of the sharp-restart algorithm on randomness via the perspective of diversity.

Raison d'être
With Eq. (1) at hand, the statistical analysis of sharp restart is -in theory -complete. Indeed, Eq.
(1) presents an explicit closed-form formula for the output's density function f R (t) in terms of: the input's density and survival functions, f (t) andF(t); and the sharp-restart timer parameter τ. Thus, given the input's statistical distribution, and setting the timer parameter, one can calculate the output's density function. In turn, various statistics of the output can be further calculated, e.g.: the output's mean (which was the focus of the studies [18]- [19]), as well as higher-order moments of the output; the output's Boltzmann-Gibbs-Shannon entropy (which was the focus of the first part of this duo [1]); and the output's diversity (which is the focus of this paper). So, why bother with the mean-performance analyses of [18]- [19], and with the randomness analyses of this duo?
Well, as stated in the opening sentence of this subsection, the aforementioned 'calculational approach' is fine in theory, yet in practice this approach is rather impractical. Firstly, consider the ideal situation in which the input's statistical distribution is known in full detail. In this situation the calculation of Eq. (1) -which is performed case-by-case, per a given input and per a given timer -provides no general insights regarding the effect of sharp restart on mean-performance and on randomness. Secondly, consider situations in which full information regarding the input's statistical distribution is lacking. In 'real life' the latter situations are prevalent, and in such situations Eq. (1) is outright unusable. Thus, Eq. (1) is a foundational theoretical result, but it is not a practical 'working tool'.
As established in the mean-performance analyses of [18]- [19] and in the entropy analysis of [1], and as shall be established here: 'standing on the shoulders' of Eq. (1), it is possible to construct highly insightful and highly implementable results that altogether circumvent the need to use Eq. (1) directly. Indeed, with remarkably little information about the input's statistical distribution -rather than full knowledge -explicit criteria can be drawn regarding the effect of sharp restart on mean-performance, on randomness, and jointly on mean-performance and randomness. Moreover, these explicit criteria are universal: they are applicable to any input, with any statistical distribution.

Diversity analysis
Having recapped the sharp-restart algorithm, and having reviewed the notion of diversity, we are all set to explore the diversity of sharp restart. This section shall present a statistical analysis of how the application of the sharp-restart algorithm changes the diversity of a given input to that of its output.
In terms of the input's survival and density functions, the output's coincidence likelihood is: Eq. (5) is obtained by applying the coincidence formula of Eq. (3) to the density formula of Eq.
(1). The derivation of Eq. (5) is detailed in the Methods. Note that setting τ = ∞ in Eq. (5) yields the input's coincidence likelihood, C ε [T ] = ∞ 0 f (u) ε du. In the Methods it is further shown that Eq. (5) can be re-written as the product of the coincidence likelihoods of the random variables N and U of Eq. (2), i.e.: Consequently, the product-form of the coincidence likelihoods carries on to the corresponding diversities: To appreciate Eq. (6) we emphasize that, in general, Eq. (2) need not imply Eq. (6). Namely, the diversity of a linear combination of (two) independent random variables is not equal, in general, to the product of the diversities of the (two) random variables. Here, Eq. (2) implies Eq. (6) due to the very specific structure of the sharp-restart algorithm: the one-to-one correspondence between the output T R and the pair (N,U), and the fact that the random variables N and U are independent random variables. 2 In what follows we denote by γ = C ε [T ] the input's coincidence likelihood, and by δ = D ε [T ] the input's diversity. Also, we denote by C (τ) = C ε [T R ] the output's coincidence likelihood, and by D (τ) = D ε [T R ] the output's diversity; this notation underscores the fact that the output's coincidence likelihood and diversity are functions of the timer τ, the parameter of the sharp-restart algorithm. The goal of this study is to explore the effect of the sharp-restart algorithm on diversity. To that end we use the following terminology: • Sharp restart with timer τ decreases diversity if the output's diversity is smaller than the input's diversity, D (τ) < δ . Due to the inverse relation between diversity and coincidence, this is equivalent to the output's coincidence likelihood being larger than that of the input, C (τ) > γ.
• Sharp restart with timer τ increases diversity if the output's diversity is larger than the input's diversity, D (τ) > δ . Due to the inverse relation between diversity and coincidence, this is equivalent to the output's coincidence likelihood being smaller than that of the input, C (τ) < γ.
As an illustrative demonstration of a diversity analysis, consider an input whose distribution is Pareto type II. Pareto distributions [52], which comprise four types, are the principal models of statistical power-laws in science and engineering [53]- [56]. The survival function of a type II Pareto input isF(t) = [1 + (t/s)] −α , where s is a positive scale parameter, and where α is a positive Pareto power. In turn, the density function of a type II Pareto input is Substituting the type II Pareto survival and density functions into Eq. (5), straightforward calculations imply that: the input's coincidence likelihood is γ = . Consequently, the fact that ε > 1 further implies that the output's coincidence likelihood is larger than the input's coincidence likelihood, C (τ) > γ. So, for inputs that are Pareto type II, the following conclusion is attained: sharp restart, with any timer τ, decreases diversity.
The example of a type II Pareto input is depicted in Figure 1. For this example, the above calculations yield a certain reciprocal structure of the output's coincidence likelihood. As shall now be shown, this reciprocal structure is not unique to the type II Pareto example. Rather, the structure holds for any input, and it gives rise to general 'survival criteria' that determine if sharp restart decreases or increases diversity.

Survival criteria
Eq. (5) conceals two statistical distributions that are induced by the input's statistical distribution, and that are defined over the positive half-line. We shall now describe these statistical distributions, and thereafter re-formulate Eq. (5) in their terms. This re-formulation will yield general 'survival criteria' that shall determine -for any given input T , and for any given timer τ -if sharp restart decreases or increases diversity.
The first statistical distribution is governed by the following density function: Evidently, in all three plots the output's coincidence likelihood C(τ) is greater than the input's coincidence likelihood γ, and hence: sharp restart, with any timer τ, decreases diversity.
(t > 0). Evidently, as the input's density function f (t) is positive-valued over the positive halfline, so is the function ψ (t). Moreover, the very definition of the coincidence likelihood γ implies that the function ψ (t) has a unit mass over the positive half-line: For an integer Renyi exponent (ε = 2, 3, · · · ) the density function ψ (t) has the following probabilistic meaning. Consider a sample {T 1 , · · · , T ε } comprising ε IID copies of the random variable T . Then -provided that the coincidence event T 1 = · · · = T ε occurredψ (t) is the likelihood that the common value attained by the IID copies is t.
For an integer Renyi exponent (ε = 2, 3, · · · ) the survival functionΦ (t) has the following probabilistic meaning. As above, consider a sample {T 1 , · · · , T ε } comprising ε IID copies of the random variable T . Then,Φ (t) is the survival function of the sample's minimum, With the two statistical distributions that were introduced, we can now re-formulate Eq. (5). To that end we divide both sides of Eq. (5) by the input's coincidence likelihood γ, and then use the above distribution and survival functions. This yields the following formula for the ratio of the output's coincidence likelihood to the input's coincidence likelihood: Recalling the inverse relation between the diversity and the coincidence likelihood, Eq. (9) straightforwardly implies the following pair of survival criteria: • Sharp restart with timer τ decreases diversity if and only ifΨ (τ) <Φ (τ).
The survival criteria determine if sharp restart decreases/increases diversity by comparing the survival functions of the two statistical distributions that were introduced above. We emphasize that, in general, the survival criteria may provide different answers for different timers τ. Namely, it may be that while sharp restart decreases diversity for some timers τ, it increases diversity for other timers τ (and vice versa).
As an illustrative demonstration of the survival criteria, we re-visit the above example of a Pareto type II input. Recall that in this example the input's survival and density functions are, respectively, where s is a positive scale parameter, and where α is a positive Pareto power). Consequently, straightforward calculations imply thatΨ (τ) = [1 + (τ/s)] −(εα+ε−1) andΦ (τ) = [1 + (τ/s)] −εα . Note that these survival functions are type II Pareto with scale parameter s, and with Pareto powers εα + ε − 1 and εα (respectively). The fact that ε > 1 implies thatΨ (τ) <Φ (τ) (see Figure 1). So, the aforementioned conclusion regarding inputs that are Pareto type II is re-attained: sharp restart, with any timer τ, decreases diversity.

Diversity invariance
To conclude this section, we address the following question: are there inputs that sharp restart neither increases nor decreases their diversity? Specifically, inputs that yield the 'flat' output diversity D(τ) = δ for all timers τ -which is tantamount to the 'flat' output coincidence-likelihood C (τ) = γ for all timers τ.
On the one hand, Eq. (9) implies that C (τ) = γ for all timers τ if and only if the two statistical distributions -governed, respectively, by the density functions ψ (t) and φ (t) -are identical. On the other hand, it is straightforward to check that the density functions ψ (t) and φ (t) are identical if and only if the input's density function is that of the Exponential distribution: f (t) = 1 s exp(−t/s) (t > 0), where s is a positive scale parameter. Thus, combining these two facts together, we arrive at the following diversity conclusions: • The output's diversity is identical to the input's diversity, D (τ) = δ for all timers τ, if and only if the input T is Exponentially-distributed.
• If the input T is not Exponentially-distributed then there exist timers τ with which the output's diversity differs from the input's diversity, D (τ) = δ .
Note that the diversity of an Exponentially-distributed input is s · δ exp , where s is the aforementioned scale parameter, and where δ exp = ε 1/(ε−1) is the diversity of the unit-scale Exponential distribution. 3 The diversity value δ exp will play a key role in sections 5 and 6 below.

Existence results
The pair of survival criteria established in the previous section are timer-specific. Namely, for a given timer τ, the pair of survival criteria determine if sharp restart with that specific timer decreases or increases diversity. In this section we shift from timer-specific criteria to existence criteria: results that determine the very existence of timers with which sharp restart decreases or increases diversity. As the results of the previous section, the results of this section shall also be based on the statistical distributions that were defined via Eqs. (7) and (8).

Existence criteria I
The mean of a statistical distribution that is defined over the positive half-line is given by the integral of its survival function. Hence, the mean of the statistical distribution that is governed by the density function ψ (t) is µ ψ = ∞ 0Ψ (t) dt. Also, the mean of the statistical distribution that is governed by the density function Note that if the integral appearing in Eq. (10) is negative then its integrand -the difference Ψ (τ) −Φ (τ) -must be negative for some τ. Similarly, if the integral is positive then its integrand must be positive for some τ. Thus, combining Eq. (10) together with the survival criteria of section 3 yields the following pair of existence criteria: • If µ ψ < µ φ then there exist timers τ with which sharp restart decreases diversity.
• If µ ψ > µ φ then there exist timers τ with which sharp restart increases diversity.
The existence criteria determine if sharp restart decreases/increases diversity by comparing the means of the two statistical distributions that were introduced in the previous section: the one governed by the density function of Eq. (7), and the one governed by the survival function of Eq. (8). While the survival criteria of the previous section required full knowledge of the two statistical distributions, the existence criteria of this section require knowing only the means of the two statistical distributions.
We note that an alternative way of obtaining these existence criteria is via the following formula: Eq. (11) stems from Eq. (9) via the following steps: subtract 1 from both sides of Eq. (9), multiply by the quantity Φ (τ), integrate over positive half-line, and then use Eq. (10).
Regarding the type II Pareto example, the existence conclusion of this section is in full accord with the survival conclusion of the previous section (which asserted that sharp restart, with any timer τ, decreases diversity). As pointed out above: in order to deduce the existence conclusion one needs to know only the means µ ψ and µ φ , whereas in order to deduce the survival conclusion one needs to have full information of the survival functionsΨ (t) andΦ (t).

Existence criteria II
Set T ψ and T φ to be positive-valued random variables whose statistical distributions are governed, respectively, by the density functions ψ (t) and φ (t). The existence criteria of the previous subsection contested the means of the random variables T ψ and T φ against each other. In this subsection we shall present existence criteria that contest the random variables T ψ and T φ directly against each other.
To that end we introduce the density function φ max (t) = 2Φ (t) φ (t) (t > 0). Specifically, φ max (t) is the density function of the maximum of two IID copies of the random variable T φ .
The following formula emanates from Eq. (9): where the random variables that appear on the right-hand side of Eq. (12), T ψ and T φ , are independent of each other. The derivation of Eq. (12) is detailed in the Methods. Using argumentation which is similar to that following Eq. (10), Eq. (12) yields the following pair of existence criteria: • If Pr T ψ ≤ T φ > 1 2 then there exist timers τ with which sharp restart decreases diversity.
• If Pr T ψ ≤ T φ < 1 2 then there exist timers τ with which sharp restart increases diversity.
The existence criteria determine if sharp restart decreases/increases diversity by contesting the random variable T ψ against the random variable T φ , and then comparing the probability of the event T ψ ≤ T φ to the 'benchmark' probability 1 2 . Equation (12) can be re-formulated in terms of the minimum min {T 1 , T 2 } of two IID copies of the input T . Specifically, denoting by δ min = D ε [min {T 1 , T 2 }] the minimum's diversity, the re-formulation of Eq. (12) is: The derivation of Eq. (13) is detailed in the Methods. Eq. (13) yields the following alternative formulation of this subsection's pair of existence criteria: • If δ > 2δ min then there exist timers τ with which sharp restart decreases diversity.
• If δ < 2δ min then there exist timers τ with which sharp restart increases diversity.
In this formulation, the existence criteria determine if sharp restart decreases/increases diversity by comparing two diversities: that of the input T to that of the minimum min {T 1 , T 2 } of two IID copies of the input T .
As an illustrative demonstration of these existence criteria, consider an input whose distribution is Weibull. The Weibull distribution [57] is one of the three universal laws emanating from the Fisher-Tippett-Gnedenko theorem [58]- [59] of Extreme Value Theory [60]- [62], and it has numerous uses in science and engineering [63]- [65]. The survival function of a Weibull input isF (t) = exp[−(t/s) α ], where s is a positive scale parameter, and where α is a positive Weibull exponent.
The Weibull input displays the following scaling property: min {T 1 , T 2 } = 2 −1/α T , where the equality is in law. In turn, this scaling property implies that δ min = 2 −1/α δ . So, when the Weibull exponent is in the 'sub-Exponential' range α < 1 then: δ > 2δ min , and hence there exist timers τ with which sharp restart decreases diversity. And, when the Weibull exponent is in the 'super-Exponential' range α > 1 then: δ < 2δ min , and hence there exist timers τ with which sharp restart increases diversity.
In the 'sub-Exponential' range α < 1 the Weibull distribution manifests the Stretched Exponential distribution -which plays a key role in statistical physics [66]- [68]. So, in particular, the aforementioned Weibull example yields the following Stretched-Exponential conclusion: there exist timers τ with which sharp restart can always decrease the diversity of Stretched-Exponential tasks. We shall re-visit the Weibull example, and bolster the above Weibull conclusions, in section 6 below.

Asymptotic analysis
Section 3 analysed sharp restart with general timers 0 < τ < ∞. In this section shall address two extreme cases of sharp restart. A) The case of 'high-frequency resetting' which employs very small timers τ 1 -henceforth termed fast timers. B) The case of 'low-frequency resetting' which employs very large timers τ 1 -henceforth termed slow timers. As noted in the introduction, the case of low-frequency resetting attracted substantial scientific interest [38]- [48].

Fast and slow criteria
The cases of sharp restart with fast and slow timers correspond, respectively, to the timer limits τ → 0 and τ → ∞. In order to analyze the asymptotic behavior of sharp restart in these limits we shall use the notion of hazard function (described below). Also, we shall use the shorthand notation ϕ (0) = lim t→0 ϕ (t) and ϕ (∞) = lim t→∞ ϕ (t) for the limit values of a general positivevalued function ϕ (t) that is defined over the positive half-line (t > 0); these limit values are assumed to exist in the wide sense, 0 ≤ ϕ (0) , ϕ (∞) ≤ ∞.
The input's hazard function played a focal role in the entropy analysis [1], in the meanperformance analysis [18], and in the tail-behavior analysis [20] of sharp restart. The input's hazard function is the negative logarithmic derivative of the input's survival function: The hazard function of Eq. (14) has the following probabilistic meaning: H (t) is the likelihood that the input be realized right at time t, given the information that the input was not realized up to time t. The hazard function -a.k.a. "hazard rate" and "failure rate" -is a widely applied tool in survival analysis [69]- [71] and in reliability engineering [72]- [74]. Now, with the input's hazard function H (t) at hand, we are all set to analyze the asymptotic behavior of sharp restart. Eqs. (16)-(17) below will incorporate the number As noted at the end of section 3, the number δ exp is the diversity of the unit-scale Exponential distribution. Firstly, we address the case of fast timers (τ 1). Taking the limit τ → 0 in the middle part of Eq. (9), while using L'Hospital's rule, yields the following limit-value of the output's diversity: The derivation of Eq. (16) is detailed in the Methods. In turn, Eq. (16) implies the following pair of fast criteria.
• If H (0) < δ exp /δ then sharp restart with fast timers increases diversity; in particular, this criterion applies whenever the hazard function vanishes at the origin, H (0) = 0.
• If H (0) > δ exp /δ then sharp restart with fast timers decreases diversity; in particular, this criterion applies whenever the hazard function explodes at the origin, H (0) = ∞.
Secondly, we address the case of slow timers (τ 1). Taking the limit τ → ∞ in the middle part of Eq. (9) yields the following limit-value of the output's coincidence likelihood: C (∞) = γ. In turn, a calculation using Eq. (9) and L'Hospital's rule asserts that the asymptotic behavior of the output's coincidence likelihood C (τ) about its limit value C (∞) = γ is given by the following limit: The derivation of Eq. (17) is detailed in the Methods. In turn, Eq. (17) implies the following pair of slow criteria.
• If H (∞) > δ exp /δ then sharp restart with slow timers increases diversity; in particular, this criterion applies whenever the hazard function explodes at infinity, H (∞) = ∞.
The fast and slow criteria display a common pattern: comparing the limit-values of the hazard function H(t) to the ratio of diversities δ exp /δ . This ratio manifests the height of a flat hazard function that characterizes an Exponential distribution whose diversity is equal to the input's diversity δ . Hence, in effect, the ratio of diversities δ exp /δ serves -in the fast and slow criteria -as an 'Exponential hazard-function benchmark' to which the limit-values of the input's hazard function are compared.

Fast and slow timers
In the previous subsection we addressed the case of fast timers (τ 1), and the case of slow timers (τ 1). However, we did not provide the precise meanings of these timers. Namely: how small should the timer τ be in order to qualify as 'fast'? and how large should the timer τ be in order to qualify as 'slow'? Considering the input's hazard function H (t) to be continuous over the positive half-line (t > 0), in this subsection we answer these two questions.
The interplay between the following terms assumed a key role in the previous subsection: the input's hazard function H (t) on the one hand, and the ratio of diversities δ exp /δ on the other hand. This interplay will assume a key role also in this subsection, via the two following thresholds: and Namely, the thresholds τ * and τ * are, respectively, the smallest and largest times at which the hazard function H (t) intersects the level δ exp /δ . In particular, if the hazard function H (t) does not intersect the level δ exp /δ then: τ * = ∞ and τ * = 0. A calculation based on Eq. (9) yields the following formulae: and The derivations of Eqs. (20) and (21) are detailed in the Methods. In Eqs. (20) and (21), the input's hazard function H(t) is compared to the level δ exp /δ . As noted at the close of the previous subsection, the level δ exp /δ manifests an 'Exponential hazard-function benchmark'. H (0) < δ exp /δ then sharp restart increases diversity for all timers τ in the range τ < τ * . II) If H (0) > δ exp /δ then sharp restart decreases diversity for all timers τ in the range τ < τ * . Hence, the threshold τ * of Eq. (18) defines the range of fast timers.
Consider the case of slow timers: τ 1. The slow-timer criteria of the previous subsection, combined together with Eq. (21), straightforwardly yield the two following conclusions. I) If H (∞) < δ exp /δ then sharp restart decreases diversity for all timers τ in the range τ > τ * . II) If H (∞) > δ exp /δ then sharp restart increases diversity for all timers τ in the range τ > τ * . Hence, the threshold τ * of Eq. (19) defines the range of slow timers.
As an illustrative demonstration of the ranges of fast and slow timers, let us re-visit the Weibull example of section 4. Recall that in this example the survival function isF (t) = exp[−(t/s) α ], where s is a positive scale parameter, and where α is a positive Weibull exponent. Consequently, the hazard function is H(t) = ct α−1 , with coefficient c = αs −α .
When the Weibull exponent is in the 'sub-Exponential' range α < 1 then the hazard function is monotone decreasing from H(0) = ∞ to H(∞) = 0. Hence, the results of the previous subsection assert that sharp restart with either fast or slow timers decreases diversity. The shape of the hazard function implies that it intersects the level δ exp /δ at the unique threshold τ * = τ * = [cδ /δ exp ] 1/(1−α) . Consequently, Eqs. (20) and (21) assert that: sharp restart with any timer decreases diversity (see Figure 2).
When the Weibull exponent is in the 'super-Exponential' range α > 1 the hazard function is monotone increasing from H(0) = 0 to H(∞) = ∞. Hence, the results of the previous subsection assert that sharp restart with either fast or slow timers increases diversity. The shape of the hazard function implies that it intersects the level δ exp /δ at the aforementioned unique threshold (τ * = τ * = [cδ /δ exp ] 1/(1−α) ). Consequently, Eqs. (20) and (21) assert that: sharp restart with any timer increases diversity (see Figure 2).
In fact, the above conclusion regarding the Weibull example in the 'sub-Exponential' range holds for any input whose hazard function is continuous and monotone decreasing from H(0) = ∞ to H(∞) = 0. And, the above conclusion regarding the Weibull example in the 'super-Exponential' range holds for any input whose hazard function is continuous and monotone increasing from H(0) = 0 to H(∞) = ∞.

Joint mean-diversity perspective
The fast and slow criteria developed in the previous section are 'diversity analogues' of fast and slow criteria for the mean-performance of sharp restart [18]. We now turn to intertwine the fast and slow criteria established here together with the fast and slow criteria established in [18] doing so in order to obtain a joint mean-diversity perspective of sharp restart.
Applying sharp restart, the 'input' task-completion time T is mapped to the 'output' taskcompletion time T R . The studies [18]- [19] examined the effect of sharp restart on mean-performance: is the output's mean smaller or larger than the input's mean? In other words, does the mean task-completion time decrease In what follows we use the shorthand µ = E [T ] to denote the input's mean. For fast and slow timers, the following pairs of criteria were established with regard to the effect of sharp restart on mean-performance [18]. Fast criteria: if H (0) < 1/µ then the mean increases; and if H (0) > 1/µ then the mean decreases. Slow criteria: if H (∞) < 1/µ then the mean decreases; and if H (∞) > 1/µ then the mean increases.
Note that the reciprocal of the input's mean 1/µ can be re-written as the ratio µ exp /µ, where: µ exp = 1 is the mean of the unit-scale Exponential distribution. Hence, the fast and slow criteria regarding mean-performance display the following common pattern: comparing the limit values of the hazard function H(t) to the ratio of means µ exp /µ. This pattern is very similar to the aforementioned pattern that the fast and slow criteria regarding diversity display: comparing the limit values of the hazard function H(t) to the ratio of diversities δ exp /δ .
When applying a given sharp restart algorithm, there are four possible mean-diversity scenarios. On the one hand there are two scenarios in which the algorithm has an aligned effect on mean-performance and on diversity: mean decrease and diversity decrease (M ↓-D ↓); mean increase and diversity increase (M ↑-D ↑). On the other hand there are two scenarios in which the algorithm has an antithetical effect on mean-performance and on diversity: mean decrease and diversity increase (M ↓-D ↑); mean increase and diversity decrease (M ↑-D ↓). The similar patterns of the fast and slow criteria yield neat classifications -presented in Tables 1 and 2 of the four mean-diversity scenarios. Alternative representations of these classifications, via mean-diversity phase diagrams, are presented in Figure 3. Table 1 Diversity Decrease Diversity Increase

Mean
Decrease Table 1: Classification of the four mean-diversity scenarios in the case of fast timers (τ 1). The classification uses the numbers µ exp = 1 and δ exp = ε 1/(ε−1) (the mean and the diversity of the unit-scale Exponential distribution), and the following features of the input: its mean µ; its diversity δ ; and the limit-value H (0) of its hazard function. For example, if H (0) > µ exp /µ and H (0) > δ exp /δ , then (when sharp restart with fast timers is applied): both the mean and the diversity of the output will be smaller than that of the input. Table 2 Diversity Decrease Diversity Increase Table 2: Classification of the four mean-diversity scenarios in the case of slow timers (τ 1). The classification uses the numbers µ exp = 1 and δ exp = ε 1/(ε−1) (the mean and the diversity of the unit-scale Exponential distribution), and the following features of the input: its mean µ; its diversity δ ; and the limit-value H (∞) of its hazard function. For example, if H (∞) < µ exp /µ and H (∞) < δ exp /δ , then (when sharp restart with slow timers is applied): both the mean and the diversity of the output will be smaller than that of the input.  (Table 1) and with slow timers ( Table 2). The phase space comprises a horizontal axis that manifests the input's mean µ, and a vertical axis that manifests the input's diversity δ . Rectilinear boarders separate the phase space to four regions that correspond to the four mean-diversity scenarios: mean decrease and diversity decrease (M ↓-D ↓); mean decrease and diversity increase (M ↓-D ↑); mean increase and diversity decrease (M ↑-D ↓); and mean increase and diversity increase (M ↑-D ↑). The rectilinear boarders are based on the numbers µ exp = 1 and δ exp = ε 1/(ε−1) (the mean and the diversity of the unit-scale Exponential distribution), and on the limit-values of the input's hazard function: the limit-value H (0) in the case of fast timers; and the limit-value H (∞) in the case of slow timers.
In order to demonstrate the four mean-diversity scenarios, we end this section with a Pareto-Exponential example: an input with power-law statistics up to the time epoch t = 1, and with exponential statistics afterward. Specifically, the input's density function is f (t) = 1 2 at a−1 over the temporal interval 0 < t ≤ 1, where a is a positive Pareto power. And the input's density function is f (t) = 1 2 b exp[−b(t − 1)] over the temporal ray 1 < t < ∞, where b is a positive Exponential 'rate'.
In this example the input's mean is µ = 1 − 1 2a+2 + 1 2b . With regard to the diversity, we set the Renyi exponent ε = 2 (which corresponds to Simpson's index, to Hirschman's index, and to the participation ratio). Consequently, in this example the input's diversity is finite if and only if the Pareto power is in the range a > 1 2 -in which case δ exp /δ = 2γ = 1 4 ( 2a 2 2a−1 + b). The limit-value H (0) of the input's hazard function depends on the Pareto power as follows: H (0) = ∞ when a < 1 and H (0) = 0 when a > 1. So, for a = 1, sharp restart with fast timers yields the following mean-diversity scenarios: mean decrease and diversity decrease (M ↓-D ↓) when a < 1; and mean increase and diversity increase (M ↑-D ↑) when a > 1. When a = 1 then: the limit-value of the input's hazard function is H (0) = 1 2 ; the input's mean is µ = 3 4 + 1 2b ; and δ exp /δ = 1 2 + 1 4 b. Consequently, for a = 1, sharp restart with fast timers yields the following mean-diversity scenarios: mean decrease and diversity increase (M ↓-D ↑) when b < 2 5 ; mean increase and diversity increase (M ↑-D ↑) when b > 2 5 . The input's hazard function yields the limit-value H (∞) = b. In turn, slow timers lead to all four mean-diversity scenarios. These four scenarios are depicted, in Figure 4, via a phase diagram that corresponds to the two parameters of the Pareto-Exponential example: the Pareto power a, and the Exponential rate b. Note how the simple rectilinear structure of the general phase-diagram of Figure 3 (which is parameterized by the mean µ and by the diversity δ ) shifts to the intricate non-linear structure of the specific phase-diagram of Figure 4  3 < a < 1.

Summary
This paper presented a comprehensive diversity analysis of the sharp-restart algorithm. The algorithm is a non-linear map that receives an input T , a positive-valued random variable that manifests the time it takes to accomplish a given task of interest. Using a positive timer parameter τ, the algorithm restarts the task -as long as it is not accomplished -every τ time-units. Doing so, the algorithm produces an output T R , a positive-valued random variable that manifests the time it takes to accomplish the task under sharp restart. The analysis focused on comparing the output's diversity D (τ) (which is a function of the timer τ) to the input's diversity δ . In turn, this comparison established a detailed diversity roadmap for the sharp-restart algorithm: five pairs of analytic criteria that determine when the application of sharp restart decreases diversity, D (τ) < δ ; and when it increases diversity, D (τ) > δ . These pairs of criteria are summarized in Table 3. The first three pairs of criteria use two statistical distributions that are induced by the input's statistical distribution: one governed by the density function ψ (t) (see Eq. (7)), and the other governed by the density function φ (t) (see Eq. (8)). The last two pairs of criteria use the limit-values, H(0) and H(∞), of the input's hazard function H(t) (see Eq. (14)). Table 3 Timer Parameter Decrease Increase Table 3: Five pairs of diversity criteria regarding the sharp-restart algorithm. The Table's columns specify the features of each pair of criteria: to which timer parameters τ the criteria apply; and when does the application of the sharp-restart algorithm decrease or increase the diversity (of the output, with respect to that of the input). Row I -criteria for general timers (section 3), where:Ψ(t) andΦ(t) are the survival functions of two statistical distributions that are induced by the input's statistical distribution; for an integer Renyi exponent (ε = 2, 3, · · · ), the first induced statistical distribution corresponds to the coincidence of ε IID copies of the input (see Eq. (7), and the second induced statistical distribution corresponds to the minimum of ε IID copies of the input (see Eq. (8). Row II -existence criteria (section 4), where: µ ψ and µ φ are, respectively, the means of the two induced statistical distributions. Row IIIexistence criteria (section 4), where: T ψ and T φ are mutually independent random variables that are drawn, respectively, from the two induced statistical distributions. Row III' -an alternative representation of the existence criteria of row III, where: δ is the input's diversity, and δ min is the diversity of the minimum of two IID copies of the input. Row IV -criteria for fast timers (sections 5 and 6), where: H(0) is the limit value, at zero, of the input's hazard function; δ exp is the diversity of the unit-scale Exponential distribution (see Eq. (15)); and τ * is the upper bound of the range of fast timers (see Eq. (18)). Row V -criteria for slow timers (sections 5 and 6), where: H(∞) is the limit value, at infinity, of the input's hazard function; and τ * is the lower bound of the range of slow timers (see Eq. (19)).
The various criteria display a trade-off between the information they require and the information they provide. For example, the first pair of criteria in Table 3 determine -for any given timer τ -if sharp restart decreases/increases diversity. However, this precise information comes with a high 'price tag': full knowledge of the two induced statistical distributions (that are governed by the density functions ψ (t) and φ (t)). On the other hand, the second pair of criteria in Table 3 determine the very existence of timers with which sharp restart decreases/increases diversity -doing so without pinpointing any particular such timer. This less detailed information comes at a far lower 'price tag': knowing only the means of the two induced statistical distributions.
In the introduction to the first part of this duo [1], it was noted that -given a statistical distribution of interest -scientists commonly strive to 'separate the wheat from the chaff' by distilling the critical information conveyed by the distribution. This goal is attained by analyzing three principal aspects of the given statistical distribution: its mean behavior; its inherent randomness; and its tail behavior -the likelihood of small and large outliers, also known as 'rare events'.
For sharp restart with high-frequency and low-frequency resetting (fast and slow timers), these three aspects come together beautifully in the neat mean-diversity classifications of Tables 1 and 2, and of Figure 3. Indeed, the mean-diversity classifications are based on three numbers emanating from the input's statistical distribution: its mean µ (quantifying the mean behavior); its diversity δ (quantifying the inherent randomness); and the limits of its hazard functionthe hazard limit H(0) which corresponds to small outliers, and the hazard limit H(∞) which corresponds to large outliers. These classifications provide deep understanding and insightswhich are first of their kind -regarding the intricate interplay between restart, mean-behavior, and randomness.
A series of recent works established a set of universal results for the mean-performance of restart protocols: general rules that determine the effect of restart on mean completion times. Yet, to date, similar results for the randomness of completion times were lacking. Going from mean to randomness, this duo presented a comprehensive stochasticity analysis of sharp restart: determining how it affects the entropy and the diversity of completion times. We hope that researchers will follow the path set in this duo, and will further explore the effect of restart on randomness. Possible directions for future research include: Poissonian restart protocols, general restart protocols, and optimization when resetting comes at a cost.