Irreversible Performance of a Quantum Harmonic Heat Engine

The unavoidable irreversible losses of power in a heat engine are found to be of quantum origin. Following thermodynamic tradition a model quantum heat engine operating by the Otto cycle is analyzed. The working medium of the model is composed of an ensemble of harmonic oscillators. A link is established between the quantum observables and thermodynamical variables based on the concept of canonical invariance. These quantum variables are sufficient to determine the state of the system and with it all thermodynamical variables. Conditions for optimal work, power and entropy production show that maximum power is a compromise between the quasistatic limit of adiabatic following on the compression and expansion branches and a sudden limit of very short time allocation to these branches. At high temperatures and quasistatic operating conditions the efficiency at maximum power coincides with the endoreversible result. The optimal compression ratio varies from the square root of the temperature ratio in the quasistatic limit where their reversibility is dominated by heat conductance to the temperature ratio to the power of 1/4 in the sudden limit when the irreversibility is dominated by friction. When the engine deviates from adiabatic conditions the performance is subject to friction. The origin of this friction can be traced to the noncommutability of the kinetic and potential energy of the working medium.


Introduction
Our cars, refrigerators, air-conditioners, lasers and power plants are all examples of heat engines. Practically all such heat engines operate far from the ideal maximum efficiency conditions set by Carnot [1]. To maximize the power output efficiency is sacrificed. This trade-off between efficiency and power is the focus of finite time thermodynamics". The field was initiated by the seminal paper of Curzon and Ahlborn [2]. From everyday experience the irreversible phenomena that limits the optimal performance of engines [3] can be identified as losses due to friction, heat leaks, and heat transport. Is there a unifying fundamental explanations for these losses? Is it possible to trace the origin of these phenomena to quantum mechanics? To address these issues we follow the tradition of thermodynamics constructing a model quantum heat engine.
Gedanken heat engines are an integral part of thermodynamical theory. Carnot in 1824 set the stage by analyzing an ideal engine [1,4]. Carnot's analysis preceded the systematic formulation that led to the first and second laws of thermodynamics [5]. Amazingly, thermodynamics was able to keep its independent status despite the development of parallel theories dealing with the same subject matter. Quantum mechanics overlaps thermodynamics in that it describes the state of matter. But in addition, quantum mechanics includes a comprehensive description of dynamics. This suggests that quantum mechanics can originate a concrete interpretation of the word dynamics in thermodynamics leading to a fundamental basis for finite time thermodynamics.
The following questions come to mind: • How do the laws of thermodynamics emerge from quantum mechanics?
• What are the quantum origins of irreversible phenomena involving friction and heat transport? • What is the relation between the quasistatic thermodynamical process and the quantum adiabatic theorem?
To address these issues a model of a reciprocating quantum heat engine is constructed. Extreme care has been taken to choose a model which can be analyzed from first principles. The specific heat engine chosen is a quantum version of the Otto cycle. The present study follows a tradition of analyzing quantum models of reciprocating heat engines [6,7,8,9,10,11,12,13,14,15]. Most of these models can be classified as endoreversible. In such models the source of irreversibility can be traced to the heat transfer between the working medium and the heat baths. Internal irreversibility was studied in a coupled spin working medium [9,10]. The present paper employs an ensemble of harmonic oscillators as a working medium which incorporates both internal and external sources of irreversibility. A quantum version of the Otto cycle is described in section 2. The link between the quantum state and thermodynamical observables is developed in section 3. This model allows a closed form solution of the quantum dynamics (section 4). At low temperature the results have similarities with the spin model, at higher temperatures the well studied finite time thermodynamical performance characteristics appear naturally (section 5).

The quantum Otto cycle
Nicolaus August Otto invented a reciprocating four stroke engine in 1861 and won a gold medal in the 1867 Paris world fair [16]. The basic components of the engine include hot and cold reservoirs, a working medium, and a mechanical output device. The cycle of the engine is defined by four branches: (i) The hot isochore: heat is transferred from the hot bath to the working medium without a volume change. (ii) The power adiabat: the working medium expands producing work while isolated from the hot and cold reservoirs. (iii) The cold isochore: heat is transferred from the working medium to the cold bath without a volume change.
(iv) The compression adiabat: the working medium is compressed consuming power while isolated from the hot and cold reservoirs.
Otto already determined that the efficiency η of the cycle is limited to Cp Cv −1 (where V c/h and T c/h are the volume and temperature of the working medium at the end of the hot and cold isochores respectively) [5]. As expected, the Otto efficiency is always smaller than the efficiency of the Carnot cycle η o ≤ η c = 1 − Tc T h .

