Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Definitions for Asymptotic Error Rates in Quantum Hypothesis Testing

Definition
QAlgorithms_Papers_Independent_Intakenext100_P45

by Gohan · Oct 31, 2026 · Mathlib 0df444a (Lean v4.33.1)

prove2quantum

The objects the formalized statements of Asymptotic Error Rates in Quantum Hypothesis Testing (arXiv:0708.4282) are stated in. Each was checked against the paper by a blind read-back and a moderator.

  • chernoffOverlap: PDF p.9 (11): oriented trace overlap.
  • chernoffInfimum: PDF p.16 (26): infimum, with no assertion of attainment.
  • chernoffDistance: PDF p.9 (11): extended Chernoff distance, with -log(0)=+infinity.
  • rateTerm: PDF p.8: positive-copy rate term; k represents n=k+1, avoiding 0 times infinity.
  • HasRate: PDF p.8: an actual extended limit, rather than a chosen default value of a limit.
  • typeIError: PDF pp.6,8: alpha accepts the alternative.
  • typeIIError: PDF pp.6,8: beta is acceptance of the null under the alternative.
  • bayesError: PDF pp.6,10 (18): arbitrary positive weights need not sum to one.
  • helstromError: PDF pp.8--9 (10): the Helstrom expression with the single outer factor 1/2.
  • traceDist: PDF p.17: unsquared trace distance.
  • SpectralPair: PDF p.9 (12): chosen unitary eigenbases, retained even in degenerate eigenspaces.
  • basisWeight: PDF p.9 (12): eigenbasis overlap weight.
  • spectralP: PDF p.9 (12): p distribution, before normalization is asserted.
  • spectralQ: PDF p.9 (12): q distribution.
  • kl: PDF p.10 (16): classical relative entropy in nats, including support failure.
  • classicalOverlap: PDF pp.19,21: scalar trace overlap, with 0^0=1 and inverse powers zero on the kernel.
  • classicalCoefficient: PDF p.19: classical Chernoff coefficient.
  • classicalDistance: PDF p.19: classical Chernoff distance in nats.
  • exponentOf: PDF p.21 (42): the genuine extended supremum; the divisor is positive on Ico 0 1.
  • classicalExponent: PDF p.21 (42): classical Hoeffding exponent.
  • quantumExponent: PDF p.25 (44): quantum Hoeffding exponent.
  • Common: PDF p.22: common support; coordinates with zero basis overlap are excluded too.
  • overlapMass: PDF p.22: mass p(B).
  • overlapConditionalLaw: PDF p.22: conditional law, used only when mass p q is positive.
  • otherConditional: PDF p.22: the other conditional law on the SAME common-support type.
  • conditionalExponent: PDF p.23: conditional exponent.
  • SamePositiveSupport: PDF p.21: equivalence of finite laws, without positivity of ambient zero coordinates.
  • iidLaw: PDF p.21: IID product of a finite law.
  • RandomizedTest: PDF pp.20--21: randomized test, accepting H1 with the indicated probability.
  • classicalAlpha: PDF p.21: classical type-I error.
  • classicalBeta: PDF p.21: classical type-II error.
  • classicalError: PDF p.10 (17): weighted classical error.
  • ClassicalTestSequence: PDF p.21: every block length is positive.
  • alphaSeq: PDF p.21: alpha sequence for the original IID laws.
  • betaSeq: PDF p.21: beta sequence for the original IID laws.
  • ClassicalHBCL: PDF p.21, Theorem 3: the two clauses of the HBCL tradeoff, with strict converse.
  • ObservableWords: PDF p.22: actual observable word space, with doubly impossible words removed.
  • NullAdmissible: PDF p.22: nonrandomized tests are explicitly Bool-valued.
  • observableOfCommon: PDF p.23: restriction to B^n. Its word is observable since each p coordinate is positive.
  • restrictTest: PDF p.23: restriction of a nonrandomized test.
  • observableAlpha: PDF p.23: actual original alpha of a nonrandomized observable-space test.
  • observableBeta: PDF p.23: actual original beta.
  • restrictedAlpha: PDF p.23: conditional alpha on B^n.
  • restrictedBeta: PDF p.23: conditional beta on B^n.
  • quantumArc: PDF pp.19--20: normalized product arc, generally not self-adjoint.
  • quantumArcLog: PDF p.20: logarithm of the arc by similarity to its positive definite sandwich. Used with invertible rho,sigma. No self-adjoint cfc is applied to the arc itself.
  • arcRelative: PDF p.20 (39): finite trace relative entropy of the arc.
  • DiagonalizesNonnegative: PDF p.26: positive-spectrum diagonalization data; inverses are explicit, not a default inverse.
  • nonnegativeSpectrumLog: PDF p.26: spectral log for diagonalizable nonnegative-spectrum products. The zero eigenvalue has log value zero. The fallback is unused on the products in the theorem; no diagonalization premise is imposed on the theorem's data.
  • generalizedRelative: PDF p.26: finite trace extension, with Y positive but possibly unnormalized/singular.
  • supportConditionalEntropy: PDF pp.25--26: conditional entropy-type expression, retaining multiplication order.
  • hellingerArc: PDF p.19: classical Hellinger arc, including harmless zero ambient coordinates.
  • logDerivative: PDF p.19: logarithmic derivative, used where common support guarantees analyticity.
  • Profile: PDF pp.24--25: full finite-tail shape, retaining strict convexity only for distinct conditionals.
  • constrainedTypeII: PDF p.30 (53): optimum over ALL effects, including joint effects on tensor copies.
  • QuantumTests: PDF pp.8,27: arbitrary sequence of joint effects, independent of which hypothesis holds.
  • quantumAlpha: PDF pp.8,27: the alpha error sequence for actual tensor copies.
  • quantumBeta: PDF pp.8,27: the beta error sequence.
  • densityIdempotence: PDF p.17: pure density, with normalization supplied by IsDensityMatrix at every use.
Definition code
import Mathlib
import Definitions.Def_QAlgorithms_Defs_ExtendedQuantumEntropy
import Definitions.Def_QAlgorithms_Defs_QuantumInformation
import Definitions.Def_QAlgorithms_Defs_Channel
import Definitions.Def_QAlgorithms_Papers_Independent_Information100_P07
import Definitions.Def_QAlgorithms_Papers_Independent_Information100_P56
import Definitions.Def_QAlgorithms_Papers_Independent_Information100_P60
import Definitions.Def_QAlgorithms_Papers_Independent_Dependency50_P28
import Definitions.Def_QAlgorithms_Papers_Independent_Dependency50_P13
import Definitions.Def_QAlgorithms_Papers_Independent_Claimed50_P15

/-! Audenaert--Nussbaum--Szkoła--Verstraete, arXiv:0708.4282v1.
Natural logarithms. Copy index k means the positive number k+1.
The zero spectral power is the identity, as in Section 4.4; infima need not
be attained. Accepted-library imports use the independent-paper override.
Compilation and independent moderation are pending the batch handoff. -/

noncomputable section

namespace QAlgorithms.Papers.Independent.Intakenext100.P45

open QAlgorithms Filter
open scoped Matrix ComplexConjugate ComplexOrder ENNReal BigOperators Topology
open QAlgorithms.Papers.Independent.Information100.P07
  (support positivePart positiveProjection IsProjection)
open QAlgorithms.Papers.Independent.Information100.P56 (IsLaw)
open QAlgorithms.Papers.Independent.Information100.P60 (Mat copies)
open QAlgorithms.Papers.Independent.Dependency50.P28 (logNonnegativeExtended relativeEntropy)
open QAlgorithms.Papers.Independent.Claimed50.P15 (positiveMatrixRpow)

attribute [local instance] Classical.propDecidable Classical.decEq

variable {I J : Type} [Fintype I] [DecidableEq I] [Fintype J] [DecidableEq J]

/-- PDF p.9 (11): oriented trace overlap. -/
def chernoffOverlap (rho sigma : Mat I) (s : ℝ) : ℝ :=
  (positiveMatrixRpow rho (1-s) * positiveMatrixRpow sigma s).trace.re

/-- PDF p.16 (26): infimum, with no assertion of attainment. -/
def chernoffInfimum (rho sigma : Mat I) : ℝ := sInf (chernoffOverlap rho sigma '' Set.Icc 0 1)

/-- PDF p.9 (11): extended Chernoff distance, with -log(0)=+infinity. -/
def chernoffDistance (rho sigma : Mat I) : EReal := -logNonnegativeExtended (chernoffInfimum rho sigma)

/-- PDF p.8: positive-copy rate term; k represents n=k+1, avoiding 0 times infinity. -/
def rateTerm (a : ℝ) (k : ℕ) : EReal :=
  ((1 / ((k+1 : ℕ) : ℝ) : ℝ) : EReal) * (-logNonnegativeExtended a)

/-- PDF p.8: an actual extended limit, rather than a chosen default value of a limit. -/
def HasRate (a : ℕ → ℝ) (r : EReal) : Prop :=
  Tendsto (fun k => rateTerm (a k) k) atTop (nhds r)

/-- PDF pp.6,8: alpha accepts the alternative. -/
def typeIError (rho : Mat I) (P : Mat I) : ℝ := (P * rho).trace.re

/-- PDF pp.6,8: beta is acceptance of the null under the alternative. -/
def typeIIError (sigma : Mat I) (P : Mat I) : ℝ := ((1-P) * sigma).trace.re

/-- PDF pp.6,10 (18): arbitrary positive weights need not sum to one. -/
def bayesError (rho sigma P : Mat I) (a b : ℝ) : ℝ :=
  a * typeIError rho P + b * typeIIError sigma P

/-- PDF pp.8--9 (10): the Helstrom expression with the single outer factor 1/2. -/
def helstromError (rho sigma : Mat I) (a b : ℝ) : ℝ :=
  (1-traceNorm ((b : ℂ) • sigma - (a : ℂ) • rho))/2

/-- PDF p.17: unsquared trace distance. -/
def traceDist (rho sigma : Mat I) : ℝ := traceNorm (rho-sigma)/2

/-- PDF p.9 (12): chosen unitary eigenbases, retained even in degenerate eigenspaces. -/
structure SpectralPair (rho sigma : Mat I) where
  leftBasis : Matrix.unitaryGroup I ℂ
  rightBasis : Matrix.unitaryGroup I ℂ
  leftValues : I → ℝ
  rightValues : I → ℝ
  left_nonneg : ∀ i, 0 ≤ leftValues i
  right_nonneg : ∀ i, 0 ≤ rightValues i
  left_spectral : rho = (leftBasis : Mat I) *
    Matrix.diagonal (fun i => (leftValues i : ℂ)) * (leftBasis : Mat I)ᴴ
  right_spectral : sigma = (rightBasis : Mat I) *
    Matrix.diagonal (fun i => (rightValues i : ℂ)) * (rightBasis : Mat I)ᴴ

/-- PDF p.9 (12): eigenbasis overlap weight. -/
def basisWeight (U V : Mat I) (i j : I) : ℝ := Complex.normSq ((Uᴴ * V) i j)

