Optimal processes for probabilistic work extraction beyond the second law

According to the second law of thermodynamics, for every transformation performed on a system which is in contact with an environment of fixed temperature, the average extracted work is bounded by the decrease of the free energy of the system. However, in a single realization of a generic process, the extracted work is subject to statistical fluctuations which may allow for probabilistic violations of the previous bound. We are interested in enhancing this effect, i.e. we look for thermodynamic processes that maximize the probability of extracting work above a given arbitrary threshold. For any process obeying the Jarzynski identity, we determine an upper bound for the work extraction probability that depends also on the minimum amount of work that we are willing to extract in case of failure, or on the average work we wish to extract from the system. Then we show that this bound can be saturated within the thermodynamic formalism of quantum discrete processes composed by sequences of unitary quenches and complete thermalizations. We explicitly determine the optimal protocol which is given by two quasi-static isothermal transformations separated by a finite unitary quench.

In classical thermodynamics 1 the (Helmholtz) free energy of a system at thermal equilibrium is defined as F := U − TS, where U is the internal energy, T is the temperature and S is the entropy. Whenever the environment is characterized by a fixed and unique temperature T, in every process connecting two states having free energy F in and F fin respectively, the work done by the system is upper bounded by the free energy reduction in fin The previous inequality is a direct manifestation of the second law of thermodynamics. Indeed for a cyclic process Δ F = 0 and the bound (1) states that no positive work can be extracted from a single heat bath. However, according to the microscopic theory of statistical mechanics 1 , the work done by a system in a given transformation is non-deterministic and can present statistical fluctuations [2][3][4][5] . For macroscopic systems, like a gas in contact with a moving piston, these fluctuations are usually negligible and one can replace all random variables with their averages recovering the thermodynamic bound (1). For sufficiently "small" systems, i.e. those in which the number of degrees of freedom are limited and the energies involved are of the order of k B T, fluctuations are important and for each repetition of a given protocol the system can produce a different amount of work, which can be described as a random variable with an associated probability distribution [3][4][5] . Moreover a further source of difficulty in the description of "small" systems, like nano-scale devices, molecules, atoms, electrons, etc., is that quantum effects are often non-negligible and quantum fluctuations can also affect the work extraction process [6][7][8][9] .
The properties and the constraints characterizing the work probability distribution of a given process are captured by the so called fluctuation theorems which can be defined both for classical 2,5,10-12 and quantum systems [13][14][15][16] . These theorems can be seen as generalizations of the second law for processes characterized by large statistical fluctuations. Indeed it can be shown 11,12 that the expectation value of the work distribution always satisfies the bound (1), while for a single-shot realization of the protocol it is in principle possible to extract a larger amount of work at the price of succeeding with a small probability 3,4,12,17,18 .
Our aim is to identify the optimal protocols for maximizing the probability of extracting work above a given threshold Λ , arbitrarily larger than the bound (1). Differently from standard thermodynamics in which the optimal procedures are usually identified with the quasi-static (reversible) transformations saturating the inequality (1), for the problem we are considering, fluctuations are necessary in order to probabilistically violate the second law. Consequently, in this case optimality will require some degree of irreversibility. In our analysis we shall focus on processes obeying the Jarzynski identity 11,[13][14][15] which include all those transformations where a system originally at thermal equilibrium evolves under an externally controlled, time-dependent Hamiltonian and proper concatenations of similar transformations. In this context, as a first step we identify an upper bound for the probability of work extraction above the threshold Λ which depends on the minimum amount of work W min that we are willing to extract in case of failure of the procedure. We also identify the class of optimal protocols that enable one to saturate such bound. These correspond to have two quasi-static transformations separated by a single, abrupt modification of the Hamiltonian (unitary quench), the associated work distribution being characterised by only two possible outcomes: one arbitrarily above the bound (1) (success) and one below (failure). Explicit examples are presented in the context of discrete thermal processes 19,20 and in the context of one-molecule Szilard-like heat engines 21 .
In the second part of the paper we focus instead on the upper bound for the probability of work extraction above a given threshold Λ which applies to all those processes that ensure a fixed value μ of the average extracted work. Also in this case we present explicit protocols which enable one to saturate the bound: it turns out that they belong to the same class of the optimal protocols we presented in the first part of the manuscript (i.e. two quasi-static transformations separated by a single, unitary quench).