Quantum dynamics of the working medium
The quantum analogue of the Otto cycle requires a dynamical description of the working medium, the power output and the heat transport mechanism. The working medium is composed of an ensemble of non interacting particles described by the density operatorρ. These particles are confined by an harmonic potential V (Q) = k 2 Q 2 . Expansion and compression of the working medium is carried out by externally controlling the curvature of the potential k(t). The energy of an individual particle is represented by the Hamiltonian operator: where m is the mass of the system andP andQ are the momentum and position operators. All thermodynamical quantities will be intensive i.e. normalized to the number of particles. In the macroscopic Otto engine the internal energy of the working medium during the adiabatic expansion is inversely proportional to the volume. In the harmonic oscillator, the energy is linear in the frequency ω(t) = k(t)/m [17]. This therefore plays the role of inverse volume 1 V . The Hamiltonian (1) is the generator of the evolution on the adiabatic branches. The frequency ω changes from ω h to ω c in a time period τ hc in the power adiabat (ω h > ω c ) and from ω c to ω h in a period τ ch in the compression adiabat. The dynamics on the stateρ during the adiabatic branches is unitary and is the solution of the Liouville von Neumann equation [18]: whereĤ is time dependent during the evolution. Notice that [Ĥ(t),Ĥ(t ′ )] = 0 since the kinetic energy does not commute with the varying potential energy.
The dynamics on the hot and cold isochores is an equilibration process of the working medium with a bath at temperature T h or T c . This is the dynamics of an open quantum system where the working medium is described explicitly and the influence of the bath implicitly [19,20]: where L D is the dissipative term responsible for driving the working medium to thermal equilibrium, while the HamiltonianĤ =Ĥ(ω) is static. The equilibration is not complete since only a finite time τ h or τ c is allocated to the hot or cold isochores. The dissipative "superoperator" L D must conform to Lindblad's form for a Markovian evolution [19], and for the harmonic oscillator can be expressed as [21,22]: where {Â,B} =ÂB +BÂ. k ↑ and k ↓ are heat conductance rates obeying detailed â † andâ are the raising and lowering operators. Notice that they are different in the hot and cold isochores sincê (4) is known as a quantum Master equation. It is an example of a reduced description where the dynamics of the working medium is sought explicitly while the baths are described implicitly by two parameters: the heat conductivity Γ = k ↓ − k ↑ and the bath temperature T . The Lindblad form of (4) guarantees that the density operator of the extended system (system+bath) remains positive (i.e. physical) [19]. Specifically, for the harmonic oscillator, (4) has been derived from first principles by many different authors [22].
To summarize, the quantum model Otto cycle is composed of a working fluid of harmonic oscillators (1), with volume corresponding to 1/ω. The power stroke is modelled by the Liouville von Neumann equation (2) while the heat transport via a Master equation (3,4). It differs from the thermodynamical model in that a finite time period is allocated to each of these branches. Solving these equations for different operating conditions allows to obtain the quantum thermodynamical observables.

Quantum thermodynamics
Thermodynamics is notorious in its ability to describe a process employing an extremely small number of variables. A minimal set of quantum expectations X n constitutes the analogue description where X n = T r{X nρ }. The dynamics of this set is generated by the Heisenberg equations of motioṅ where the first term addresses an explicitly time dependent set of operators,X(t).
To move from dynamics to thermodynamics we need to consider the three laws. The energy expectation E is obtained whenX =Ĥ, i.e. E = Ĥ . The quantum analogue of the first law of thermodynamics [23,24] dE = dW + dQ is obtained by insertingĤ into (5): The power is identified as P =Ẇ = ∂Ĥ ∂t . The heat exchange rate becomeṡ Q = L * D (Ĥ) . The Otto cycle contains the simplification that power is produced or consumed only on the adiabats and heat transfer takes place only on the isochores.
The third law is trivially manifest for a system at thermal equilibrium (Gibbs state) at temperature zero. The intricacies of proving the second law in the general case are beyond this paper. Instead, in accordance with thermodynamic tradition, its applicability will be demonstrated for a closed cycle. Note that thermodynamics will be maintained even though the system is not generally in thermal equilibrium.
The thermodynamic state of a system is fully determined by the thermodynamical variables. Statistical thermodynamics adds the prescription that the state is determined by the maximum entropy condition subject to the constraints set by the thermodynamical observables [25,26,27]. Maximizing the Von Neumann entropy [18] subject to the energy constraint leads to thermal equilibrium [27], where k B is Boltzmann constant and Z = T r{e −Ĥ k B T } is the partition function. The state of the working medium in general is not in thermal equilibrium. In order to generalize the canonical form (8) additional observables are required to define the state of the system. The maximum entropy state subject to this set of observables where β j are Lagrange multipliers. The generalized canonical form of (9) is meaningful only if the state can be cast in the canonical form during the entire cycle of the engine leading to β j = β j (t). This requirement is called canonical invariance [28]. A necessary condition for canonical invariance is that the set of operatorsX in (9) is closed under the dynamics generated by the equation of motion. If this conditions is also sufficient for canonical invariance, then the state of the system can be reconstructed from a small number of quantum observables X j (t), which are the thermodynamical observables in the sense that they define the state under the maximum entropy principle. The condition for Canonical invariance on the unitary part of the evolution taking place on the adiabats is as follows. If the Hamiltonian is a linear combination of the operators in the setĤ(t) = m h mXm (h m (t) are expansion coefficients), and the set forms a closed Lie algebra [X j ,X k ] = l C jk lX l (where C jk l is the structure factor of the Lie algebra), then the setX is closed under the evolution [29]. In addition canonical invariance prevails [30].
For the Otto cycle the set of the operatorsP 2 ,Q 2 andD = (QP +PQ) form a closed Lie algebra. Since the Hamiltonian is a linear combination of the two first operators of the set (P 2 andQ 2 ), canonical invariance will result on the adiabatic branches.
On the isochores the set has to be closed also to the operation of L D . The set P 2 ,Q 2 andD is also closed to L D defined by (4). This condition is only necessary for canonical invariance. Nevertheless for the harmonic working medium and L D defined in (4) the closure is also sufficient for canonical invariance to take place (Cf. Appendix A).
The significance of canonical invariance is that all quantities become functions of a very limited set of thermodynamic quantum observables X j . The choice of operatorsX j should reflect the most telling thermodynamical variables. Explicitly for the current engine the thermodynamical variables are chosen to be the expectations of the following operators: • The position momentum correlationD = (QP +PQ).
These operators are linear combinations of the same Lie algebra asQ 2 ,P 2 andD.
To make explicit the connection between the expectation values of the closed set of operators and the state of the systemρ an alternative product form for the density operator is used. It is defined by the parameters β, γ and γ * : From (10) the expectations ofĤ andâ 2 are extracted leading to and Equations (12) and (13) can be inverted leading to γ =h and Equations (14) and (15) make explicit the relation between the state of the systemρ (by equation (10)) and the thermodynamical observables Ĥ , D and L .