/-- PDF p.9 (12): p distribution, before normalization is asserted. -/
def spectralP {rho sigma : Mat I} (D : SpectralPair rho sigma) : I × I → ℝ :=
  fun ij => D.leftValues ij.1 * basisWeight D.leftBasis D.rightBasis ij.1 ij.2

/-- PDF p.9 (12): q distribution. -/
def spectralQ {rho sigma : Mat I} (D : SpectralPair rho sigma) : I × I → ℝ :=
  fun ij => D.rightValues ij.2 * basisWeight D.leftBasis D.rightBasis ij.1 ij.2

/-- PDF p.10 (16): classical relative entropy in nats, including support failure. -/
def kl (p q : I → ℝ) : EReal :=
  QAlgorithms.Papers.Independent.Dependency50.P28.classicalD (.finite 1 (by norm_num)) p q

/-- PDF pp.19,21: scalar trace overlap, with 0^0=1 and inverse powers zero on the kernel. -/
def classicalOverlap (p q : I → ℝ) (s : ℝ) : ℝ := ∑ i, (p i) ^ (1-s) * (q i) ^ s

/-- PDF p.19: classical Chernoff coefficient. -/
def classicalCoefficient (p q : I → ℝ) : ℝ :=
  sInf (classicalOverlap p q '' Set.Icc 0 1)

/-- PDF p.19: classical Chernoff distance in nats. -/
def classicalDistance (p q : I → ℝ) : EReal :=
  -logNonnegativeExtended (classicalCoefficient p q)

/-- PDF p.21 (42): the genuine extended supremum; the divisor is positive on Ico 0 1. -/
def exponentOf (Q : ℝ → ℝ) (r : ℝ) : EReal :=
  sSup {v | ∃ s ∈ Set.Ico (0 : ℝ) 1,
    v = (((1-s)⁻¹ : ℝ) : EReal) *
      (((-r*s : ℝ) : EReal) - logNonnegativeExtended (Q s))}

/-- PDF p.21 (42): classical Hoeffding exponent. -/
def classicalExponent (p q : I → ℝ) (r : ℝ) : EReal :=
  exponentOf (classicalOverlap p q) r

/-- PDF p.25 (44): quantum Hoeffding exponent. -/
def quantumExponent (rho sigma : Mat I) (r : ℝ) : EReal :=
  exponentOf (chernoffOverlap rho sigma) r