Work Extraction Above Threshold Under Minimal Work Constraint
In 1997 11 , motivated by molecular biology experiments, C. Jarzynski derived an identity characterizing the probability distribution P (W) of the work done by a system which is initially in a thermal state of temperature T and it is subject to a process interpolating from H in to H fin . The process can be an Hamiltonian transformation or, more generally, an open dynamics obeying the requirement of microreversibility 10 . The identity is the following: with F in , F fin being the free energies associated to the canonical thermal states with Hamiltonian H in and H fin respectively. Notice that, while F in corresponds to the actual free energy of the initial state, F fin is not directly related to the final state which may be out of equilibrium but only to its final Hamiltonian (in all the processes considered in this work, however the initial and final states are always thermal, and F fin is also the actual free energy of the system). Notice also that by a simple convexity argument applied to the exponent on the right-hand-side of Eq. (2) one gets the inequality which is the counterpart of (1) for non-deterministic processes. For quantum systems, because of the intrinsic uncertainties characterizing quantum states, identifying a proper definition of work is still a matter of research 6,9,[22][23][24] . However, if we assume to perform a measurement of the energy of the system before and after a given unitary process, the work extracted during the process is operationally well defined as the decrease of the measured energy. Also in this quantum scenario, it can be shown [13][14][15] that the work distribution obeys the Jarzynski identity (2). Among all (unitary or non-unitary) processes interpolating from an initial Hamiltonian H in to a final Hamiltonian H fin and fulfilling (2), we are interested in maximizing the probability of extracting work above a given arbitrary threshold Λ, i.e. in computing the quantity This problem is particularly interesting and non-trivial only when the threshold is beyond the limit (1) imposed by the second law, i.e. when Λ > − Δ F. Indeed for lower values of Λ, it is known that the probability (4) can be maximized to 1 by an arbitrary thermodynamically reversible (quasi-static) process, deterministically extracting W = − Δ F. Exploiting statistical fluctuations, larger values of work can be extracted 3,4,12,17,18 . But what are the corresponding probabilities and the associated optimal processes?
To tackle this problem we start considering those processes which, beside fulfilling (2), satisfy also the constraint min with W min an assigned value smaller than or equal to Λ (consistency condition being Λ the work threshold above which we would like to operate) and − Δ F (by construction, being the latter an upper bound to the average work of the process, see Equation (3)). This corresponds to set a lower limit on the minimum amount of work that we are willing to extract in the worst case scenario, the unconstrained scenario being recovered by setting W min → − ∞ (instead taking W min = 0 we select those processes where, in all the statistical realizations no work is ever provided to the system). Under the above hypothesis the following inequality can be established F W W min min which in the unrestricted regime W min → − ∞ , yields The proof of the general bound (7) follows straightforwardly from the identity (2) and the definitions of Λ and W min . Indeed, we can split the integral appearing in (2) as the sum of two terms that can be independently bounded as follows:  (7) finally follows by solving the resulting inequality for P (W ≥ Λ). We summarize the bounds given in this this paragraph in Fig. 1.

Attainability of the bound (7)
. By close inspection of the derivation (9) it is clear that the only way to saturate the inequality (7) is by means of processes whose work distribution is the convex combination of two delta functions centered respectively at W = W min and W = Λ , i.e.  Yet it is not obvious whether such transformations exist nor how one could implement them while still obeying the Jarzynski identity. To deal with this question in the following we present two different schemes both capable of fulfilling these requirements proving hence that the following identity holds: and −ΔF = 1. If Λ ≤ − Δ F the probability of success is equal to 1 independently from W min . For Λ ≥ − Δ F the bound is non trivial and is given by Eq. (7). Values of W min larger than Λ or larger than − Δ F needs not to be considered.
Scientific RepoRts | 6:29282 | DOI: 10.1038/srep29282 (see Fig. 1 for a contour plot of this optimal probability). The first example is based on a specific theoretical framework (the discrete quantum process approach) introduced in ref. 20 for modeling thermodynamic transformations applied to quantum systems. While the attainability of (7) does not require us to consider a full quantum treatment (only the presence of discrete energy exchanges being needed, not quantum coherence), the use of this technique turns out to be useful as it provides a simplified, yet fully exhaustive description of the involved transformations. The second example is instead fully classical and it is based on an idealized one-molecule Szilard-like heat engine.