Entropy balance
In thermodynamics the entropy S is a state variable. Shannon introduced entropy as a measure of the missing information required to define a probability distribution p [31]. The information entropy can be applied to a complete quantum measurement of an observable represented by the operatorÔ with possible outcomes p j : where p j = T r{P jρ }. The projectionsP j are defined using the spectral decomposition theoremÔ = j λ jPj , where λ j are the eigenvalues of the operatorÔ. SÔ is then the measure of information gain obtained by the measurement. The Von Neumann entropy is equivalent to the minimum entropy SŶ n associated with a complete measurement of the stateρ, by the observableŶ n where the set of operatorsŶ n includes all possible non degenerate operators in the Hilbert space. The operator that minimizes the entropy commutes with the state [ρ,Ŷ min ] = 0. Obviously S V N ≤ SÔ. This supplies the interpretation that S V N is the minimum information required to completely specify the stateρ.
The primary thermodynamic variable for the heat engine is energy. The entropy associated with the measurement of energy S E = SĤ in general differs from the Von Neumann entropy S E ≥ S V N . Only whenρ is diagonal in the energy representation, such as in thermal equilibrium (8), The Von Neumann entropy is invariant under a unitary evolution [30]. This is the result of the property of unitary transformations where the set of eigenvalues ofρ ′ =ÛρÛ † is equal to the set of eigenvalues ofρ. Since the von Neumann entropy S V N is a functional of the eigenvalues ofρ it becomes invariant to any unitary transformation. In particular when applying a unitary transformation generated by the HamiltonianĤ ′ to a thermal stateρ(0) = exp(−Ĥ/k b T )/Z then if [Ĥ ′ ,ρ(0)] = 0, the unitary transformation will always increase the energy entropy, S E (t) ≥ S E (0). Nevertheless the Von Neumann entropy will stay invariant S V N (t) = S V N (0) = S E (0).
To find the Von Neumann entropy for the oscillator, the product-form of the density operator (10) is rewritten aŝ where the relation between the coefficients χ in (17) and γ and β in the product form (10) are evaluated in Appendix B , equation (B.5).
Employing (17) the Von Neumann entropy becomes: Equation (18) shows that S V N is a functional of the thermodynamical variables Ĥ , D and L . The energy entropy S E of the oscillator (not in equilibrium) is found to be equivalent to the entropy of an oscillator in thermal equilibrium with the same energy expectation: (19) is completely determined by the energy expectation E = Ĥ . As an extreme example, for a squeezed state S V N = 0 and S E ≥ 0. In a macroscopic working medium, the internal temperature can be defined from the entropy and energy variables 1/T int = ∂S ∂E V at constant volume. For the quantum Otto cycle, S E is used to define the inverse internal temperature 1/T int = ∂SE ∂E ω . T int is a generalized temperature appropriate for non equilibrium density operatorsρ. Using this definition the internal temperature T int of the oscillator working medium can be calculated implicitly from the energy expectation: which is equivalent to the relation between temperature and energy in thermal equilibrium.
The entropy expressions (18) and (19) for the working medium illustrate that entropy changes along the cycle trajectory. Once the cycle reaches a limit cycle (Cf. Sec. (5.1)) then the internal entropy changes become cyclic. As a result any entropy change becomes zero [10]. The irreversible character of the operation concentrates therefore in the entropy production in the thermal baths. Assuming a structureless reservoir, the entropy production is calculated from the heat transfer from the working medium: where T h and T c are the hot and cold bath temperatures andQ hQc are the heat fluxes Cf. equation (6).