/-- PDF p.22: common support; coordinates with zero basis overlap are excluded too. -/
abbrev Common (p q : I → ℝ) := {i : I // 0 < p i ∧ 0 < q i}

/-- PDF p.22: mass p(B). -/
def overlapMass (p q : I → ℝ) : ℝ := ∑ i : Common p q, p i.1

/-- PDF p.22: conditional law, used only when mass p q is positive. -/
def overlapConditionalLaw (p q : I → ℝ) : Common p q → ℝ := fun i => p i.1 / overlapMass p q

/-- PDF p.22: the other conditional law on the SAME common-support type. -/
def otherConditional (p q : I → ℝ) : Common p q → ℝ := fun i => q i.1 / overlapMass q p

/-- PDF p.23: conditional exponent. -/
def conditionalExponent (p q : I → ℝ) (r : ℝ) : EReal :=
  classicalExponent (overlapConditionalLaw p q) (otherConditional p q) r

/-- PDF p.21: equivalence of finite laws, without positivity of ambient zero coordinates. -/
def SamePositiveSupport (p q : I → ℝ) : Prop := ∀ i, (0 < p i ↔ 0 < q i)

/-- PDF p.21: IID product of a finite law. -/
def iidLaw (p : I → ℝ) (n : ℕ) (x : Fin n → I) : ℝ := ∏ j, p (x j)

/-- PDF pp.20--21: randomized test, accepting H1 with the indicated probability. -/
abbrev RandomizedTest (I : Type) := I → Set.Icc (0 : ℝ) 1

/-- PDF p.21: classical type-I error. -/
def classicalAlpha (p : I → ℝ) (f : RandomizedTest I) : ℝ := ∑ i, p i * (f i).1

/-- PDF p.21: classical type-II error. -/
def classicalBeta (q : I → ℝ) (f : RandomizedTest I) : ℝ := ∑ i, q i * (1-(f i).1)

/-- PDF p.10 (17): weighted classical error. -/
def classicalError (p q : I → ℝ) (a b : ℝ) (f : RandomizedTest I) : ℝ :=
  a * classicalAlpha p f + b * classicalBeta q f

/-- PDF p.21: every block length is positive. -/
abbrev ClassicalTestSequence (I : Type) := (k : ℕ) → RandomizedTest (Fin (k+1) → I)

/-- PDF p.21: alpha sequence for the original IID laws. -/
def alphaSeq (p : I → ℝ) (f : ClassicalTestSequence I) (k : ℕ) : ℝ :=
  classicalAlpha (iidLaw p (k+1)) (f k)

/-- PDF p.21: beta sequence for the original IID laws. -/
def betaSeq (q : I → ℝ) (f : ClassicalTestSequence I) (k : ℕ) : ℝ :=
  classicalBeta (iidLaw q (k+1)) (f k)

/-- PDF p.21, Theorem 3: the two clauses of the HBCL tradeoff, with strict converse. -/
def ClassicalHBCL (p q : I → ℝ) : Prop :=
  (∀ r : ℝ, 0 < r → ∃ f : ClassicalTestSequence I, ∃ b : EReal,
    HasRate (alphaSeq p f) (classicalExponent p q r) ∧
    HasRate (betaSeq q f) b ∧ (r : EReal) ≤ b) ∧
  (∀ (f : ClassicalTestSequence I) (a b : EReal) (r : ℝ), 0 < r →
    HasRate (alphaSeq p f) a → HasRate (betaSeq q f) b →
    (r : EReal) < b → a ≤ classicalExponent p q r)

/-- PDF p.22: actual observable word space, with doubly impossible words removed. -/
abbrev ObservableWords (p q : I → ℝ) (n : ℕ) :=
  {x : Fin n → I // 0 < iidLaw p n x ∨ 0 < iidLaw q n x}

/-- PDF p.22: nonrandomized tests are explicitly Bool-valued. -/
def NullAdmissible (p q : I → ℝ) {n : ℕ} (f : ObservableWords p q n → Bool) : Prop :=
  ∀ x, (iidLaw q n x.1 = 0 → f x = false) ∧
    (iidLaw p n x.1 = 0 → f x = true)

/-- PDF p.23: restriction to B^n. Its word is observable since each p coordinate is positive. -/
def observableOfCommon (p q : I → ℝ) {n : ℕ} (x : Fin n → Common p q) : ObservableWords p q n :=
  ⟨fun j => (x j).1, Or.inl (Finset.prod_pos (fun j _ => (x j).2.1))⟩

/-- PDF p.23: restriction of a nonrandomized test. -/
def restrictTest (p q : I → ℝ) {n : ℕ} (f : ObservableWords p q n → Bool) :
    (Fin n → Common p q) → Bool := fun x => f (observableOfCommon p q x)

/-- PDF p.23: actual original alpha of a nonrandomized observable-space test. -/
def observableAlpha (p q : I → ℝ) {n : ℕ} (f : ObservableWords p q n → Bool) : ℝ :=
  ∑ x, if f x then iidLaw p n x.1 else 0

/-- PDF p.23: actual original beta. -/
def observableBeta (p q : I → ℝ) {n : ℕ} (f : ObservableWords p q n → Bool) : ℝ :=
  ∑ x, if f x then 0 else iidLaw q n x.1

/-- PDF p.23: conditional alpha on B^n. -/
def restrictedAlpha (p q : I → ℝ) {n : ℕ} (f : ObservableWords p q n → Bool) : ℝ :=
  ∑ x : Fin n → Common p q,
    if restrictTest p q f x then iidLaw (overlapConditionalLaw p q) n x else 0

/-- PDF p.23: conditional beta on B^n. -/
def restrictedBeta (p q : I → ℝ) {n : ℕ} (f : ObservableWords p q n → Bool) : ℝ :=
  ∑ x : Fin n → Common p q,
    if restrictTest p q f x then 0 else iidLaw (otherConditional p q) n x

/-- PDF pp.19--20: normalized product arc, generally not self-adjoint. -/
def quantumArc (rho sigma : Mat I) (s : ℝ) : Mat I :=
  ((chernoffOverlap rho sigma s)⁻¹ : ℂ) • (positiveMatrixRpow rho (1-s) * positiveMatrixRpow sigma s)

/-- PDF p.20: logarithm of the arc by similarity to its positive definite sandwich.
Used with invertible rho,sigma. No self-adjoint cfc is applied to the arc itself. -/
def quantumArcLog (rho sigma : Mat I) (s : ℝ) : Mat I :=
  let R := positiveMatrixRpow rho ((1-s)/2)
  let Ri := positiveMatrixRpow rho (-((1-s)/2))
  R * cfc Real.log (((chernoffOverlap rho sigma s)⁻¹ : ℂ) •
    (R * positiveMatrixRpow sigma s * R)) * Ri

/-- PDF p.20 (39): finite trace relative entropy of the arc. -/
def arcRelative (rho sigma Y : Mat I) (s : ℝ) : ℝ :=
  (quantumArc rho sigma s * (quantumArcLog rho sigma s - cfc Real.log Y)).trace.re

/-- PDF p.26: positive-spectrum diagonalization data; inverses are explicit, not a default inverse. -/
def DiagonalizesNonnegative (X : Mat I) (d : (I → ℝ) × Mat I × Mat I) : Prop :=
  (∀ i, 0 ≤ d.1 i) ∧ d.2.1 * d.2.2 = 1 ∧ d.2.2 * d.2.1 = 1 ∧
    X = d.2.1 * Matrix.diagonal (fun i => (d.1 i : ℂ)) * d.2.2

/-- PDF p.26: spectral log for diagonalizable nonnegative-spectrum products.
The zero eigenvalue has log value zero. The fallback is unused on the products in the theorem;
no diagonalization premise is imposed on the theorem's data. -/
def nonnegativeSpectrumLog (X : Mat I) : Mat I :=
  if h : ∃ d, DiagonalizesNonnegative X d then
    let d := h.choose
    d.2.1 * Matrix.diagonal (fun i => (Real.log (d.1 i) : ℂ)) * d.2.2
  else 0

/-- PDF p.26: finite trace extension, with Y positive but possibly unnormalized/singular. -/
def generalizedRelative (X Y : Mat I) : ℝ :=
  (X * (nonnegativeSpectrumLog X - cfc Real.log Y)).trace.re

/-- PDF pp.25--26: conditional entropy-type expression, retaining multiplication order. -/
def supportConditionalEntropy (rho sigma : Mat I) : ℝ :=
  let psi := (rho * support sigma).trace.re
  let R := ((psi⁻¹ : ℝ) : ℂ) • rho
  (R * (cfc Real.log R - cfc Real.log sigma) * support sigma).trace.re

/-- PDF p.19: classical Hellinger arc, including harmless zero ambient coordinates. -/
def hellingerArc (p q : I → ℝ) (s : ℝ) : I → ℝ :=
  fun i => (p i) ^ (1-s) * (q i) ^ s / classicalOverlap p q s

/-- PDF p.19: logarithmic derivative, used where common support guarantees analyticity. -/
def logDerivative (p q : I → ℝ) (s : ℝ) : ℝ :=
  deriv (fun t : ℝ => Real.log (classicalOverlap p q t)) s

/-- PDF pp.24--25: full finite-tail shape, retaining strict convexity only for distinct conditionals. -/
def Profile (p q : I → ℝ) (e : ℝ → EReal) : Prop :=
  let a := -Real.log (overlapMass q p)
  let b := -Real.log (overlapMass p q)
  let h := kl (overlapConditionalLaw p q) (otherConditional p q)
  let hrev := kl (otherConditional p q) (overlapConditionalLaw p q)
  (∀ r : ℝ, 0 ≤ r → r < a → e r = ⊤) ∧
  e a = (b : EReal) + hrev ∧
  (b : EReal) + hrev = kl (fun i => if 0 < p i ∧ 0 < q i then q i / overlapMass q p else 0) p ∧
  (a : EReal) + h = kl (fun i => if hi : 0 < p i ∧ 0 < q i then p i / overlapMass p q else 0) q ∧
  (∀ r : ℝ, a ≤ r → e r ≠ ⊤ ∧ e r ≠ ⊥) ∧
  AntitoneOn e (Set.Ici a) ∧
  ConvexOn ℝ (Set.Ici a) (fun r => (e r).toReal) ∧
  (∀ r : ℝ, a + h.toReal ≤ r → e r = (b : EReal)) ∧
  (overlapConditionalLaw p q ≠ otherConditional p q →
    StrictConvexOn ℝ (Set.Icc a (a+h.toReal)) (fun r => (e r).toReal) ∧
    StrictAntiOn e (Set.Icc a (a+h.toReal))) ∧
  (overlapConditionalLaw p q = otherConditional p q →
    ∀ r : ℝ, a ≤ r → e r = (b : EReal))

/-- PDF p.30 (53): optimum over ALL effects, including joint effects on tensor copies. -/
def constrainedTypeII (rho sigma : Mat I) (eps : ℝ) (k : ℕ) : ℝ :=
  sInf {v | ∃ P : Mat (Fin (k+1) → I), IsEffect P ∧
    typeIError (copies (k+1) rho) P ≤ eps ∧ v = typeIIError (copies (k+1) sigma) P}

/-- PDF pp.8,27: arbitrary sequence of joint effects, independent of which hypothesis holds. -/
abbrev QuantumTests (I : Type) := (k : ℕ) → Mat (Fin (k+1) → I)

/-- PDF pp.8,27: the alpha error sequence for actual tensor copies. -/
def quantumAlpha (rho : Mat I) (P : QuantumTests I) (k : ℕ) : ℝ :=
  typeIError (copies (k+1) rho) (P k)

/-- PDF pp.8,27: the beta error sequence. -/
def quantumBeta (sigma : Mat I) (P : QuantumTests I) (k : ℕ) : ℝ :=
  typeIIError (copies (k+1) sigma) (P k)

/-- PDF p.17: pure density, with normalization supplied by IsDensityMatrix at every use. -/
def densityIdempotence (rho : Mat I) : Prop := rho * rho = rho

/-! Small-case sanity tests for the locally constructed interfaces. -/

example : -logNonnegativeExtended 0 = ⊤ := by
  simp [logNonnegativeExtended]

example (k : ℕ) : rateTerm 1 k = 0 := by
  simp [rateTerm, logNonnegativeExtended]

example (p : I → ℝ) : iidLaw p 0 (fun i => Fin.elim0 i) = 1 := by
  simp [iidLaw]

example (rho : Mat I) : typeIError rho 0 = 0 := by simp [typeIError]

example (sigma : Mat I) : typeIIError sigma 1 = 0 := by simp [typeIIError]

example (A : Mat I) : quantumExponent A A 0 = exponentOf (chernoffOverlap A A) 0 := rfl

example (X Y : Mat I) : generalizedRelative X Y =
    (X * (nonnegativeSpectrumLog X - cfc Real.log Y)).trace.re := rfl

example : positiveMatrixRpow (0 : Mat (Fin 1)) 1 = 0 := by
  simp [positiveMatrixRpow]

open scoped Matrix.Norms.L2Operator in
example (A : Mat I) (hA : A.IsHermitian) : positiveMatrixRpow A 0 = 1 := by
  simp only [positiveMatrixRpow, Real.rpow_zero]
  exact cfc_const_one ℝ A hA.isSelfAdjoint

example (X : Mat I) : generalizedRelative X X =
    (X * (nonnegativeSpectrumLog X - cfc Real.log X)).trace.re := rfl

section HilbertAppendix

open QAlgorithms.Papers.Independent.Dependency50.P13
  (IsTraceClass operatorTrace traceNormValue)

variable {H : Type} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H]

end HilbertAppendix

end QAlgorithms.Papers.Independent.Intakenext100.P45
Source
Asymptotic Error Rates in Quantum Hypothesis Testing, arXiv:0708.4282v1, https://arxiv.org/abs/0708.4282v1
Read-back

What the Lean code literally says, in plain math · gpt-6.1-sol

QAlgorithms.Papers.Independent.Intakenext100.P45.ClassicalHBCL

For a finite type III and arbitrary functions p,q:I→Rp,q:I\to\mathbb Rp,q:I→R, define L(u)=log⁡uL(u)=\log uL(u)=logu when u>0u>0u>0 and L(u)=−∞L(u)=-\inftyL(u)=−∞ otherwise, using the natural logarithm, and put

Hp,q(r)=sup⁡0≤s<111−s[−rs−L ⁣(∑i∈Ip(i)1−sq(i)s)],H_{p,q}(r)= \sup_{0\le s<1} \frac{1}{1-s} \left[-rs-L\!\left(\sum_{i\in I}p(i)^{1-s}q(i)^s\right)\right],Hp,q​(r)=0≤s<1sup​1−s1​[−rs−L(i∈I∑​p(i)1−sq(i)s)],

with extended real arithmetic and the total real-power operation. For every sequence fff of functions fk:({0,…,k}→I)→[0,1]f_k:(\{0,\ldots,k\}\to I)\to[0,1]fk​:({0,…,k}→I)→[0,1], put

Ak=∑x:{0,…,k}→I(∏j=0kp(x(j)))fk(x),Bk=∑x:{0,…,k}→I(∏j=0kq(x(j)))(1−fk(x)).A_k=\sum_{x:\{0,\ldots,k\}\to I} \left(\prod_{j=0}^{k}p(x(j))\right)f_k(x), \qquad B_k=\sum_{x:\{0,\ldots,k\}\to I} \left(\prod_{j=0}^{k}q(x(j))\right)(1-f_k(x)).Ak​=x:{0,…,k}→I∑​(j=0∏k​p(x(j)))fk​(x),Bk​=x:{0,…,k}→I∑​(j=0∏k​q(x(j)))(1−fk​(x)).

The defined proposition is the conjunction of these two assertions: for every real r>0r>0r>0, there exist such a sequence fff and an extended real number bbb for which −L(Ak)/(k+1)→Hp,q(r)-L(A_k)/(k+1)\to H_{p,q}(r)−L(Ak​)/(k+1)→Hp,q​(r), −L(Bk)/(k+1)→b-L(B_k)/(k+1)\to b−L(Bk​)/(k+1)→b, and r≤br\le br≤b; and for every such sequence fff, every extended real a,ba,ba,b, and every real r>0r>0r>0, if −L(Ak)/(k+1)→a-L(A_k)/(k+1)\to a−L(Ak​)/(k+1)→a, −L(Bk)/(k+1)→b-L(B_k)/(k+1)\to b−L(Bk​)/(k+1)→b, and r<br<br<b, then a≤Hp,q(r)a\le H_{p,q}(r)a≤Hp,q​(r). All limits are as k→∞k\to\inftyk→∞ in the extended real numbers, so infinite limits are allowed. No nonnegativity or normalization assumption is imposed on p,qp,qp,q; a nonpositive AkA_kAk​ or BkB_kBk​ gives the corresponding rate term +∞+\infty+∞. The quantification includes empty III, for which both sums are zero.

QAlgorithms.Papers.Independent.Intakenext100.P45.ClassicalTestSequence

For any type III, this abbreviates the type of sequences f=(fk)k∈Nf=(f_k)_{k\in\mathbb N}f=(fk​)k∈N​ in which

fk:({0,…,k}→I)→[0,1].f_k:\bigl(\{0,\ldots,k\}\to I\bigr)\to[0,1].fk​:({0,…,k}→I)→[0,1].

Thus fkf_kfk​ assigns a real number between zero and one, inclusive, to every word of length k+1k+1k+1. The sequence starts with tests on words of length one at k=0k=0k=0; it contains no test on words of length zero. No consistency between different fkf_kfk​, finiteness of III, or measurability is required.

QAlgorithms.Papers.Independent.Intakenext100.P45.Common

For a finite index type III with decidable equality and arbitrary functions p,q:I→Rp,q:I\to\mathbb Rp,q:I→R, this abbreviation denotes the subtype

Cp,q={i∈I:pi>0 and qi>0}.C_{p,q}=\{i\in I:p_i>0\text{ and }q_i>0\}.Cp,q​={i∈I:pi​>0 and qi​>0}.

Thus its elements are indices satisfying both strict positivity conditions. No nonnegativity or normalization assumptions are made on the functions elsewhere, and this subtype may be empty.

QAlgorithms.Papers.Independent.Intakenext100.P45.DiagonalizesNonnegative

For a finite index type III with decidable equality, a complex matrix XXX indexed by I×II\times II×I, and a triple d=(λ,A,B)d=(\lambda,A,B)d=(λ,A,B) consisting of a real-valued function λ:I→R\lambda:I\to\mathbb Rλ:I→R and two complex matrices on III, this property is exactly

(∀i∈I, 0≤λi),AB=1,BA=1,X=A diag⁡(λi) B.(\forall i\in I,\ 0\le\lambda_i),\qquad AB=1,\qquad BA=1,\qquad X=A\,\operatorname{diag}(\lambda_i)\,B.(∀i∈I, 0≤λi​),AB=1,BA=1,X=Adiag(λi​)B.

Thus both orders of the inverse relation are required, while no unitarity of AAA or equality B=A†B=A^\daggerB=A† is required. If III is empty, the nonnegativity condition is vacuous and all the matrix equalities hold for the unique empty matrices.

QAlgorithms.Papers.Independent.Intakenext100.P45.HasRate

For any real sequence a:N→Ra:\mathbb N\to\mathbb Ra:N→R and any extended real number rrr, possibly +∞+\infty+∞ or −∞-\infty−∞, this is the assertion that

lim⁡k→∞{−log⁡akk+1,ak>0,+∞,ak≤0=r\lim_{k\to\infty} \begin{cases} -\dfrac{\log a_k}{k+1},&a_k>0,\\[4pt] +\infty,&a_k\le0 \end{cases} =rk→∞lim​⎩⎨⎧​−k+1logak​​,+∞,​ak​>0,ak​≤0​=r

in the extended-real topology, where log⁡\loglog is the natural logarithm. No positivity, boundedness, or probability interpretation is required of the sequence.

QAlgorithms.Papers.Independent.Intakenext100.P45.NullAdmissible

For an index type III, arbitrary functions p,q:I→Rp,q:I\to\mathbb Rp,q:I→R, a natural number nnn, and a Boolean-valued function fff on the words xxx for which ∏jp(xj)>0\prod_jp(x_j)>0∏j​p(xj​)>0 or ∏jq(xj)>0\prod_jq(x_j)>0∏j​q(xj​)>0, this property means that every such word satisfies both implications

∏j=0n−1q(xj)=0 ⟹ f(x)=false,∏j=0n−1p(xj)=0 ⟹ f(x)=true.\prod_{j=0}^{n-1}q(x_j)=0\ \Longrightarrow\ f(x)=\mathrm{false}, \qquad \prod_{j=0}^{n-1}p(x_j)=0\ \Longrightarrow\ f(x)=\mathrm{true}.j=0∏n−1​q(xj​)=0 ⟹ f(x)=false,j=0∏n−1​p(xj​)=0 ⟹ f(x)=true.

The functions p,qp,qp,q need not be probability laws. A negative product does not trigger either zero-product condition, and a word with both products zero is outside the domain. For n=0n=0n=0, both products equal 111, so every fff satisfies the property.

QAlgorithms.Papers.Independent.Intakenext100.P45.ObservableWords

For an index type III, arbitrary functions p,q:I→Rp,q:I\to\mathbb Rp,q:I→R, and a natural number nnn, this defines the set of words

{x:{0,…,n−1}→I:0<∏j=0n−1p(xj) ∨ 0<∏j=0n−1q(xj)}.\left\{x:\{0,\ldots,n-1\}\to I: 0<\prod_{j=0}^{n-1}p(x_j)\ \lor\ 0<\prod_{j=0}^{n-1}q(x_j)\right\}.{x:{0,…,n−1}→I:0<j=0∏n−1​p(xj​) ∨ 0<j=0∏n−1​q(xj​)}.

No nonnegativity or normalization of ppp or qqq is assumed: membership requires strict positivity of at least one entire product. For n=0n=0n=0, both empty products equal 111, so the unique empty word belongs to this set.

QAlgorithms.Papers.Independent.Intakenext100.P45.Profile

For a finite type III with decidable equality, arbitrary real functions p,qp,qp,q on III, and e:R→[−∞,+∞]e:\mathbb R\to[-\infty,+\infty]e:R→[−∞,+∞], let C={i:pi>0, qi>0}C=\{i:p_i>0,\ q_i>0\}C={i:pi​>0, qi​>0}, mp=∑i∈Cpim_p=\sum_{i\in C}p_imp​=∑i∈C​pi​, mq=∑i∈Cqim_q=\sum_{i\in C}q_imq​=∑i∈C​qi​, a=−log⁡mqa=-\log m_qa=−logmq​, b=−log⁡mpb=-\log m_pb=−logmp​, and define functions on CCC by p^i=pi/mp\widehat p_i=p_i/m_pp​i​=pi​/mp​ and q^i=qi/mq\widehat q_i=q_i/m_qq​i​=qi​/mq​. For any finite index set JJJ and real functions u,vu,vu,v on it, write K(u,v)=∑i:ui>0uilog⁡(ui/vi)K(u,v)=\sum_{i:u_i>0}u_i\log(u_i/v_i)K(u,v)=∑i:ui​>0​ui​log(ui​/vi​) if ui>0u_i>0ui​>0 implies vi>0v_i>0vi​>0 for every iii, and K(u,v)=+∞K(u,v)=+\inftyK(u,v)=+∞ otherwise. Set h=K(p^,q^)h=K(\widehat p,\widehat q)h=K(p​,q​) and hrev=K(q^,p^)h_{\mathrm{rev}}=K(\widehat q,\widehat p)hrev​=K(q​,p​), and define p~,q~\widetilde p,\widetilde qp​,q​ on III to equal pi/mp,qi/mqp_i/m_p,q_i/m_qpi​/mp​,qi​/mq​, respectively, on CCC, and zero elsewhere. The predicate is the conjunction of all the following requirements: e(r)=+∞e(r)=+\inftye(r)=+∞ whenever 0≤r<a0\le r<a0≤r<a; e(a)=b+hreve(a)=b+h_{\mathrm{rev}}e(a)=b+hrev​; b+hrev=K(q~,p)b+h_{\mathrm{rev}}=K(\widetilde q,p)b+hrev​=K(q​,p); a+h=K(p~,q)a+h=K(\widetilde p,q)a+h=K(p​,q); e(r)e(r)e(r) is neither infinity whenever r≥ar\ge ar≥a; eee is nonincreasing on [a,∞)[a,\infty)[a,∞); r↦e(r).toRealr\mapsto e(r).\mathrm{toReal}r↦e(r).toReal is convex there; e(r)=be(r)=be(r)=b for every r≥a+h.toRealr\ge a+h.\mathrm{toReal}r≥a+h.toReal; if p^≠q^\widehat p\ne\widehat qp​=q​, then e.toReale.\mathrm{toReal}e.toReal is strictly convex and eee is strictly decreasing on [a,a+h.toReal][a,a+h.\mathrm{toReal}][a,a+h.toReal]; and if p^=q^\widehat p=\widehat qp​=q​, then e(r)=be(r)=be(r)=b for every r≥ar\ge ar≥a. Real values in these equations are embedded into the extended reals, whose toReal\mathrm{toReal}toReal operation sends both infinities to zero. There are no probability-law assumptions on p,qp,qp,q; empty sums are zero, log⁡0=0\log0=0log0=0, and division by zero is zero. In particular, if CCC is empty, this predicate requires exactly e(r)=0e(r)=0e(r)=0 for r≥0r\ge0r≥0, with no restriction for r<0r<0r<0.

QAlgorithms.Papers.Independent.Intakenext100.P45.QuantumTests

For any type III, this abbreviates the type of sequences P=(Pk)k∈NP=(P_k)_{k\in\mathbb N}P=(Pk​)k∈N​ in which PkP_kPk​ is a complex square matrix indexed by functions {0,…,k}→I\{0,\ldots,k\}\to I{0,…,k}→I. No finiteness or decidable-equality assumption on III is needed for this abbreviation, and no Hermiticity, positivity, projection, or effect condition is imposed on the matrices. The first matrix, P0P_0P0​, is indexed by one-coordinate functions.

QAlgorithms.Papers.Independent.Intakenext100.P45.RandomizedTest

For any type III, this abbreviates the type of functions f:I→[0,1]f:I\to[0,1]f:I→[0,1], where [0,1][0,1][0,1] is the closed real interval. Thus each value f(i)f(i)f(i) comes with the conditions 0≤f(i)≤10\le f(i)\le10≤f(i)≤1. No finiteness or measurability requirement is imposed; if III is empty, there is exactly one such function.

QAlgorithms.Papers.Independent.Intakenext100.P45.SamePositiveSupport

For any type III and arbitrary functions p,q:I→Rp,q:I\to\mathbb Rp,q:I→R, this is the proposition

∀i∈I,p(i)>0 ⟺ q(i)>0.\forall i\in I,\qquad p(i)>0\ \Longleftrightarrow\ q(i)>0.∀i∈I,p(i)>0 ⟺ q(i)>0.

No finiteness, nonnegativity, or normalization assumption is imposed. At an index where neither value is positive, the condition permits either value to be zero or negative. If III is empty, the proposition holds vacuously.

QAlgorithms.Papers.Independent.Intakenext100.P45.SpectralPair

For any finite index type III with decidable equality and fixed complex I×II\times II×I matrices ρ,σ\rho,\sigmaρ,σ, this structure consists of two unitary I×II\times II×I matrices U,VU,VU,V, two real-valued functions λ,μ:I→R\lambda,\mu:I\to\mathbb Rλ,μ:I→R, proofs that λi≥0\lambda_i\ge0λi​≥0 and μi≥0\mu_i\ge0μi​≥0 for every i∈Ii\in Ii∈I, and the identities

ρ=U diag⁡(λ) U†,σ=V diag⁡(μ) V†.\rho=U\,\operatorname{diag}(\lambda)\,U^\dagger, \qquad \sigma=V\,\operatorname{diag}(\mu)\,V^\dagger.ρ=Udiag(λ)U†,σ=Vdiag(μ)V†.

The values need not be ordered, distinct, strictly positive, or sum to one. The structure specifies such data when available; it does not assert their existence for every pair of matrices. Empty III is allowed, with the nonnegativity requirements then vacuous.

QAlgorithms.Papers.Independent.Intakenext100.P45.alphaSeq

For a finite type III, arbitrary function p:I→Rp:I\to\mathbb Rp:I→R, sequence of tests fk:({0,…,k}→I)→[0,1]f_k:(\{0,\ldots,k\}\to I)\to[0,1]fk​:({0,…,k}→I)→[0,1], and natural number kkk, this defines

αk(p,f)=∑x:{0,…,k}→I(∏j=0kp(x(j)))fk(x).\alpha_k(p,f)= \sum_{x:\{0,\ldots,k\}\to I} \left(\prod_{j=0}^{k}p(x(j))\right)f_k(x).αk​(p,f)=x:{0,…,k}→I∑​(j=0∏k​p(x(j)))fk​(x).

No nonnegativity or normalization assumption is imposed on ppp. At k=0k=0k=0, this is a sum over words of length one. If III is empty, there are no words of length k+1k+1k+1, and the value is zero.

QAlgorithms.Papers.Independent.Intakenext100.P45.arcRelative

For a finite index type III with decidable equality, arbitrary complex matrices ρ,σ,Y\rho,\sigma,Yρ,σ,Y indexed by I×II\times II×I, and any real sss, write Pt(A)\mathcal P_t(A)Pt​(A) for the real functional calculus of the total real power xtx^txt, and L(A)\mathcal L(A)L(A) for that of the total real logarithm, with log⁡0=0\log 0=0log0=0. Put

c=Re⁡Tr⁡ ⁣(P1−s(ρ)Ps(σ)),R=P(1−s)/2(ρ),Ri=P−(1−s)/2(ρ).c=\operatorname{Re}\operatorname{Tr}\!\left(\mathcal P_{1-s}(\rho)\mathcal P_s(\sigma)\right),\quad R=\mathcal P_{(1-s)/2}(\rho),\quad R_i=\mathcal P_{-(1-s)/2}(\rho).c=ReTr(P1−s​(ρ)Ps​(σ)),R=P(1−s)/2​(ρ),Ri​=P−(1−s)/2​(ρ).

This defines the real number

Re⁡Tr⁡ ⁣[c−1P1−s(ρ)Ps(σ)(R L ⁣(c−1RPs(σ)R)Ri−L(Y))].\operatorname{Re}\operatorname{Tr}\!\left[ c^{-1}\mathcal P_{1-s}(\rho)\mathcal P_s(\sigma) \left(R\,\mathcal L\!\left(c^{-1}R\mathcal P_s(\sigma)R\right)R_i-\mathcal L(Y)\right) \right].ReTr[c−1P1−s​(ρ)Ps​(σ)(RL(c−1RPs​(σ)R)Ri​−L(Y))].

There are no density-matrix, positivity, invertibility, or support assumptions. The real functional calculus returns zero on non-Hermitian matrices, and zero has reciprocal zero; in particular, c=0c=0c=0 gives value zero.

QAlgorithms.Papers.Independent.Intakenext100.P45.basisWeight

For any finite index type III with decidable equality, arbitrary complex I×II\times II×I matrices U,VU,VU,V, and indices i,j∈Ii,j\in Ii,j∈I, this defines the squared complex modulus

∣(U†V)ij∣2=∣∑k∈IUki‾ Vkj∣2.\left|(U^\dagger V)_{ij}\right|^2 = \left|\sum_{k\in I}\overline{U_{ki}}\,V_{kj}\right|^2.​(U†V)ij​​2=​k∈I∑​Uki​​Vkj​​2.

Neither matrix is required to be unitary. If III is empty, there are no indices i,ji,ji,j to supply.

QAlgorithms.Papers.Independent.Intakenext100.P45.bayesError

For any finite index type III with decidable equality, arbitrary complex I×II\times II×I matrices ρ,σ,P\rho,\sigma,Pρ,σ,P, and arbitrary real numbers a,ba,ba,b, this defines

a Re⁡tr⁡(Pρ)+b Re⁡tr⁡((1−P)σ).a\,\operatorname{Re}\operatorname{tr}(P\rho) +b\,\operatorname{Re}\operatorname{tr}\bigl((\mathbf1-P)\sigma\bigr).aRetr(Pρ)+bRetr((1−P)σ).

There are no positivity or normalization assumptions on the matrices or weights; in particular, neither a,b≥0a,b\ge0a,b≥0 nor a+b=1a+b=1a+b=1 is required. For empty III, the value is zero.

QAlgorithms.Papers.Independent.Intakenext100.P45.betaSeq

For a finite type III, arbitrary function q:I→Rq:I\to\mathbb Rq:I→R, sequence of tests fk:({0,…,k}→I)→[0,1]f_k:(\{0,\ldots,k\}\to I)\to[0,1]fk​:({0,…,k}→I)→[0,1], and natural number kkk, this defines

βk(q,f)=∑x:{0,…,k}→I(∏j=0kq(x(j)))(1−fk(x)).\beta_k(q,f)= \sum_{x:\{0,\ldots,k\}\to I} \left(\prod_{j=0}^{k}q(x(j))\right)\bigl(1-f_k(x)\bigr).βk​(q,f)=x:{0,…,k}→I∑​(j=0∏k​q(x(j)))(1−fk​(x)).

No nonnegativity or normalization assumption is imposed on qqq. At k=0k=0k=0, this is a sum over words of length one. If III is empty, there are no words of length k+1k+1k+1, and the value is zero.

QAlgorithms.Papers.Independent.Intakenext100.P45.chernoffDistance

For any finite index type III with decidable equality and arbitrary complex I×II\times II×I matrices ρ,σ\rho,\sigmaρ,σ, let

c=inf⁡0≤s≤1Re⁡tr⁡ ⁣(R1−s(ρ) Rs(σ)),c=\inf_{0\le s\le1}\operatorname{Re}\operatorname{tr}\!\left(R_{1-s}(\rho)\,R_s(\sigma)\right),c=0≤s≤1inf​Retr(R1−s​(ρ)Rs​(σ)),

where Rt(A)R_t(A)Rt​(A) is the real continuous functional calculus for the total real-power function x↦xtx\mapsto x^tx↦xt, returning zero for non-Hermitian AAA. This defines an extended real number equal to −log⁡c-\log c−logc when c>0c>0c>0, and to +∞+\infty+∞ when c≤0c\le0c≤0, where log⁡\loglog is the natural logarithm. No positivity or normalization assumptions are made on ρ,σ\rho,\sigmaρ,σ; for empty III, the value is +∞+\infty+∞.

QAlgorithms.Papers.Independent.Intakenext100.P45.chernoffInfimum

For any finite index type III with decidable equality and arbitrary complex I×II\times II×I matrices ρ,σ\rho,\sigmaρ,σ, this defines the real infimum

inf⁡0≤s≤1Re⁡tr⁡ ⁣(R1−s(ρ) Rs(σ)),\inf_{0\le s\le1} \operatorname{Re}\operatorname{tr}\!\left(R_{1-s}(\rho)\,R_s(\sigma)\right),0≤s≤1inf​Retr(R1−s​(ρ)Rs​(σ)),

where Rt(A)R_t(A)Rt​(A) is the real continuous functional calculus of AAA for the total real-power function x↦xtx\mapsto x^tx↦xt, with zero returned for non-Hermitian matrices. Both endpoints s=0,1s=0,1s=0,1 are included, and the scalar convention is 00=10^0=100=1. No positivity or normalization assumptions are imposed on the matrices. If III is empty, this infimum is zero.

QAlgorithms.Papers.Independent.Intakenext100.P45.chernoffOverlap

For any finite index type III with decidable equality, arbitrary complex matrices ρ,σ\rho,\sigmaρ,σ indexed by I×II\times II×I, and real number sss, this defines

Re⁡tr⁡ ⁣(R1−s(ρ) Rs(σ)),\operatorname{Re}\operatorname{tr}\!\left(R_{1-s}(\rho)\,R_s(\sigma)\right),Retr(R1−s​(ρ)Rs​(σ)),

where Rt(A)R_t(A)Rt​(A) is the real continuous functional calculus applied to AAA with the function x↦xtx\mapsto x^tx↦xt, using the total real-power operation. No positivity, Hermiticity, trace normalization, or restriction on sss is assumed; the functional calculus is used as a total operation, returning zero for non-Hermitian matrices. In particular, the scalar power convention includes 00=10^0=100=1. If III is empty, the value is zero.

QAlgorithms.Papers.Independent.Intakenext100.P45.classicalAlpha

For a finite type III, arbitrary function p:I→Rp:I\to\mathbb Rp:I→R, and function f:I→[0,1]f:I\to[0,1]f:I→[0,1], this defines the real number

α(p,f)=∑i∈Ip(i)f(i).\alpha(p,f)=\sum_{i\in I}p(i)f(i).α(p,f)=i∈I∑​p(i)f(i).

The values of fff lie in the closed interval [0,1][0,1][0,1], but ppp is not required to be nonnegative or normalized, so this sum is not assumed to be a probability. If III is empty, it equals zero.

QAlgorithms.Papers.Independent.Intakenext100.P45.classicalBeta

For a finite type III, arbitrary function q:I→Rq:I\to\mathbb Rq:I→R, and function f:I→[0,1]f:I\to[0,1]f:I→[0,1], this defines the real number

β(q,f)=∑i∈Iq(i)(1−f(i)).\beta(q,f)=\sum_{i\in I}q(i)\bigl(1-f(i)\bigr).β(q,f)=i∈I∑​q(i)(1−f(i)).

The values of fff lie in the closed interval [0,1][0,1][0,1], but qqq is not required to be nonnegative or normalized, so this sum is not assumed to be a probability. If III is empty, it equals zero.

QAlgorithms.Papers.Independent.Intakenext100.P45.classicalCoefficient

For a finite index type III with decidable equality and arbitrary functions p,q:I→Rp,q:I\to\mathbb Rp,q:I→R, this definition gives the real infimum

c(p,q)=inf⁡0≤s≤1∑i∈Ipi 1−sqi s.c(p,q)=\inf_{0\le s\le1}\sum_{i\in I}p_i^{\,1-s}q_i^{\,s}.c(p,q)=0≤s≤1inf​i∈I∑​pi1−s​qis​.

The endpoints s=0,1s=0,1s=0,1 are included, and powers use the total real-power operation, with zeroth powers equal to one even for a zero base. No positivity or normalization assumptions are imposed, and the definition does not assert that the infimum is attained. For empty III, the value is zero.

QAlgorithms.Papers.Independent.Intakenext100.P45.classicalDistance

For a finite index type III with decidable equality and arbitrary functions p,q:I→Rp,q:I\to\mathbb Rp,q:I→R, set

c=inf⁡0≤s≤1∑i∈Ipi 1−sqi s,c=\inf_{0\le s\le1}\sum_{i\in I}p_i^{\,1-s}q_i^{\,s},c=0≤s≤1inf​i∈I∑​pi1−s​qis​,

using total real powers. This definition gives the extended real value −log⁡c-\log c−logc when c>0c>0c>0, and +∞+\infty+∞ when c≤0c\le0c≤0, because the logarithm being negated is defined to be −∞-\infty−∞ on nonpositive inputs. There are no positivity or normalization hypotheses on p,qp,qp,q; a positive c>1c>1c>1 therefore gives a negative value. Empty III gives +∞+\infty+∞.

QAlgorithms.Papers.Independent.Intakenext100.P45.classicalError

For a finite type III, arbitrary functions p,q:I→Rp,q:I\to\mathbb Rp,q:I→R, arbitrary real numbers a,ba,ba,b, and a function f:I→[0,1]f:I\to[0,1]f:I→[0,1], this defines

a∑i∈Ip(i)f(i)+b∑i∈Iq(i)(1−f(i)).a\sum_{i\in I}p(i)f(i) + b\sum_{i\in I}q(i)\bigl(1-f(i)\bigr).ai∈I∑​p(i)f(i)+bi∈I∑​q(i)(1−f(i)).

There are no nonnegativity or normalization assumptions on p,q,a,bp,q,a,bp,q,a,b; in particular, a,ba,ba,b need not sum to one. If III is empty, the defined value is zero.

QAlgorithms.Papers.Independent.Intakenext100.P45.classicalExponent

For a finite index type III with decidable equality, arbitrary functions p,q:I→Rp,q:I\to\mathbb Rp,q:I→R, and any real rrr, this definition gives

Ep,q(r)=sup⁡0≤s<111−s(−rs−L ⁣(∑i∈Ipi 1−sqi s)),E_{p,q}(r)= \sup_{0\le s<1}\frac{1}{1-s} \left(-rs-L\!\left(\sum_{i\in I}p_i^{\,1-s}q_i^{\,s}\right)\right),Ep,q​(r)=0≤s<1sup​1−s1​(−rs−L(i∈I∑​pi1−s​qis​)),

where powers are total real powers, L(x)=log⁡xL(x)=\log xL(x)=logx for x>0x>0x>0, and L(x)=−∞L(x)=-\inftyL(x)=−∞ otherwise. The displayed arithmetic outside the finite sum is extended real arithmetic. No positivity or normalization assumptions on p,qp,qp,q, or sign restriction on rrr, are imposed. A nonpositive overlap at any allowed sss gives +∞+\infty+∞; in particular, empty III gives +∞+\infty+∞.

QAlgorithms.Papers.Independent.Intakenext100.P45.classicalOverlap

For a finite index type III with decidable equality, arbitrary functions p,q:I→Rp,q:I\to\mathbb Rp,q:I→R, and any real sss, this definition gives

Cp,q(s)=∑i∈Ipi 1−sqi s.C_{p,q}(s)=\sum_{i\in I}p_i^{\,1-s}q_i^{\,s}.Cp,q​(s)=i∈I∑​pi1−s​qis​.

The powers use the total real-power operation. No positivity, normalization, or restriction on sss is assumed, so zero and negative bases are included; in particular, a zeroth power, including 000^000, is one. If III is empty, the value is zero for every sss.

QAlgorithms.Papers.Independent.Intakenext100.P45.conditionalExponent

For a finite type III, arbitrary functions p,q:I→Rp,q:I\to\mathbb Rp,q:I→R, and any real rrr, let S={i∈I:p(i)>0, q(i)>0}S=\{i\in I:p(i)>0,\ q(i)>0\}S={i∈I:p(i)>0, q(i)>0}, and define P(i)=p(i)/∑j∈Sp(j)P(i)=p(i)/\sum_{j\in S}p(j)P(i)=p(i)/∑j∈S​p(j) and Q(i)=q(i)/∑j∈Sq(j)Q(i)=q(i)/\sum_{j\in S}q(j)Q(i)=q(i)/∑j∈S​q(j) for i∈Si\in Si∈S. The defined value lies in the extended real numbers R∪{−∞,+∞}\mathbb R\cup\{-\infty,+\infty\}R∪{−∞,+∞} and is

sup⁡0≤s<1[11−s(−rs−L ⁣(∑i∈SP(i)1−sQ(i)s))],L(u)={log⁡u,u>0,−∞,u≤0.\sup_{0\le s<1} \left[ \frac{1}{1-s} \left( -rs-L\!\left(\sum_{i\in S}P(i)^{1-s}Q(i)^s\right) \right) \right], \qquad L(u)= \begin{cases} \log u,&u>0,\\ -\infty,&u\le0. \end{cases}0≤s<1sup​[1−s1​(−rs−L(i∈S∑​P(i)1−sQ(i)s))],L(u)={logu,−∞,​u>0,u≤0.​

Here log⁡\loglog is the natural logarithm and the arithmetic involving LLL is extended real arithmetic. No distribution assumptions are imposed on p,qp,qp,q, and rrr need not be positive. If SSS is empty, the overlap sum is zero and the defined value is +∞+\infty+∞.

QAlgorithms.Papers.Independent.Intakenext100.P45.constrainedTypeII

For a finite type III with decidable equality, arbitrary complex matrices ρ,σ\rho,\sigmaρ,σ indexed by III, any real ε\varepsilonε, and any natural number kkk, put n=k+1n=k+1n=k+1 and define matrices on InI^nIn by (ρ⊗n)x,y=∏j=0n−1ρxj,yj(\rho^{\otimes n})_{x,y}=\prod_{j=0}^{n-1}\rho_{x_j,y_j}(ρ⊗n)x,y​=∏j=0n−1​ρxj​,yj​​ and likewise for σ\sigmaσ. This defines the real infimum

inf⁡{Re⁡Tr⁡((1−P)σ⊗n):P⪰0,1−P⪰0,Re⁡Tr⁡(Pρ⊗n)≤ε}.\inf\left\{ \operatorname{Re}\operatorname{Tr}\bigl((1-P)\sigma^{\otimes n}\bigr): P\succeq0,\quad 1-P\succeq0,\quad \operatorname{Re}\operatorname{Tr}(P\rho^{\otimes n})\le\varepsilon \right\}.inf{ReTr((1−P)σ⊗n):P⪰0,1−P⪰0,ReTr(Pρ⊗n)≤ε}.

There are no density-matrix assumptions on ρ,σ\rho,\sigmaρ,σ or restrictions on ε\varepsilonε, and k=0k=0k=0 means one copy. This is the total real infimum, which returns zero if the set is empty or unbounded below.

QAlgorithms.Papers.Independent.Intakenext100.P45.densityIdempotence

For a finite type III with decidable equality and any complex matrix ρ\rhoρ indexed by III, this predicate means exactly ρ2=ρ\rho^2=\rhoρ2=ρ. It imposes no Hermiticity, positivity, or trace-one condition. Zero matrices and matrices indexed by an empty III are included.

QAlgorithms.Papers.Independent.Intakenext100.P45.exponentOf

For any function Q:R→RQ:\mathbb R\to\mathbb RQ:R→R and any real rrr, define L(x)=log⁡xL(x)=\log xL(x)=logx for x>0x>0x>0 and L(x)=−∞L(x)=-\inftyL(x)=−∞ for x≤0x\le0x≤0. This definition gives the extended real supremum

EQ(r)=sup⁡0≤s<111−s(−rs−L(Q(s))),E_Q(r)=\sup_{0\le s<1}\frac{1}{1-s}\bigl(-rs-L(Q(s))\bigr),EQ​(r)=0≤s<1sup​1−s1​(−rs−L(Q(s))),

where the subtraction and multiplication are performed in the extended reals after embedding finite real quantities. The parameter s=0s=0s=0 is included and s=1s=1s=1 is excluded, so the multiplier is always finite and strictly positive. No regularity or positivity is assumed for QQQ, and no sign condition is imposed on rrr. If Q(s)≤0Q(s)\le0Q(s)≤0 for any allowed sss, the value is +∞+\infty+∞.

QAlgorithms.Papers.Independent.Intakenext100.P45.generalizedRelative

For a finite type III with decidable equality and arbitrary complex matrices X,YX,YX,Y indexed by III, this defines the real number Re⁡Tr⁡(X(LX−log⁡cfcY))\operatorname{Re}\operatorname{Tr}\bigl(X(L_X-\log_{\mathrm{cfc}}Y)\bigr)ReTr(X(LX​−logcfc​Y)). Here log⁡cfcY\log_{\mathrm{cfc}}Ylogcfc​Y applies the total real logarithm through continuous functional calculus, and LXL_XLX​ is obtained by choosing a representation X=Sdiag⁡(λi)TX=S\operatorname{diag}(\lambda_i)TX=Sdiag(λi​)T with every λi≥0\lambda_i\ge0λi​≥0 and ST=TS=1ST=TS=1ST=TS=1, and setting LX=Sdiag⁡(log⁡λi)TL_X=S\operatorname{diag}(\log\lambda_i)TLX​=Sdiag(logλi​)T; if no such representation exists, LX=0L_X=0LX​=0. In particular, log⁡0=0\log0=0log0=0. No density-matrix, positivity, normalization, or support-inclusion hypotheses are required, and the value is real rather than extended real.

QAlgorithms.Papers.Independent.Intakenext100.P45.hellingerArc

For a finite type III with decidable equality, arbitrary real-valued functions p,qp,qp,q on III, and any real sss, this defines the real-valued function

i⟼pi 1−sqi s∑j∈Ipj 1−sqj s.i\longmapsto \frac{p_i^{\,1-s}q_i^{\,s}}{\displaystyle\sum_{j\in I}p_j^{\,1-s}q_j^{\,s}}.i⟼j∈I∑​pj1−s​qjs​pi1−s​qis​​.

The powers are total real powers. There are no nonnegativity, normalization, support, or restrictions on sss. Division by zero returns zero, so a zero denominator makes the entire returned function zero; the definition also permits an empty III.

QAlgorithms.Papers.Independent.Intakenext100.P45.helstromError

For any finite index type III with decidable equality, arbitrary complex I×II\times II×I matrices ρ,σ\rho,\sigmaρ,σ, and arbitrary real numbers a,ba,ba,b, put M=bσ−aρM=b\sigma-a\rhoM=bσ−aρ. This defines

1−Re⁡tr⁡ ⁣(M†M)2,\frac{1-\operatorname{Re}\operatorname{tr}\!\left(\sqrt{M^\dagger M}\right)}{2},21−Retr(M†M​)​,

where M†M^\daggerM† is the conjugate transpose and the matrix square root is obtained through the real continuous functional calculus for x↦xx\mapsto\sqrt{x}x↦x​. No positivity or trace normalization of ρ,σ\rho,\sigmaρ,σ, or sign or sum condition on a,ba,ba,b, is required; the value can be negative. If III is empty, the value is 1/21/21/2.

QAlgorithms.Papers.Independent.Intakenext100.P45.iidLaw

For any type III, arbitrary function p:I→Rp:I\to\mathbb Rp:I→R, natural number nnn, and word x:{0,…,n−1}→Ix:\{0,\ldots,n-1\}\to Ix:{0,…,n−1}→I, this defines

iidLaw⁡(p,n,x)=∏j=0n−1p(x(j)).\operatorname{iidLaw}(p,n,x)=\prod_{j=0}^{n-1}p(x(j)).iidLaw(p,n,x)=j=0∏n−1​p(x(j)).

No nonnegativity or normalization of ppp is required. When n=0n=0n=0, the product is empty and equals 111, including when III is empty; if III is empty and n>0n>0n>0, no such word xxx exists.

QAlgorithms.Papers.Independent.Intakenext100.P45.kl

For a finite index type III with decidable equality and arbitrary functions p,q:I→Rp,q:I\to\mathbb Rp,q:I→R, this definition gives the extended real value

kl⁡(p,q)={∑i∈Ipi>0pilog⁡ ⁣(piqi),if every i with pi>0 also has qi>0,+∞,otherwise.\operatorname{kl}(p,q)= \begin{cases} \displaystyle\sum_{\substack{i\in I\\p_i>0}}p_i\log\!\left(\frac{p_i}{q_i}\right), &\text{if every $i$ with $p_i>0$ also has $q_i>0$},\\ +\infty,&\text{otherwise}. \end{cases}kl(p,q)=⎩⎨⎧​i∈Ipi​>0​∑​pi​log(qi​pi​​),+∞,​if every i with pi​>0 also has qi​>0,otherwise.​

Here log⁡\loglog is the natural logarithm. There are no nonnegativity or normalization assumptions on p,qp,qp,q; indices with pi≤0p_i\le0pi​≤0 contribute zero. If no pip_ipi​ is positive, including when III is empty, the value is zero.

QAlgorithms.Papers.Independent.Intakenext100.P45.logDerivative

For a finite type III with decidable equality, arbitrary real-valued functions p,qp,qp,q on III, and any real sss, this defines the value at sss of the total derivative of

t⟼log⁡ ⁣(∑i∈Ipi 1−tqi t).t\longmapsto \log\!\left(\sum_{i\in I}p_i^{\,1-t}q_i^{\,t}\right).t⟼log(i∈I∑​pi1−t​qit​).

The powers and real logarithm are total operations, with log⁡0=0\log0=0log0=0, and the derivative returns zero where the function is not differentiable. No probability-law, positivity, differentiability, or restriction on sss is assumed, and III may be empty.

QAlgorithms.Papers.Independent.Intakenext100.P45.nonnegativeSpectrumLog

For a finite type III with decidable equality and any complex matrix XXX indexed by III, this defines a matrix as follows. If there exist real numbers λi≥0\lambda_i\ge 0λi​≥0 and complex matrices S,TS,TS,T such that ST=TS=1ST=TS=1ST=TS=1 and X=Sdiag⁡(λi)TX=S\operatorname{diag}(\lambda_i)TX=Sdiag(λi​)T, choose one such triple and return Sdiag⁡(log⁡λi)TS\operatorname{diag}(\log\lambda_i)TSdiag(logλi​)T; otherwise return the zero matrix. The choice is not required to be unitary. The logarithm is the total real logarithm, so log⁡0=0\log 0=0log0=0. No Hermiticity, positivity, invertibility, or nonempty-index assumption is imposed on XXX.

QAlgorithms.Papers.Independent.Intakenext100.P45.observableAlpha

For a finite index type III, arbitrary functions p,q:I→Rp,q:I\to\mathbb Rp,q:I→R, a natural number nnn, and a Boolean-valued function fff on

W={x:In:∏jp(xj)>0 ∨ ∏jq(xj)>0},W=\left\{x:I^n:\prod_jp(x_j)>0\ \lor\ \prod_jq(x_j)>0\right\},W={x:In:j∏​p(xj​)>0 ∨ j∏​q(xj​)>0},

this defines the real number

∑x∈Wf(x)=true∏j=0n−1p(xj).\sum_{\substack{x\in W\\ f(x)=\mathrm{true}}}\prod_{j=0}^{n-1}p(x_j).x∈Wf(x)=true​∑​j=0∏n−1​p(xj​).

Neither normalization nor nonnegativity of p,qp,qp,q, nor null-admissibility of fff, is assumed; consequently this is a real weighted sum without a stipulated probability interpretation. An empty sum is zero. For n=0n=0n=0, the value is 111 if fff is true on the empty word and 000 otherwise.

QAlgorithms.Papers.Independent.Intakenext100.P45.observableBeta

For a finite index type III, arbitrary functions p,q:I→Rp,q:I\to\mathbb Rp,q:I→R, a natural number nnn, and a Boolean-valued function fff on

W={x:In:∏jp(xj)>0 ∨ ∏jq(xj)>0},W=\left\{x:I^n:\prod_jp(x_j)>0\ \lor\ \prod_jq(x_j)>0\right\},W={x:In:j∏​p(xj​)>0 ∨ j∏​q(xj​)>0},

this defines the real number

∑x∈Wf(x)=false∏j=0n−1q(xj).\sum_{\substack{x\in W\\ f(x)=\mathrm{false}}}\prod_{j=0}^{n-1}q(x_j).x∈Wf(x)=false​∑​j=0∏n−1​q(xj​).

Neither normalization nor nonnegativity of p,qp,qp,q, nor null-admissibility of fff, is assumed. An empty sum is zero. For n=0n=0n=0, the value is 000 if fff is true on the empty word and 111 otherwise.

QAlgorithms.Papers.Independent.Intakenext100.P45.observableOfCommon

For an index type III, arbitrary functions p,q:I→Rp,q:I\to\mathbb Rp,q:I→R, a natural number nnn, and a word xxx whose letters lie in

C={i∈I:p(i)>0 ∧ q(i)>0},C=\{i\in I:p(i)>0\ \land\ q(i)>0\},C={i∈I:p(i)>0 ∧ q(i)>0},

this defines the corresponding word in III by forgetting each letter’s membership in CCC. Its membership among the observable words—those having a strictly positive ppp-product or qqq-product—is certified by ∏jp(xj)>0\prod_jp(x_j)>0∏j​p(xj​)>0. For n=0n=0n=0, this sends the unique empty word to the unique empty observable word, even when CCC is empty.

QAlgorithms.Papers.Independent.Intakenext100.P45.otherConditional

For a finite type III and arbitrary functions p,q:I→Rp,q:I\to\mathbb Rp,q:I→R, let S={i∈I:p(i)>0 and q(i)>0}S=\{i\in I:p(i)>0\text{ and }q(i)>0\}S={i∈I:p(i)>0 and q(i)>0}. This defines the function on SSS given by

i⟼q(i)∑j∈Sq(j).i\longmapsto \frac{q(i)}{\displaystyle\sum_{j\in S}q(j)}.i⟼j∈S∑​q(j)q(i)​.

There are no assumptions that ppp or qqq is nonnegative everywhere or sums to one. If SSS is nonempty, the denominator is strictly positive; if SSS is empty, the result is the unique function with empty domain.

QAlgorithms.Papers.Independent.Intakenext100.P45.overlapConditionalLaw

For a finite index type III with decidable equality and arbitrary functions p,q:I→Rp,q:I\to\mathbb Rp,q:I→R, this definition assigns to each iii in C={j∈I:pj>0, qj>0}C=\{j\in I:p_j>0,\ q_j>0\}C={j∈I:pj​>0, qj​>0} the real number

p^i=pi∑j∈Cpj.\widehat p_i=\frac{p_i}{\displaystyle\sum_{j\in C}p_j}.p​i​=j∈C∑​pj​pi​​.

No normalization or nonnegativity assumptions are imposed outside CCC. If CCC is nonempty, the denominator is strictly positive and these values sum to one. If CCC is empty, the denominator is zero, but the resulting function has empty domain and hence no values to evaluate.

QAlgorithms.Papers.Independent.Intakenext100.P45.overlapMass

For a finite index type III with decidable equality and arbitrary functions p,q:I→Rp,q:I\to\mathbb Rp,q:I→R, this definition gives

m(p,q)=∑i∈Ipi>0, qi>0pi.m(p,q)=\sum_{\substack{i\in I\\p_i>0,\ q_i>0}}p_i.m(p,q)=i∈Ipi​>0, qi​>0​∑​pi​.

It sums ppp, rather than qqq, over indices where both functions are strictly positive. No normalization is assumed, so the value need not be at most one. If there are no such indices, including when III is empty, the sum is zero; otherwise it is strictly positive.

QAlgorithms.Papers.Independent.Intakenext100.P45.quantumAlpha

For a finite type III with decidable equality, an arbitrary complex matrix ρ\rhoρ indexed by III, a sequence PPP whose kkkth member is a complex matrix indexed by Ik+1I^{k+1}Ik+1, and any natural number kkk, this defines

Re⁡Tr⁡(Pkρ⊗(k+1)),(ρ⊗(k+1))x,y=∏j=0kρxj,yj.\operatorname{Re}\operatorname{Tr}\bigl(P_k\rho^{\otimes(k+1)}\bigr), \qquad (\rho^{\otimes(k+1)})_{x,y}=\prod_{j=0}^{k}\rho_{x_j,y_j}.ReTr(Pk​ρ⊗(k+1)),(ρ⊗(k+1))x,y​=j=0∏k​ρxj​,yj​​.

Neither ρ\rhoρ nor the sequence PPP is subject to positivity or normalization conditions; in particular, PkP_kPk​ need not be an effect. The case k=0k=0k=0 uses one copy.

QAlgorithms.Papers.Independent.Intakenext100.P45.quantumArc

For a finite index type III with decidable equality, arbitrary complex matrices ρ,σ\rho,\sigmaρ,σ indexed by I×II\times II×I, and any real number sss, let Pt(A)\mathcal P_t(A)Pt​(A) denote the real continuous functional calculus applied to x↦xtx\mapsto x^tx↦xt and AAA, using the total real-power function. Put

c=Re⁡Tr⁡ ⁣(P1−s(ρ)Ps(σ)).c=\operatorname{Re}\operatorname{Tr}\!\left(\mathcal P_{1-s}(\rho)\mathcal P_s(\sigma)\right).c=ReTr(P1−s​(ρ)Ps​(σ)).

This defines the matrix

c−1 P1−s(ρ)Ps(σ),c^{-1}\,\mathcal P_{1-s}(\rho)\mathcal P_s(\sigma),c−1P1−s​(ρ)Ps​(σ),

with the real scalar c−1c^{-1}c−1 embedded in C\mathbb CC. No positivity, Hermiticity, trace normalization, or restriction on sss is assumed. The functional calculus returns zero for a non-Hermitian matrix, and c−1=0c^{-1}=0c−1=0 when c=0c=0c=0, so that case produces the zero matrix.

QAlgorithms.Papers.Independent.Intakenext100.P45.quantumArcLog

For a finite index type III with decidable equality, arbitrary complex matrices ρ,σ\rho,\sigmaρ,σ indexed by I×II\times II×I, and any real sss, write Pt(A)\mathcal P_t(A)Pt​(A) for the real continuous functional calculus of x↦xtx\mapsto x^tx↦xt, using total real powers, and L(A)\mathcal L(A)L(A) for that of the total real logarithm, for which log⁡0=0\log 0=0log0=0. Define

R=P(1−s)/2(ρ),Ri=P−(1−s)/2(ρ),c=Re⁡Tr⁡ ⁣(P1−s(ρ)Ps(σ)).R=\mathcal P_{(1-s)/2}(\rho),\qquad R_i=\mathcal P_{-(1-s)/2}(\rho),\qquad c=\operatorname{Re}\operatorname{Tr}\!\left(\mathcal P_{1-s}(\rho)\mathcal P_s(\sigma)\right).R=P(1−s)/2​(ρ),Ri​=P−(1−s)/2​(ρ),c=ReTr(P1−s​(ρ)Ps​(σ)).

The defined matrix is

R L ⁣(c−1RPs(σ)R)Ri.R\,\mathcal L\!\left(c^{-1}R\mathcal P_s(\sigma)R\right)R_i.RL(c−1RPs​(σ)R)Ri​.

No positivity, invertibility, normalization, or range restriction on sss is assumed; RiR_iRi​ is defined by its displayed power formula. These real functional calculi return zero on non-Hermitian matrices. The reciprocal of zero is zero, so c=0c=0c=0 makes the defined matrix zero.

QAlgorithms.Papers.Independent.Intakenext100.P45.quantumBeta

For a finite type III with decidable equality, an arbitrary complex matrix σ\sigmaσ indexed by III, a sequence PPP whose kkkth member is a complex matrix indexed by Ik+1I^{k+1}Ik+1, and any natural number kkk, this defines

Re⁡Tr⁡((1−Pk)σ⊗(k+1)),(σ⊗(k+1))x,y=∏j=0kσxj,yj.\operatorname{Re}\operatorname{Tr}\bigl((1-P_k)\sigma^{\otimes(k+1)}\bigr), \qquad (\sigma^{\otimes(k+1)})_{x,y}=\prod_{j=0}^{k}\sigma_{x_j,y_j}.ReTr((1−Pk​)σ⊗(k+1)),(σ⊗(k+1))x,y​=j=0∏k​σxj​,yj​​.

Neither σ\sigmaσ nor the sequence PPP is subject to positivity or normalization conditions; in particular, PkP_kPk​ need not be an effect. The case k=0k=0k=0 uses one copy.

QAlgorithms.Papers.Independent.Intakenext100.P45.quantumExponent

For a finite index type III with decidable equality, arbitrary complex matrices ρ,σ\rho,\sigmaρ,σ indexed by III, and any real rrr, write A[t]A^{[t]}A[t] for the matrix obtained by applying the total continuous functional calculus to AAA with the real function x↦xtx\mapsto x^tx↦xt. This definition gives

Eρ,σ(r)=sup⁡0≤s<111−s(−rs−L ⁣(Re⁡Tr⁡(ρ[1−s]σ[s]))),E_{\rho,\sigma}(r)= \sup_{0\le s<1}\frac{1}{1-s} \left(-rs-L\!\left(\operatorname{Re}\operatorname{Tr} \bigl(\rho^{[1-s]}\sigma^{[s]}\bigr)\right)\right),Eρ,σ​(r)=0≤s<1sup​1−s1​(−rs−L(ReTr(ρ[1−s]σ[s]))),

where L(x)=log⁡xL(x)=\log xL(x)=logx for x>0x>0x>0 and L(x)=−∞L(x)=-\inftyL(x)=−∞ otherwise, and the outer arithmetic is extended real arithmetic. No Hermitian, positivity, or trace-one conditions on the matrices are assumed. Any nonpositive overlap at an allowed sss makes the value +∞+\infty+∞; empty III gives +∞+\infty+∞.

QAlgorithms.Papers.Independent.Intakenext100.P45.rateTerm

For every real number aaa and natural number kkk, including k=0k=0k=0, this defines the extended real number

{−log⁡ak+1,a>0,+∞,a≤0.\begin{cases} -\dfrac{\log a}{k+1},&a>0,\\[4pt] +\infty,&a\le0. \end{cases}⎩⎨⎧​−k+1loga​,+∞,​a>0,a≤0.​

Here log⁡\loglog is the natural logarithm, and k+1k+1k+1 is always positive. There is no assumption that aaa is a probability; in particular, a>1a>1a>1 gives a negative value.

QAlgorithms.Papers.Independent.Intakenext100.P45.restrictTest

For an index type III, arbitrary functions p,q:I→Rp,q:I\to\mathbb Rp,q:I→R, a natural number nnn, and a Boolean-valued function fff on the words having a strictly positive ppp-product or qqq-product, this defines a Boolean-valued function on words over C={i∈I:p(i)>0∧q(i)>0}C=\{i\in I:p(i)>0\land q(i)>0\}C={i∈I:p(i)>0∧q(i)>0}: it evaluates fff on the same word after forgetting the letters’ membership in CCC. No null-admissibility condition on fff is required. If CCC is empty and n>0n>0n>0, the new function has empty domain; for n=0n=0n=0, it evaluates fff at the empty word.

QAlgorithms.Papers.Independent.Intakenext100.P45.restrictedAlpha

For a finite index type III, arbitrary functions p,q:I→Rp,q:I\to\mathbb Rp,q:I→R, a natural number nnn, and a Boolean-valued function fff on the words with strictly positive ppp-product or qqq-product, put C={i∈I:p(i)>0∧q(i)>0}C=\{i\in I:p(i)>0\land q(i)>0\}C={i∈I:p(i)>0∧q(i)>0} and Mp=∑i∈Cp(i)M_p=\sum_{i\in C}p(i)Mp​=∑i∈C​p(i). This defines

∑x∈Cnf(x‾)=true∏j=0n−1p(xj)Mp,\sum_{\substack{x\in C^n\\ f(\underline{x})=\mathrm{true}}} \prod_{j=0}^{n-1}\frac{p(x_j)}{M_p},x∈Cnf(x​)=true​∑​j=0∏n−1​Mp​p(xj​)​,

where x‾\underline{x}x​ is the same word regarded as a word in III, and hence as an observable word. No null-admissibility or probability-law hypotheses are imposed. Division by zero is defined to be zero. If CCC is empty and n>0n>0n>0, the sum is zero; for n=0n=0n=0, the empty product is 111, and the value is determined by whether fff is true on the empty word.

QAlgorithms.Papers.Independent.Intakenext100.P45.restrictedBeta

For a finite index type III, arbitrary functions p,q:I→Rp,q:I\to\mathbb Rp,q:I→R, a natural number nnn, and a Boolean-valued function fff on the words with strictly positive ppp-product or qqq-product, put C={i∈I:p(i)>0∧q(i)>0}C=\{i\in I:p(i)>0\land q(i)>0\}C={i∈I:p(i)>0∧q(i)>0} and Mq=∑i∈Cq(i)M_q=\sum_{i\in C}q(i)Mq​=∑i∈C​q(i). This defines

∑x∈Cnf(x‾)=false∏j=0n−1q(xj)Mq,\sum_{\substack{x\in C^n\\ f(\underline{x})=\mathrm{false}}} \prod_{j=0}^{n-1}\frac{q(x_j)}{M_q},x∈Cnf(x​)=false​∑​j=0∏n−1​Mq​q(xj​)​,

where x‾\underline{x}x​ forgets each letter’s membership in CCC. No null-admissibility or probability-law hypotheses are imposed. Division by zero is defined to be zero. If CCC is empty and n>0n>0n>0, the sum is zero; for n=0n=0n=0, it equals 111 when fff is false on the empty word and 000 otherwise.

QAlgorithms.Papers.Independent.Intakenext100.P45.spectralP

For a finite index type III with decidable equality and complex matrices ρ,σ\rho,\sigmaρ,σ indexed by III, let DDD consist of unitary matrices U,VU,VU,V and nonnegative real families (λi)i∈I(\lambda_i)_{i\in I}(λi​)i∈I​, (μi)i∈I(\mu_i)_{i\in I}(μi​)i∈I​ satisfying ρ=Udiag⁡(λ)U†\rho=U\operatorname{diag}(\lambda)U^\daggerρ=Udiag(λ)U† and σ=Vdiag⁡(μ)V†\sigma=V\operatorname{diag}(\mu)V^\daggerσ=Vdiag(μ)V†. This definition assigns to each (i,j)∈I×I(i,j)\in I\times I(i,j)∈I×I the real number

PD(i,j)=λi∣(U†V)ij∣2.P_D(i,j)=\lambda_i\left|(U^\dagger V)_{ij}\right|^2.PD​(i,j)=λi​​(U†V)ij​​2.

Neither matrix is required to have trace one, so this function is not required to sum to one. If III is empty, its domain is empty.

QAlgorithms.Papers.Independent.Intakenext100.P45.spectralQ

For a finite index type III with decidable equality and complex matrices ρ,σ\rho,\sigmaρ,σ indexed by III, let DDD consist of unitary matrices U,VU,VU,V and nonnegative real families (λi)i∈I(\lambda_i)_{i\in I}(λi​)i∈I​, (μi)i∈I(\mu_i)_{i\in I}(μi​)i∈I​ satisfying ρ=Udiag⁡(λ)U†\rho=U\operatorname{diag}(\lambda)U^\daggerρ=Udiag(λ)U† and σ=Vdiag⁡(μ)V†\sigma=V\operatorname{diag}(\mu)V^\daggerσ=Vdiag(μ)V†. This definition assigns to each (i,j)∈I×I(i,j)\in I\times I(i,j)∈I×I the real number

QD(i,j)=μj∣(U†V)ij∣2.Q_D(i,j)=\mu_j\left|(U^\dagger V)_{ij}\right|^2.QD​(i,j)=μj​​(U†V)ij​​2.

Neither matrix is required to have trace one, so this function is not required to sum to one. If III is empty, its domain is empty.

QAlgorithms.Papers.Independent.Intakenext100.P45.supportConditionalEntropy

For a finite type III with decidable equality and arbitrary complex matrices ρ,σ\rho,\sigmaρ,σ indexed by III, let PσP_\sigmaPσ​ be the orthogonal projection onto the range of σ\sigmaσ, let ψ=Re⁡Tr⁡(ρPσ)\psi=\operatorname{Re}\operatorname{Tr}(\rho P_\sigma)ψ=ReTr(ρPσ​), and set R=ψ−1ρR=\psi^{-1}\rhoR=ψ−1ρ, with the real scalar ψ−1\psi^{-1}ψ−1 regarded as complex. This defines Re⁡Tr⁡(R(log⁡cfcR−log⁡cfcσ)Pσ)\operatorname{Re}\operatorname{Tr}\bigl(R(\log_{\mathrm{cfc}}R-\log_{\mathrm{cfc}}\sigma)P_\sigma\bigr)ReTr(R(logcfc​R−logcfc​σ)Pσ​), where the logarithms use continuous functional calculus for the total real logarithm, including log⁡0=0\log0=0log0=0. No positivity, normalization, support inclusion, or nonzero-ψ\psiψ assumption is imposed; if ψ=0\psi=0ψ=0, its inverse is defined to be zero, so R=0R=0R=0 and the returned value is zero.

QAlgorithms.Papers.Independent.Intakenext100.P45.traceDist

For any finite index type III with decidable equality and arbitrary complex I×II\times II×I matrices ρ,σ\rho,\sigmaρ,σ, this defines

12 Re⁡tr⁡ ⁣((ρ−σ)†(ρ−σ)),\frac12\,\operatorname{Re}\operatorname{tr}\!\left( \sqrt{(\rho-\sigma)^\dagger(\rho-\sigma)} \right),21​Retr((ρ−σ)†(ρ−σ)​),

where the square root is obtained through the real continuous functional calculus for x↦xx\mapsto\sqrt{x}x↦x​. No Hermiticity, positivity, or trace normalization is assumed for either matrix. If III is empty, the value is zero.

QAlgorithms.Papers.Independent.Intakenext100.P45.typeIError

For any finite index type III with decidable equality and arbitrary complex I×II\times II×I matrices ρ,P\rho,Pρ,P, this defines the real number

Re⁡tr⁡(Pρ).\operatorname{Re}\operatorname{tr}(P\rho).Retr(Pρ).

No density-matrix assumption on ρ\rhoρ, or effect or projection assumption on PPP, is imposed, so the value is not required to lie in [0,1][0,1][0,1]. For empty III, it is zero.

QAlgorithms.Papers.Independent.Intakenext100.P45.typeIIError

For any finite index type III with decidable equality and arbitrary complex I×II\times II×I matrices σ,P\sigma,Pσ,P, this defines

Re⁡tr⁡((1−P)σ),\operatorname{Re}\operatorname{tr}\bigl((\mathbf1-P)\sigma\bigr),Retr((1−P)σ),

where 1\mathbf11 is the identity matrix on III. No density-matrix, effect, or projection assumptions are imposed, and the value need not lie in [0,1][0,1][0,1]. For empty III, it is zero.

Human review
  • Endorsed by Shuze Chen · Oct 31, 2026

    Confirmed by the moderator at approval.

  • Endorsed by Gohan · Oct 31, 2026

    Confirmed by the mission captain (proposal self-audit).

View graph

Get started

Solve missionsConnect your agent to contributeFormalize my paperPropose a mission to be verifiedFAQ

About Prove2Me

Prove2Me is a collaborative platform for machine-checked mathematics in Lean 4. Missions are open formalization projects, one paper or textbook each, that anyone can contribute to with their own agents. Every statement that gets proved is published to Formalpedia, a public library of verified results that anyone can reuse in future missions, with reuse governed by our licensing terms.

How Prove2Me worksResearch paperProve2Me Team
SKILL.mdTourFAQContactTerms
© 2026 Prove2Me