Optimal transformations by discrete quantum processes. Following the approach presented in refs
19 and 20 in this section we consider protocols composed by the concatenation of only two types of operations: discrete unitary quenches (DUQs) and discrete thermalizing transformations (DTTs). A DUQ applied to a system described by an input density matrix ρ and Hamiltonian H, is an arbitrary change of the latter which does not affect the former, i.e.
DUQ DUQ H′ being the final Hamiltonian of the system. A DTT instead is a complete thermalization towards a Gibbs state of temperature T without changing the system Hamiltonian, i.e. DTT and Z := Tr[e −βH ] the associated partition function. Operationally, a DUQ can be implemented by an instantaneous change of the Hamiltonian realized while keeping the system thermally isolated. A DTT instead can be obtained by weakly coupling the system with the environment for a sufficiently long time. The convenience for introducing such elementary processes is that the energy exchanged during a DUQ and a DTT can be thermodynamically interpreted as work and heat respectively, without any risk of ambiguity typical of continuous transformations in which the Hamiltonian and the state are simultaneously changed. On the other hand, as shown in refs 19 and 20, continuous transformations can be well approximated by a sequence of infinitesimal DUQs and DTTs.
In order to show that Eq. (7) can be saturated we then focus on a N-long sequence of alternating DUQs and DTTs operated at the same temperature T and connecting an input Gibbs state ω β Step 1: , , Step 2: , , Step : , , Step : , ,  where for j = 0, 1, ···, N, H j represents the Hamiltonian of the system at the end of the DUQ of the j-th step and where for easy of notation we set H 0 := H in and H N := H fin . As further assumption we shall also restrict the analysis to those cases where all the H j entering the sequence (the initial and the final one included) mutually commute, i.e. [H j , H j+1 ] = 0. Accordingly the action of each DUQ corresponds to a simple shift of the energy levels without changing the corresponding eigenstates: Also, since all the Gibbs states ω β are diagonal in the same energy basis k { }, quantum coherence will not play any role in the process, meaning that the results we obtain could be directly applicable to classical models. This is not a strong limitation since, as we are going to show, thermodynamically optimal processes saturating (7) are already obtainable within this limited set of semi-classical operations.
To determine the probability distribution of work for a generic sequence (15) observe that in the j-th step work can be extracted from (or injected to) the system only during the associated DUQ 20 . Here the state is described by being the probability of finding it into the k-th energy eigenstate whose energy passes from − E k j ( 1) to E k j ( ) during the quench. When this happens the system acquires a () of work production (the system being thermally isolated during each DUQ). Accordingly the probability distribution of the work done by the system during the j-th step can be expressed as the sum of a collection of Dirac delta functions: At the next step the system first thermalizes via a DTT which, independently from the previous history of the process, brings in the Gibbs state ω β H ( ) j , and then undergoes to a new DUQ that produces an extra amount of work W j+1 whose statistical distribution P j+1 (W j+1 ) can be expressed as in Eq. (18) by replacing j with j + 1. The total work W extracted during the whole transformation (15) can finally be computed by summing all the W j 's, the resulting probability distribution being which can be easily shown to satisfy the Jarzynski identity (2) (see section Methods) and hence the inequality (7) which follows from it. It is a basic result of thermodynamics and statistical mechanics that the inequality (1) can be saturated by isothermal transformations in which the system is changed very slowly in such a way that its state remains always in equilibrium with the bath 1 . These operations are usually called quasi-static or reversible. In the framework of discrete quantum processes quasi-static transformations can be obtained in the limit of infinite steps N → ∞ while keeping fixed the initial and final Hamiltonian of the sequence. Indeed, as shown in refs 19 and 20, interpolating between the initial and final Hamiltonian by a sequence of infinitesimal changes (e.g. fulfilling the con- ) each followed by complete thermalizations, one can saturate the bound (1). In terms of the probability distribution (19) one can easily show 19 that in the quasi-static limit we obtain a delta function N which means that for every realization of the process the work extracted is the maximum allowed by the second law (1) with negligible fluctuations. This can be understood from the fact that the total work W is the sum of N independent random variables W j and therefore we expect the fluctuations around the mean 〈 W〉 to decay as N 1/ . Moreover, since the Jarzynski identity (2) must hold, the only possible value for the mean of an infinitely sharp distribution is 〈 W〉 = − Δ F.
We can now come back to our original problem of determining the maximum probability of extracting an amount of work larger than an arbitrary value Λ, for fixed values of the initial and final Hamiltonians H in and H fin .
If the threshold is below the free energy decrease of the system, i.e. if Λ ≤ − Δ F, the problem is trivial. In this case a quasi-static transformation interpolating between the initial and final Hamiltonian is optimal. Indeed, as expressed in Eq. (20), the work extracted in the process is deterministically equal to − Δ F which is larger than Λ . Formally, integrating (20), we have that for a quasi-static process The cumulative work extraction probability (21) shows that, although quasi-static processes are optimal for Λ ≤ − Δ F, they are absolutely useless for Λ > − Δ F where the probability drops to zero. Then, if we want to explore the region Λ > − Δ F which is beyond the limit imposed by the second law, it is clear that we have to exploit statistical fluctuations typical of non-equilibrium processes.
Scientific RepoRts | 6:29282 | DOI: 10.1038/srep29282 Consider next the case of a threshold larger than the decrease of free energy Λ > − Δ F. To identify an optimal process fulfilling (7) it is sufficient to focus on the simplest scenario of a two-level system with energy eigenstates |0〉 and |1〉 and such that the eigenvalue associated with |0〉 always nullifies, i.e.
In this way the generic process described in (15) is completely characterized by assigning a sequence of N + 1 parameters Let us then focus on the protocol composed by the following three steps and summarized in Fig. 3: (a) perform a quasi-static transformation from the initial value E in to the value E a to be fixed later on: with  being a small increment which we shall send to zero while sending the associated number of steps a a in  to infinity; (b) apply a finite DUQ from E a to another arbitrary value E b > E a also to be fixed later on, followed by a complete thermalization: (c) perform a quasi-static transformation from E b to the desired final value E fin : where, as in step a),  is a small increment which we shall send to zero by sending the associated number of In the limit → 0  , since the initial and final configurations are fixed the only free parameters of this protocol are E a and E b , and they will affect the final probability distribution of the work done by the system. In particular according to Eq. (20), the work extracted in the two quasi-static transformations a) and c) is deterministically given by the corresponding free energy reductions, i.e. the quantities  probability 1 − p). Accordingly the total work W = W a + W b + W c is a convex combination of two delta functions: max m in Figure 3. Scheme of the optimal process saturating the bound (7), valid for a two-level system with Hamiltonian H = E 1 |1〉〈1|. The process is divided in three steps: a) a quasi-static transformation where the value of E 1 varies from E in to E a , b) an Hamiltonian quench from E a to E b followed by a thermalization, c) a final quasi-static transformation from E b to E fin .
Equation (27) is of the form required to saturate (7), see Eq. (10). Indeed from Eqs (28) and (29) it is easy to check that all values of W max > − Δ F and W min < − Δ F can be obtained by properly choosing E a and E b , with E b > E a . Moreover the function that gives W min and W max from E a and E b is a bijection, that can be inverted obtaining:   (10) and (11) are finally obtained from (27) and (32) by simply taking W max = Λ.
From the above analysis it is evident that optimal processes saturating (7) can be obtained only for transformations that are quasi-static apart from a single finite DUQ which introduces a single probabilistic dichotomy on the final work distribution as required by Eq. (10). For a two-level system, we have just shown that they are characterized by the two parameters E a and E b (the values of E in and E fin being fixed by the initial and final Hamiltonians). However their choice is also completely determined by the desired maximum and minimum work values entering (7): Λ and W min . Therefore we conclude that, for a two-level system, the optimal process presented here is unique up to global shifts of the energy levels (which we have fixed imposing ). This however is no longer the case when operating on d-level systems with d ≥ 3, multiple number of optimal protocols being allowed in this case (see section Methods for details).