Solving the dynamics of the quantum Otto cycle
The strategy to solve the dynamics of the working fluid along the engine's cycle of operation relies on obtaining closed form equations for the quantum thermodynamical observables and on using them to reconstruct the state of the system using the maximum entropy relation (9).

Heisenberg dynamics on the Isochores
The working medium dynamics on the isochores represent an approach to thermal equilibrium where the HamiltonianĤ is constant (ω = ω h/c is constant). The Heisenberg equations of motion for an operatorX arė Equation (22) is the analogue of (3) and (4) in the Schrödinger frame.
For the dynamical set of observables, the equations of motion become where Γ = k ↓ − k ↑ is the heat conductance and k ↑ /k ↓ = e −hω/kB T obeys detailed balance where ω = ω h/c and T = T h/c are defined for the hot or cold bath respectively. From (6) the heat current can be identified as: where T B is the bath temperature. In the high temperature limit the heat transport law becomes Newtonian: The solution of the isochore dynamics (23) becomes: where the equilibrium value of the energy is E = Ĥ eq =h ω 2 coth(h ω 2kB T ). The equilibration dynamics are characterized by the energy exponentially relaxing to its equilibrium value. The LagrangianL and the momentum-position correlation D show a damped oscillation with a frequency of 2ω to an equilibrium value of zero. The identity operatorÎ becomes a constant of motion representing the conservation of norm.

The dynamics on the Adiabats
On the adiabats the oscillator frequency changes from ω h to ω c on the power expansion branch and from ω c to ω h on the compression branch. As a result the Hamiltonian is explicitly time dependent and [Ĥ(t),Ĥ(t ′ )] = 0. Under these conditions the Heisenberg equations of motion (5) for the dynamical set of operators become In general all operators in (27) are dynamically coupled. The coupling can be characterized by the nonadiabatic parameter α =ω ω . It is important to notice that α has no explicit dependence on the mass of the oscillator. This means that the nonadiabatic character is universal. For example from the first law (6) the power can be identified as The power on the adiabats (28) can be decomposed to the "useful" external power P ex = α Ĥ and to the power invested to counter friction P f = −α L . It is "friction" in the sense that it reduces the power and is zero when the motion is infinitely slow and increases with speed (see below). The translation of this effect into the actual reduction of power, however, cannot be separated from the dissipative branches. A solution of the dynamics depends on an explicit dependence of ω(t) on time, and it can always be carried out numerically. An illustrative example is found when the non-adiabatic parameter α =ω ω is constant during the adiabatic branches. This leads to the explicit time dependence ω(t) = ω 0 e αt = ω h ωc ω h t/τ hc on the power adiabat, and a similar expression for the compression adiabat. Under these conditions the time derivative in (27) becomes stationary allowing a closed form solution to be obtained by diagonalizing the matrix in (27).
Two simplifying limits exist. The first is the quasistatic limit, which is defined by α ≪ ω. In this case the fast motion (neglecting α) can be evaluated first in (27) leading to a zeroth order expression forL andD. From that expression one can construct an ansatz correct to first order in α ω : where α is the accumulated phase. For small α ω , φ diverges leading to fast oscillation ofL(t). As a resultL can be averaged out in the equation of the slow variableĤ leading to: The outcome of the quasistatic conditions is that the Hamiltonian follows adiabatically the change in frequency ω. This limit is equivalent to the invariance of the number operatorN = 1 hωĤ − 1 2Î in the evolution, i.e. N = constant. In this limit the power invested to counter friction is zero, P f = 0.
A higher order expression for the energyĤ can be obtained by integration, and will be useful in the consideration of friction. To second order in α ω the energyĤ on the adiabat becomes Averaging over the fast oscillation,sin(φ) = 0 leads to: The other extreme condition is the sudden limit when α ≫ ω. The fast variables can be integrated first leading to Ĥ andD staying constant up to first order in ω α . The dynamics can be translated to the final expectation at the end of the adiabat: Ĥ where ω i/f is either ω h or ω c depending on whether the evolution takes place on the power or on the compression adiabat.

The Engine In Action
We can now turn to look at the engine cycle as a whole. The four branches of the engine can be summarized as follows:

