{'fraction_non_alphanumeric': 0.05276190476190476, 'fraction_numerical': 0.019428571428571427, 'mean_word_length': 4.0082670906200315, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 3, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
Adiabatic processes need not correspond to optimal work

The minimum work principle states that work done on a thermally isolated equilibrium system is minimal for the adiabatically slow (reversible) realization of a given process. This principle, one of the formulations of the second law, is studied here for finite (possibly large) quantum systems interacting with macroscopic sources of work. It is shown to be valid as long as the adiabatic energy levels do not cross. If level crossing does occur, counter examples are discussed, showing that the minimum work principle can be violated and that optimal processes are neither adiabatically slow nor reversible.

The second law of thermodynamics 1,2,3 , formulated nearly one and half century ago, continues to be under scrutinity 4,5,6 . While its status within equilibrium thermodynamics and statistical physics is by now wellsettled 1,2,3 , its fate in various border situations is far from being clear. In the macroscopic realm the second law is a set of equivalent statements concerning quantities such as entropy, heat, work, etc. However, in more general situations these statements need not be equivalent and some, e.g. those involving entropy, may have only a limited applicability 5,6 . In contrast to entropy, the concept of work has a well-defined operational meaning for finite systems interacting with macroscopic work sources 2 . It is, perhaps, not accidental that Thomson's formulation of the second law 1,2,3 -no work can be extracted from an equilibrium system by means of a cyclis processwas proven 7,8 both in quantum and classical situation.
Here we study the minimum work principle which extends the Thomson's formulation to non-cyclic processes 1,2,3,8 , and provides a recipe for reducing energy costs. After formulating the principle and discussing it for macroscopic systems, we investigate it for finite systems coupled to macroscopic sources of work. Its domain of validity there is found to be large but definitely limited. These limits are illustrated via counterexamples.
The setup. Consider a quantum system S which is thermally isolated 1,2,3 : it moves according to its own dynamics and interacts with an external macroscopic work source. This interaction is realized via time-dependence of some parameters R(t) = {R 1 (t), R 2 (t), ...} of the system's Hamiltonian H(t) = H{R(t)}. They move along a certain trajectory R(t) which at some initial time t i starts from R i = R(t i ), and ends at R f = R(t f ). The initial and final values of the Hamiltonian are H i = H{R i } and H f = H{R f }, respectively. Initially S is assumed to be in equilibrium at temperature T = 1/β ≥ 0, that is, S is described by a gibbsian density operator: As usual, this equilibrium state is prepared by a weak interaction between S and a macroscopic thermal bath at temperature T 1,2,6 , and then decoupling S from the bath in order to achieve a thermally isolated process 1,2,3 .
The Hamiltonian H(t) generates a unitary evolution: where we performed partial integration and inserted (2). This is the energy increase of S, which coincides with the energy decrease of the source.
The principle. Let S start in the state (1), and let R move between R i and R f along a trajectory R(t). The work done on S is W . Consider the adiabatically slow realization of this process: R proceeds between the same values R i and R f and along the same trajectory, but now with a homogeneously vanishing velocity, thereby taking a very long time t f − t i , at the cost of an amount work W . The minimum-work principle then asserts 1,2,3 This is a statement on optimality: if work has to be extracted from S, W is negative, and to make it as negative as possible one proceeds with very slow velocity. If during some operation work has to be added (W > 0) to S, one wishes to minimize its amount, and operates slowly. For thermally isolated systems, adiabatically slow processes are reversible. This is standard if S is macroscopic 1,2,3 , and below it is shown to hold for a finite S as well, where the definition of reversibility extends unambiguously (i.e., without invoking entropy) 3 .
In macroscopic thermodynamics the minimum work principle is derived 1,3 from certain axioms which ensure that, within the domain of their applicability, this principle is equivalent to other formulations of the second law. Derivations in the context of statistical thermodynamics are presented in 8,9,10 . We discuss one of them now.
The minimal work principle for macroscopic systems is proven in two steps: first one considers the relative entropy tr[ρ(t f ) ln ρ(t f ) − ρ(t f ) ln ρ eq (H f )] between the final state ρ(t f ) given by (2) and an equilibrium state ρ eq (H f ) = exp(−βH f )/Z f , Z f = tr e −βH f , a state corresponding to the final Hamiltonian H f and the same temperature T = 1/β. As follows from (2), tr[ρ(t f ) ln ρ(t f )] = tr[ρ(t i ) ln ρ(t i )]. This combined with (1, 3) and the nonnegativity of relative entropy 2 yields: where F (H i ) and F (H f ) are the gibbsian free energies corresponding to ρ(t i ) and ρ eq (H f ), respectively.
There are several classes of macroscopic systems for which one can show that the free energy difference in the RHS of (5) indeed coincides with the adiabatic work 6,9,10 .
Finite systems. For an arbitrary N -level quantum system S, Eq. (5) does not have the needed physical meaning, since in general F (H f ) − F (H i ) does not coincide with the the adiabatic work. It is known 11 that for finite systems the final density matrix ρ(t f ) given by (2) need not coincide with ρ eq (H f ) = exp(−βH f )/Z f . This fact was recently applied for certain irreversible processes 12 .
Thus we need an independent derivation of (4). Let the spectral resolution of H(t) and ρ(t i ) be At t = t i we order the spectrum as For t i ≤ t ≤ t f we expand on the complete set |n, t : and use (3) to obtain: A similar formula can be derived to express the adiabatic work W in coefficients a kn (t f ). From the definition With help of the identity: x n , we obtain using (10, 11) the general formula for the difference between non-adiabatic and adiabatic work: To understand the meaning of this formula, let us first assume that the ordering (8) is kept at t = t f : If different energy levels did not cross each other (and equal ones do not become different), Eq. (14) is implied by Eq. (8). According to non-crossing rule 13 , if H{R} is real and only one of its parameters is varied with time, (14) is satisfied for any discrete-level quantum system: level-crossing, even if it happens in modeldependent calculations or due to approximate symmetry, does not survive arbitrary small perturbation where it is substituted by avoided crossing (for a more general H{R} the conditions prohibiting level-crossing are more restrictive; see 13 ). No level-crossings and natural conditions of smoothmess of H(t) are sufficient for the standard quantum adiabatic theorem 14 to ensure Combined with (8,15), Eq. (13) brings Eqs. (10,12,14) together with Θ m ≥ 0 extend the minimum work principle (4) to cases where the adiabatic work is not equal to the difference in free energies. Level crossing. The above non-crossing condition raises the question: Is the minimum work principle also valid if the adiabatic energy levels cross? Before addressing this question in detail, let us mention some popular misconceptions which surround the level-crossing problem: 1) The no-crossing rule is said to exclude all crossings. This is incorrect as the exclusion concerns situations where, in particular, only one independent parameter of a real Hamiltonian H{R} is varied 13 . Two parameters can produce robust level-crossing for such Hamiltonians. 2) It is believed that once levels can cross, ∆ε → 0, the very point of the adiabatic theorem disappears as the internal characteristic time /∆ε of S is infinite. This view misidentifies the proper internal time as seen below; see also 15 in this context. 3) It is sometimes believed that crossing is automatically followed by a population inversion. We shall find no support for that.
As a first example we consider a spin-1/2 particle with Hamiltonian where σ 1 , σ 3 and σ 2 = iσ 1 σ 3 are Pauli matrices, and where s is the reduced time with τ being the characteristic time-scale. The magnetic fields h 1 and h 3 smoothly vary in time. Assume that i) for s → s i < 0 and for s → s f > 0, h 1 (s) and h 3 (s) go to constant values sufficiently fast; ii) for s → 0 one has: h 1 (s) ≃ α 1 s 2 , h 3 (s) ≃ −α 3 s, where α 1 and α 3 are positive constants.
iii) h 1 (s) and h 3 (s) are non-zero for all s, s i ≤ s ≤ s f , except s = 0. Not all these points are needed, but we choose them for clarity. Generalizations are indicated below. One writes (16) as where θ(s) = − arctan[h 1 (s)/h 3 (s)] is a parameter in the interval −π/2 < θ < π/2, and where  14) is not valid, and (10-13) imply: Naively this already proves the violation. More carefully, our strategy is now to confirm (15) in the adiabatic limit τ → ∞ and thus to confirm that Θ 1 > 0, implying that the minimum work principle is indeed violated. To this end we apply the standard adiabatic perturbation theory 14 . Substituting (9) into (2) one has: As |1 and |2 in (18) are real, n|n = 1 implies n|∂ t |n = 0. Since n|∂ t |m = 1 τ n|∂ s |m the RHS of (20) contains a small parameter 1/τ . It is more convenient to introduce new variables: a kn (t) = δ kn + b kn (t), b kn (t i ) = 0. To leading order in 1/τ , b kn can be neglected in the RHS of (20), yielding for a k =n (t f ) = b k =n (t f ): For large τ the integral in (21) can be calculated with use of the saddle-point method: Eqs. (21, 23) extend the adiabatic theorem (15) for the level-crossing situation. More general statements of similar adiabatic theorems can be found in Ref. 15 . Inserting Θ 1 = (p 1 − p 2 )|a 12 (t f )| 2 > 0 in Eq. (19) confirms the violation of the minimum work principle. Eq. (23) shows that the role of the proper internal characteristic time is played by α 2 1 /α 3 3 rather than by /(ε 1 − ε 2 ). More generally, if h 2 3 (s) + h 2 1 (s) is a smooth function for all real s (e.g., it is not ∝ |s|), there are no crossings of eigenvalues and (4) is valid. If both h 1 (s) and h 3 (s) are linear for s → 0, the leading term presented in (23) vanishes due to 2|∂ s |1 2 | s=0 = 0, and one needs the secondorder in the saddle-point expansion, to be compared with the second-order term of the adiabatic perturbation theory. This leads to the same physical conclusions as (23) did, but with |a 12 (t f )| 2 ∼ τ −3 .
One can calculate |a kn (t f )| yet in another limiting case, where the characteristic time τ is very short. It is wellknown 14 that in this limit energy changes can be calculated with frozen initial state of S. For the present situation this leads from (18) , again positive. Exactly solvable model with level crossing. Consider a two-level system with Hamiltonian where τ is the characteristic time-scale, and ω is a constant. For s i < 0 denote the adiabatic energy levels as ε 1 (s i ) = ωs i < ε 2 (s i ) = 0. They cross when s passes through zero. Eq. (20) for this model can be solved exactly in terms of hypergeometric functions.
Postponing the detailed discussion, we present in Fig.  1 the behavior of |a 12 (s f )| 2 as a function of τ . Since from (12,24) one has for the present model W − W = − ωs f |a 12 (s f )| 2 tanh( 1 2 β ω |s i | ), violations of the minimum work principle exist for s f > 0, and they are maximal for |a 12 (s f )| 2 → 1. This is seen to be the case in Fig.  1 for some τ near τ = 1. Notice that both the first-order perturbation theory and the saddle-point approximation are adequately reproducing |a 12 (s f )| 2 for τ 10.
Let S has a finite amount of levels, and two of them cross. For quasi-adiabatic processes (τ is large but finite) the transition probability between non-crossing levels is exponentially small 14,16 , while as we saw it has power-law smallness for two crossing levels. Then one neglects in (10) the factors |a k =n (t f )| 2 coming from any non-crossed levels k and n, and the problem is reduced to the two-level situation. Thus already one crossing suffices to detect limits of the minimum work principle. The reduction to the two-level situation takes place also in a macroscopic system which has few discrete levels at the bottom of a continuous spectrum, since for low temperatures these levels can decouple from the rest of the spectrum.
Cyclic processes and reversibility. The above results do not imply any violation of the second law in Thomson's formulation 7 : no work is extracted from S during a cyclic process, W c ≥ 0. We illustrate its general proof in the context of the level crossing model given by (16)(17)(18). Assume that the trajectory R(t) = (h 1 (t), h 2 (t) ) described there is supplemented by another trajectory R ′ (t) which brings the parameters back to their initial values (h 1 (t i ), h 3 (t i ) ) so that the overall process R + R ′ is cyclic. If R ′ crosses the levels backwards, then at the final time of R ′ Eq. (14) is valid, and (10-15) imply: where |a 12 | 2 ≤ 1 now corresponds to the full cyclic process R + R ′ . Eq. (25) confirms the intuitive expectation that non-adiabatic process are less optimal. In particular, this is valid if R ′ is exactly the same process R moved backwards with the same speed. Then W c = 0 means that R is a reversible process in the standard thermodynamical sense 1,2,3 . If R ′ does not induce another level crossing, i.e., h 1 (s) and h 2 (s) in Eq. (16) return to their initial values without simultaneously crossing zero, then ε 1 (t f ) = ε 2 (t i ), ε 2 (t f ) = ε 1 (t i ) and Eqs. (10,15) imply In contrast to (25), non-adiabatic processes are more optimal if R + R ′ contains one level-crossing (or an odd number of them). We thus have found here a violation of the minimum work principle for a cyclic process.
In conclusion, we have studied the minimum work principle for finite systems coupled to external sources of work. As compared to other formulations of the second law, this principle has a direct practical meaning as it provides a recipe for reducing energy costs of various processes. We gave its general proof and have shown that it may become limited if there are crossings of adiabatic energy levels: optimal processes need to be neither slow nor reversible. Already one crossing suffices to note violations of the principle. If this is the case, the optimal process occurs at some finite speed.
Level-crossing was observed, e.g., in molecular and chemical physics 18 . It is not a rare effect 17 : if the number of externally varied parameters is larger then two, then for typical spectra level crossings are even much more frequent than avoided crossings 17 . It is possible that the presented limits of the minimum work principe may serve as a test for level crossings.
Together with the universal validity of Thomson's formulation of the second law 7,8 , the limits of the principle imply that the very equivalence between various formulations of the second law may be broken for a finite system coupled to macroscopic sources of work: different formulations are based on different physical mechanisms and have different ranges of validity. Similar results on non-equivalence of various formulations of the second law were found in Ref. 5,6 , where for a quantum particle coupled to a macroscopic thermal bath, it was shown that some formulations, e.g., Clausius inequality and positivity of the energy dispersion rate, are satisfied at sufficiently high temperatures of the bath, but can be invalid at low temperatures, that is, in the quantum regime.
The work is supported by FOM/NWO (Netherlands).