§3.5, (17)–(18) — first and second laws
OpenQAlgorithms.Papers.Independent.Intake100.P34.energy_lawsAssume detailed balance, positivity improvement, and a common self-adjoint Hamiltonian with reservoir Gibbs states at inverse temperatures . Let , and . Then
The flux is out of a reservoir into the system. These are the second law and the steady first law, with the entropy/energy conversion fixed by that orientation.
import Definitions.Def_QAlgorithms_Papers_Independent_Intake100_P34
noncomputable section
open scoped BigOperators Matrix ComplexConjugate ENNReal NNReal Matrix.Norms.L2Operator ComplexOrder
open MeasureTheory Filter
attribute [local instance] Classical.propDecidable Classical.decEq
namespace QAlgorithms.Papers.Independent.Intake100.P34
open QAlgorithms (IsDensityMatrix)
open QAlgorithms.Papers.Independent.Dependency50.P16 (sandwich)
open QAlgorithms.Papers.Independent.Information100.P26 (Mat commutant scalars)
open QAlgorithms.Papers.Independent.Information100.P30 (MatrixMap IsPositiveMap)
open QAlgorithms.Papers.Independent.Information100.P56 (entropy)
open QAlgorithms.Papers.Independent.Information100.P69 (Faithful)
open QAlgorithms.Papers.Independent.Bridge50.P37 (hsAdjoint)
open QAlgorithms.Papers.Independent.Claimed50.P15
(evaluate finiteRelativeEntropyNats entropyObservable)
open QAlgorithms.Papers.Independent.Claimed50.P43 (chaotic)
/-- PDF p.3: complex linear superoperators. -/
local notation "GeneratorMap" => fun d : ℕ => MatrixMap (Fin d) (Fin d)
/-- PDF p.11, (17)–(18): first and second laws, with flux out of each reservoir. -/
theorem energy_laws {d M : ℕ} (D : DBData d M) (hER : ER D)
(H : Mat d) (beta : EntropyCoordinates M) (hThermal : Thermal D H beta) :
(∀ j, entropyMean D j = -beta j * energyMean D H j) ∧
reservoirEntropyProduction D (steadyDensity (reservoirGenerator D)) = ((-∑ j, beta j * energyMean D H j : ℝ) : EReal) ∧
0 ≤ -∑ j, beta j * energyMean D H j ∧ ∑ j, energyMean D H j = 0 := by sorry
end QAlgorithms.Papers.Independent.Intake100.P34
end
Read-back
What the Lean code literally says, in plain math · gpt-6.1-sol
For any natural numbers , let consist of , positive definite density matrices , Hermitian matrices , and complex-linear maps on , indexed by , such that is completely positive,
and is completely positive and unital for every . Here complete positivity means positivity under all finite identity amplifications and denotes the Hilbert–Schmidt adjoint. Put , and assume sends every nonzero positive semidefinite matrix to a positive definite matrix for every . Let be Hermitian and let satisfy and for every . Define , with , let be the supremum of the real parts of the characteristic roots of , and set . Let be the unique density matrix satisfying if exactly one exists, and otherwise, and set . Finally define
as an extended-real sum, with logarithms interpreted by functional calculus using . Then
The case is included, with empty sums.
Confirmed by the mission captain (proposal self-audit).
Confirmed by the moderator at approval.