The limit cycle
Once the engine is ignited it is expected that it will settle down to a smooth mode of operation determined by the control parameters. This asymptotic cycle will be termed the limit cycle.
The dynamics of the four strokes of the cycle can be represented by the cycle propagator: It is therefore expected that each point of the limit cycle trajectory is invariant to the propagator U cyc Â limit = Â limit (we choose point A). The cycle propagator is a product of the branch propagators. They belong to the class of completely positive maps, U cyc therefore, is also a completely positive map. It has been proven that if Â limit is unique then a repeated application of U cyc will lead monotonically to the limit cycle [32,10]. This means that the limit cycle has to close. Consequently all variables are cyclic. This property allows to study the optimal performance of the operating engine. A typical limit cycle trajectory is shown in figure 2. The oscillation of L and D on the isochores with a different frequency ω h or ω c is clearly seen. The canonical invariance condition is preserved by the limit cycle. Moreover even if the initial state of the system does not belong to the class of canonical invariant states after a few cycles it will approach monotonically such a state [10].

Optimizing the operation of the engine
Finite time thermodynamics allows us to optimize power as well as efficiency. We will assume, for simplicity, that the external parameters are fixed. These include the bath parameters T h and T c as well as the heat transport rates Γ h and Γ c . At first the frequencies ω h and ω c and with them the compression ratio C = ω h /ω c are also set. The optimization is carried out with respect to the time allocations on each of the engine's branches: τ h , τ hc , τ c , and τ ch . This sets the total cycle time τ = τ h + τ hc + τ c + τ ch .
The maximum efficiency limit is obtained for infinite time allocations on all branches. This cycle maximizes the work output. Its trajectory passes through the points W E Q F in figure 1, and the efficiency reaches the value η o = 1 − ωc ω h . Since for this limit the cycle time τ is infinite, obviously the power of this cycle is zero.
Optimizing the power is far more interesting. It requires a finite cycle time τ . As a result the optimizer has to compromise and shorten the time allocated to equilibration on the isochores. In addition restricting the time on the adiabats results in nonadiabatic conditions that expose the nature of friction.

5.2.1.
Optimizing the operation of the engine for quasistatic conditions. The power optimization in the quasistatic regime is determined by heat transport from the hot and cold baths. To reach quasistatic conditions, ample time is allocated to the adiabats (Cf. equation (30)). As a consequence, the Number operator becomes invariant on the adiabats.
The time allocations on the isochores determine the change in the number operator N = N (Cf. equation (25)): eq + N h eq on the hot isochore, where N B is the number expectation value at the end of the hot isochore, N A at the beginning and N h eq is the equilibrium value point E. A similar expression exists for the cold isochore.
The work in the limit cycle becomes where the convention of the sign of the work for a working engine is negative, in correspondence with Callen [5]. The heat transport from the hot bath becomes The efficiency η becomes independent of the time allocations: In the limit cycle for adiabatic conditions N D = N A which leads to the relation By demanding a closed cycle the number change N B − N D is calculated, leading to: where the scaled time allocations are defined x c ≡ Γ c τ c , and x h ≡ Γ h τ h . The work W q (40) becomes a product of two functions: G W which is a function of the static constraints of the engine and F which describes the heat transport on the isochores. Explicitly the function G W is 0 ≤ F ≤ 1, therefore for the engine to produce work G W ≥ 0. The first term in (41) is positive. Therefore G W ≥ 0 translates in to the restriction that ωc ω h ≥ Tc T h or in terms of the compression ratio 1 ≤ C ≤ T h Tc . This is equivalent to the statement that the maximum efficiency of the Otto cycle is smaller than the Carnot efficiency η o ≤ η c .
In the high temperature limit whenh ω In this case the work W q = −G W F can be optimized with respect to the compression ratio C = ω h ωc for fixed bath temperatures. The optimum is found at C = T h Tc . As a result the efficiency at maximum power for high temperatures becomes which is the well known efficiency at maximum power of an endoreversible engine [2,6,24,33,34]. Note that these results indicate greater validity to the Curzon-Ahlborn result from what their original derivation [2] indicates. The function F defined in (40) characterizes the heat transport to the working medium. As expected F maximizes when infinite time is allocated to the isochores. The optimal partitioning of the time allocation between the hot and cold isochores is obtained when: If (and only if) Γ h = Γ c the optimal time allocations on the isochores becomes τ h = τ c . Optimizing the total cycle power output P is equivalent to optimizing F/τ since G W is determined by the engine's external constraints. The total time allocation τ = τ iso + τ adi is partitioned to the time on the adiabats τ adi which is limited by the adiabatic condition, and the time τ iso allocated to the isochores.
Optimizing the time allocation on the isochores subject to (44) leads to the optimal condition When Γ h = Γ c ≡ Γ this expression simplifies to: For small x equation (46) can be solved leading to the optimal time allocation on the isochores: τ c = τ h ≈ (Γτ adi /3) 1 3 /Γ. Taking into consideration the restriction on the adiabatic condition this time can be estimated to be: . When the heat transport rate Γ is sufficiently large, the optimal power conditions lead to the Bang-Bang solution where vanishingly small time is allocated to all branches of the engine [32].
For the conditions Γ ≡ Γ c = Γ h , and restricting the time allocation on the adiabat to be τ adi = 1 ωc + 1 ω h , the quasistatic optimal power production as a function of cycle time τ becomes: which is an upper limit to the power production Cf. figures 5, 6 and 7.
The entropy production ∆S U (21) reflects the irreversible character of the engine. In quasistatic conditions the irreversibility is completely associated with the heat transport. ∆S U can also be factorized to a product of two functions: where F is identical to the F function defined in (40). The function G S becomes: Due to the common F (x c , x h ) function the entropy production has the same dependence on the time allocations τ h and τ c as the work W [8]. As a consequence maximizing the power will also maximize the entropy production rate ∆S U /τ . Note that entropy production is always positive, even for cycles that produce no work as their compression ratio C is too large, which is a statement of the second law. The dependence of the G s function on the compression ratio can be simplified in the high temperature limit leading to: which is a monotonic decreasing function in the range 1 ≤ C ≤ T h Tc that reaches a minimum at the Carnot boundary when C = T h Tc .