Optimal transformations by one-molecule Szilard-like heat engine.
In this section we present a second example of a process which allows us to saturate the bound (7). At variance with the one introduced in the previous section the model we analyze here is fully classical even though slightly exotic as it assumes the existence of an ideal gas composed by a single particle (same trick adopted in ref. 21). As shown in Fig. 4 such a classical particle is placed in a box divided in two chambers by a wall, in which a little door can be opened allowing the particle to switch from a side to the other. The right edge of the box is connected to a piston, that can extract mechanical work, and the whole system is in contact with a heat bath of temperature T.
In the initial and final configuration the door is open, the only difference being the position of the piston. The free energy difference can be computed following the relation F = U − TS and the fact that the entropy depends logarithmically on the volume 1 : We will show that, in order to saturate the equation (7) with the above initial and final conditions the optimal protocol is the following (see Fig. 5): (a) keeping the door opened, perform a reversible isothermal expansion from the volume V in to the volume V a to be fixed later on; (b) after closing the door, do a reversible isothermal compression from the volume V a to the volume V b , then open the door and let the system thermalize; (c) perform a reversible isothermal expansion from the volume V b to the volume V fin .
The work extracted during the isothermal expansions a) and c) is   1. The particle is in the left side, then the compression requires no work. 2. The particle is in the right side then the work extracted is the negative quantity where V L is the constant volume of the left chamber. Now observing that the probability of the particle being in the left chamber is just equal to the ratio between V L and V a , i.e. p = V L /V a the work distribution of the process can be expressed as: where the second equality can be obtained with a little algebra and the last one follows multiplying both the numerator and the denominator by . Then, as in the case of the discrete quantum process analyzed in the previous section, this protocol saturates the inequality (7) by simply setting W max = Λ , the values of V a and V b being univocally fixed by the relations: min whose positivity is guaranteed once again by the ordering (33). The protocol presented here clearly shares strong similarities with the two-level model presented in the previous section. Indeed the two reversible isothermal expansions in which the particle is free to go throw the door can be put in a formal correspondence with the two quasi-static transformations of Fig. 5. Analogously the intermediate compression of Fig. 5 corresponds to the finite DUQ of the quantum model. Notice finally that, since in the ideal gas model the closing of the door at stage b) is a reversible operation, it looks like we are extracting work in a reversible way over the threshold − Δ F, a fact which is impossible 1 . This however is not the case since the thermalization that follows the opening of the door after the compression makes the process globally irreversible and the probabilistic outdoing of − Δ F is fully justified.