5.2.2.
Lost work required to counter the friction Quasistatic conditions only obtain for infinitely long adiabats. To determine the validity and applicability of this limit, we must consider shorter adiabats and verify our results to higher orders. We must consider finite adiabatic branches which will lead to friction (Cf. equation (28)). The accumulated work required to overcome the friction is defined as: for each adiabatic branch. To second order in the nonadiabatic coupling α ω , the accumulated work becomes: Averaging on the fast oscillating phase φ leads to: When D (0) = 0 and Γ → ∞, the accumulated work to counter friction on both adiabats for the limit cycle becomes which at the high temperature limit simplifies to Equations (54) and (55) reflect the finite time allocation on the adiabat (i.e. the finiteness of α) which always reduces the produced work relative to the quasistatic case [9]. Remember that for an engine producing work W = W q + W f should be negative. This justifies the use of the term "friction". When the friction is sufficiently large, no work can be produced at all in the given engine. This can be seen in figure  4, showing the quasistatic work W q corrected by W f as a function of the temperature ratio r = T h Tc . The entropy production due to friction is At the limit of high temperature (56) simplifies to ∆S f = 1 4 α ωc Tc . The nonadiabatic nature of the motion leads to an increase in entropy production in the baths, in accordance with our conceptions of "friction".

5.2.3.
Optimizing the engine in the sudden limit The extreme case of the performance of an engine with zero time allocation on the adiabats is dominated by the frictional terms. These terms arise from the inability of the working medium to follow adiabatically the external change in potential. A closed form expression for the sudden limit can be derived based on the adiabatic branch propagator U hc and U ch (34). The expressions are complex and therefore will not be presented.
Insight on the sudden limit can be obtained when the heat conductance terms Γ become infinite. The performance therefore is solely determined by the friction. For this limiting case the work per cycle becomes: The maximum produced work −W s can be optimized with respect to the compression ratio C. At the high temperature limit: For the quasistatic optimal compression ratio C = T h Tc , W s is zero. The optimal compression ratio for the sudden limit is C = T h Tc 1/4 , leading to the maximal work in the high temperature limit The efficiency at the maximal work point is Equation (60) leads to the following hierarchy of the engines maximum work efficiencies: Equation (61) leads to the interpretation that when the engine is constrained by friction its efficiency is smaller than the endoreversible efficiency where the engine is constrained by heat transport that is smaller than the ideal Carnot efficiency. At the limit of T c → 0, η s = 1 2 and η q = η c = 1. An upper limit to the work invested in friction W f is obtained by subtracting the maximum work in the quasistatic limit (40) from the maximum work in the sudden limit (57). In both these cases infinite heat conductance is assumed leading to N B = N h eq and N D = N c eq . Then the upper limit of work invested to counter friction becomes: At high temperature (62) simplifies to: Figure 4 compares the maximum produced work at the high temperature limit of the quasistatic and sudden limits for the compression ratio that optimizes the quasistatic Tc and the sudden work C = ( T h Tc ) 1/4 . The work against friction W f (equation (63)) can be identified the figure as an increasing function of the temperature ratio. For the compression ratio that optimizes the quasistatic limit the sudden work is zero. This means that all the useful work is balanced by the work against friction W f = W q . Zero produced work is obtained in the quasistatic limit for the compression ratio C = T h Tc and becomes negative for the sudden limit. Tc . The plot is at the high temperature limit for three compression ratios: C = r (triangles) corresponding to the Carnot limit, C = r 1/2 (solid) corresponding to the endoreversible optimum compression ratio and C = r 1/4 (dotted) corresponding to the sudden optimum. The work against friction in the sudden limit W f = Wq − Ws is indicated.

Optimal Power Production
The full range of the performance options of the engine is explored by finding the limit cycle numerically for a random set of time allocations τ h , τ hc , τ c , τ ch , on the different branches. Figure 5 displays the power as a function of total cycle time and efficiency for the compression ratio C = T h /T c that optimizes the quasistatic limit at high temperatures. All plots show a clear global maximum in efficiency at a specific cycle time. In all cases, the deviation of the maximum power point from the quasistatic estimate is not large. Therefore the efficiency at maximum power is quite close to the maximum Otto efficiency η o At large cycle times the optimal power obtained by optimizing the time allocations fits very nicely the quasistatic limit. A closer examination of the cycles with optimal time allocation shows that they form a discontinuous set. At different total cycle times τ different combinations of time allocation lead to maximum power. Underneath the optimal time allocation we can identify cycles which are classified as being sudden either on the hot-to-cold adiabat or cold-to-hot adiabat. When the heat conductance Γ is high these sudden cycles outperform the quasistatic ones at short times. Cycles which could be classified as sudden on both adiabats are absent in this plot since they produce almost zero power. This is expected for the compression ratio C = T h /T c for which W s is zero (Cf. equation (63) ).  The compression ratio is chosen to correspond to the optimal value in the quasistatic limit C = T h /Tc. Upper panels are for large values of heat transport (Γ = 0.6) and the lower panels are for small value of heat transport (Γ = 0.03). The graph was produced from a random sample of time allocations on all branches (gray filled squares). The black circles represent the optimal time allocation values which correlate to the quasistatic limit. The blue triangles classify the sudden limit on the cold-to-hot adiabat. The red squares classify the sudden limit on the hot-to-cold adiabat. The Carnot efficiency ηc, endoreversible (CA) efficiency ηq the Otto efficiency ηo and the sudden efficiency ηs are indicated in the right panels. The purple line represents Pq, the quasistatic power limit (47). quasistatic limit when the heat conductance is small. A careful examination of figure  6 show some cycles with low power output that exceed the Otto efficiency. This is not a contradiction since the limit restricts only quasistatic cycles. Thus some sudden like cycles can exceed this limit. In addition at high heat conductivity a reminiscent of some bang-bang cycles at very short cycle times can be identified.
Operating the engine in the compression ratio corresponding to the optimum for the sudden limit C = (T h /T c ) 1/4 unravels a different set of optimal time allocations leading to maximum power. This can be observed in figure 7 which shows the power as a function of cycle time and its efficiency for this compression ratio. For conditions of high heat conductance the sudden cycles on both adiabats out-perform all other cycles. These cycles are very close to the bang-bang solutions. The efficiency at maximum power also corresponds to this limit (Cf. equation (60)).

Discussion
The performance of the model Otto engine shows close resemblance to macroscopic real engines. The power has a definite maximum which is the result of a compromise between minimizing heat transport losses and frictional losses [35]. How does this phenomena emerge from the quantum origins of the engine? Put more boldly what is quantum in the engine?
The quantum laws governing the heat transport from the baths to the working medium (equations (4) and (22)) have been derived from first principles [20,22] in the Markovian limit. This limit guarantees the tensor product form of the extended system, allowing for a separation between the local variables of the system and the rest. This separation is a prerequisite for a thermodynamic description [36]. Nonmarkovian models may also lead to a similar structure [37], but are beyond the scope of the present study. The irreversibility in these equations can be interpreted as emerging from a quantum measurement [20,38,39]. Specifically for the present system they coincide with the linear Newtonian heat transport law at high temperature. The compression ratio is chosen to correspond to the optimal value in the sudden limit C = T h Tc 1/4 . Upper panels are for large values of heat transport (Γ = 0.6) and the lower panels are for small value of heat transport (Γ = 0.03). The graph was produced from a random sample of time allocations on all branches (gray filled squares). The black circles represent the optimal time allocation values which correlate to the quasistatic limit. The blue triangles classify the sudden limit on the cold-to-hot adiabat. The red squares classify the sudden limit on the hot-to-cold adiabat. The Carnot efficiency ηc, endoreversible (CA) efficiency ηq the Otto efficiency ηo and the sudden efficiency ηs are indicated in the right panels. The purple line represents the quasistatic power limit (47).
The quantum nature of the heat transport on the isochores becomes significant at low temperatures whenh ω kB T ≥ 1. Planck's constant relates the frequency to a discrete energy unithω. The expressions for work (equations (40) and (57)) and power production (equation (47)) are linearly related to this Quant of energy. At higher temperatures the energy unit is replaced by k B T andh disappears. Moreover the thermodynamical expressions for maximum power and efficiency coincide with well established relations known from finite time thermodynamics [3,34]. The finding is in line with the study of Geva et. al. [7] which has shown that although the quantum heat transport laws are not linear in general (equation (24)), and the system can be far from equilibrium, nevertheless they lead at high temperatures to the Curzon Ahlborn efficiency [2] at maximum power.
The rapid dynamics on the adiabatic branches is responsible for the frictional behaviour. The quantum origin can be traced to the noncommutability of the Hamiltonian at different times. As a result the system is not able to adiabatically follow the instantaneous energy representation. For the harmonic model the origin of the noncommutability comes about from the kinetic energy not commuting with the potential energy, the origin of which is the fundamental relation [Q,P ] = ih. Plank's constant appearing in the commutation relation of the kinetic and potential energy [P 2 2m , kQ 2 2 ] = ih ω 2 2D (Cf. equation (1)) is cancelled by the inverse of Planck's constant appearing in the equation of motion (2) or (22).
The deviation from adiabaticity is independent of the mass of the oscillator. This inertial effect appears only in the combination α =ω/ω the nonadiabatic parameter. This means that friction like behaviour is expected whenever the internal timescale of the working medium is comparable to the engines cycle time. Without a dissipative branch, however, this "friction" cannot be interpreted as such -it is even reversible.
The most important noncommutability of the engine is between the branch propagators [U ch , U c ] = 0 or [U hc , U h ] = 0, composing the cycle propagator U cyc in equation (35). The sequence of alternating propagations of adiabats and isochores is what breaks the time reversal symmetry and allows the engine to produce power irreversibly.