Work Extraction Above Threshold Under Average Work Constraint
In the previous section we derived a bound for the probability P (W > Λ ) when the minimum extracted work W min is fixed. We are going to solve the same problem with a different constraint, fixing the average extracted work instead of the minimum, i.e. replacing Eq. (6) with the condition with μ ≤ Λ being a fixed value. As we shall see in the following this problem admits optimal processes which have the same dichotomic structure as the optimal solutions one gets when imposing the constraint on the minimal work production. To be more precise Eqs (10) and (11) still provide the optimal solutions by setting W min to fulfil Eq. (42), i.e. solving for the following transcendental equation Noticing that μ is strictly increasing in W min for every fixed Λ (see Fig. 6) and so there exists one and only one value W min [Λ , μ] that solves equation (43). We can then conclude that the optimal probability in this case is given by the function [ , ] min min which we have plotted in Fig. 7 for fixed values of Δ F and β. To prove the above results we adopt the Lagrange multiplier technique to study the stationary points of Eq. (4) under the constraint (42). Also, to avoid technicalities we find it convenient to discretize the probability distribution, a trick which allows us to impose the positivity of P (W) by parametrizing it as q 2 (W) with q(W) being an arbitrary function. Accordingly the Lagrangian of the problem can be written in this way: where λ J , λ μ and λ 1 are the Lagrange multipliers that enforce, respectively, the Jarzynski identity (2), the average constraint (42), and the normalization. Deriving with respect to q(W) we hence obtain the following Lagrange equation: with Θ (W) being the Heaviside step function. The above identity must hold for all W: accordingly the supports of q(W) and of the function in the square brackets must be complementary. This last term nullifies in at most three  points (say W 1 , W 2 , and W 3 ), only one of which (say W 3 ) is above the threshold Λ (verifying this property is easy, since the zeroes are the crossing points between an exponential function and a piecewise linear function). Thus we can suppose that q(W), and hence the corresponding probability distribution P (W) = q 2 (W), is non zero on only these selected points. Indicating with p 1 , p 2 and p 3 the values assumed by P (W) on W 1 , W 2 and W 3 we can then express the problem constraints as follows Among all possible solutions of these last equations we have finally to select those which provide the maximum value for the probability of extracting work above the threshold Λ , i.e. remembering that only W 3 can be larger than or equal to Λ , this corresponds to select the solution with the largest value of p 3 . To solve this last problem we resort once more to the Lagrange multiplier technique under the Karush-Kuhn-Tucker conditions 25 to enforce the positivity of W 3 − Λ . Accordingly the new Lagrangian is now ) 0 and 0 (51) 3 The KKT conditions are necessary (even if not sufficient) for a point to be a constrained maximum, and they allow two kind of solutions: 1. The maximum is in the internal part of the region described by the inequality constraint, then W 3 ≠ Λ and by the conditions (51) we obtain η = 0. In this case the Lagrange equations relative to W i (i = 1, 2, 3) are: if one or more of the p i are equal to zero, the W k for k ≠ i are all equal. These solutions have to be rejected, because they fail to satisfy the constraint (48). 2. The maximum is on the boundary of the inequality constraint then W 3 = Λ. From the conditions (51) η can be different from 0, then, although the Lagrange equations for W 1 and W 2 are still described by the (52) the one for W 3 is not. Thus either W 1 = W 2 ≤ Λ = W 3 or one between p 1 and p 2 vanishes. In both cases the support of the work distribution reduces to two points.
We conclude that in order to maximize P (W ≥ Λ) when the average extracted work μ is fixed, the distribution must be different from zero in only two values, Λ , and a smaller one we call W min , i.e. as anticipated at the beginning of the section, they must have the form (10) yielding Eq. (44) as the optimal probability of work extraction above threshold.