Conclusion
The quantum Otto cycle model engine served its purpose of unravelling the emergence of thermodynamics out of quantum mechanics. Due to the simplicity of a working medium composed of harmonic oscillators the following insights have been illustrated: • Thermodynamical variables are related to quantum observables which are sufficient to reconstruct the state of the working medium. The energy variable is supplemented by additional variables required to describe the deviation from adiabatic behaviour in the limit cycle. The knowledge of these observables enables the calculation of thermodynamical variables such as entropy and temperature. The first law emerges as a statement accounting for the energy change in an open quantum system. The second law is related to the fact that the energy entropy is always larger than the von Neumann entropy which is invariant to free evolution. The information required to restore the von Neumann entropy from the energy entropy is partially erased on the isochores. The open dynamics on the isochores can be considered as a partial measurement of energy. As a result information on the operatorsL andD which do not commute with energy is lost. • Quantum origins of irreversible losses are due to heat transport and with it the unavoidable dephasing. Quasistatic cycles which almost follow adiabatically the energy frame show irreversible losses dominated by heat transport. The optimal performance of these cycles closely resembles the endoreversible limit.
• Deviation from quantum adiabatic behaviour is reflected by frictional losses which emerge from the generation of inertial components on the adiabats and their dephasing on the isochores. The frictional loss terms are independent of the cycle direction of motion. • At high temperatures, explicit quantum variables and constants disappear. The performance of the engine shows universal behaviour which is a function of temperature T compression ratio C and the ratio between the cycle frequency proportional to α and the internal frequency of the working medium ω. In addition to the derivations outlined below, a full derivation of the results presented in this paper can be found in the Mathematica notebook file, "HOE.nb" which can be downloaded from www.fh.huji.ac.il/˜yairr. For canonical invariance to prevail during the evolution L(ρ)ρ −1 also should become a linear combination of the set of operators {X}. This will lead to N coupled differential equations for the coefficients µ(t).
The simpler case is when the Hamiltonian is also composed of a linear combination of the same algebra then L(ρ)ρ −1 = −ih[Ĥ,ρ]ρ −1 = −ihĤ −ihρĤρ −1 forming a linear sum of the same set {X} and canonical invariance prevails.
For an open quantum system the equivalent statement would be that in addition L D (ρ)ρ −1 also forms a linear combination of the set {X}. This condition becomes: whereF are Lindblad operators [19]. Specifically for the harmonic oscillator setP 2 ,Q 2 andD = (QP +PQ) and the Lindblad operatorF =â this condition is met. On the contrary forF =Ĥ ,Ĥ 2 is not part of the Lie algebra therefore, canonical invariance is not met in the case of pure dephasing.

Appendix B. The relations between the parameters in the product form and the exponential form
The state of the system can be expressed in an exponent product form (10) or as an exponent of an operator sum (17). To determine this equivalence, the expression ρâρ −1 andρâ †ρ−1 are evaluated. The normalization Z is identical for both forms and therefore is not considered. In the exponent-product form (10) using the Baiker-Housdorff formula one obtains: Using the operator sum form (17) to evaluate the same two expressions, leads to: Equating both formula pairs results in the identification: which establishes the relation between γ and β in the product form (17) and χ in the the operator sum form (10).