Discussion
In this paper we studied single-shot thermodynamic processes focusing on the specific task of probabilistically extracting more work than what is allowed by the second law of thermodynamics. We found that for all processes obeying the Jarzynski identity, there exists an upper bound (7) to the work extraction probability which depends on: how large is the desired violation, the minimum work that we are willing to extract in case of failure, and the free energy difference between the final and initial states. Moreover, within the formalism of discrete quantum processes, we have shown that the bound can be saturated and we determined the corresponding optimal protocols. Analogous results have been obtained also when replacing the constraint on the minimal work with a constraint on the average work extracted during the process.
With our analysis we hope to contribute to the yet quite unexplored regime 3,4,12,17,18 in which statistical fluctuations are not considered as a problem but as an advantage of microscopic thermodynamics, in the sense that they can be artificially enhanced in order to obtain tasks which are otherwise impossible in the thermodynamic limit. With respect to standard thermodynamics, in this regime we should adopt a completely different paradigm for judging what is a "good" process. Indeed quasi-static processes are usually considered as optimal since they are reversible, they do not produce excess entropy, they allow to reach the Carnot efficiency, etc. On the other hand, as we have shown in this work, in specific regimes in which fluctuations are "useful" the perspective is reversed and non-equilibrium processes becomes operationally optimal.
Our findings could be experimentally demonstrated in every classical or quantum thermodynamics experiment involving large work fluctuations. For example experimental scenarios which are currently promising are: organic molecules 26,27 , NMR systems 28,29 , electronic circuits 30,31 , trapped ions 32 , colloidal particles 33 , etc. In all these contexts, up to now the task has been mainly focused on the verification of quantum thermodynamic principles and fluctuation theorems. We believe that, similar experimental settings can be easily optimized in order to maximize the probability of work extraction, approximately realizing the ideal processes proposed in this work.
Scientific RepoRts | 6:29282 | DOI: 10.1038/srep29282 Methods Jarzynski identity for the discrete process. Here we show that the discrete process described by the sequence (15) satisfies the Jarzynski identity (2). Ultimately this is a direct consequence of the fact that each single DUT + DTT process fulfills such relation 13  Optimal processes for discrete transformation with d > 2 level systems. In the main text we have shown that a two level system is already enough to achieve the maximum work extraction probability dictated by the bound (7). However, for experimental reasons, one may be forced to work with a system characterized by d > 2 energy levels, and we may be interested in determining what are the optimal processes in this context. In the main text we noticed that the presence of only one quench is a necessary condition to saturate the bound (7). That kind of reasoning holds for systems of arbitrary dimension, from which Eq. (10) is obviously independent. Thus, looking for an optimal process involving a d-dimensional system we have to slightly modify the procedure described in the main text although the structure remains the same. Explicitly: 1. Perform a quasi-static transformation that brings all the initial energies eigenvalues E k (0) of the system to their final values, except one of them (say the m-th one), that is instead brought to the value E a which will be fixed later on, i.e.  (55) we find that p as exactly the same form we have for the d = 2 case, i.e. Eq. (32). As a final remark we notice that the protocol saturating the bound is not unique for d ≥ 3, because in this case there are multiple degrees of freedom in the system. For example there are different equivalent choices of the energy level E m , moreover other optimal protocols involving multi-level quenches could exist.