Offline · exact source
Exact Lean source

MixedChannelsPreparation

formalization/Cloning/MixedChannelsPreparation.lean

Source hash: 6c8e98d44315e8629964e9992b6b947635a9882e7eb780e9531eca38b1d6a068

Full source copied without mathematical changes from the snapshot whose input hash matches the passing audit. Select a line number for a stable source pointer.

The declarations belong to the compiled inventory covered by the project’s shared axiom audit. That audit records an aggregate union, without attributing axioms to individual declarations.

Declarations in this module
1import Cloning.MixedChannels
2import Cloning.HybridCovariantWeighted
3 
4/-! Concrete cross-type channels: append a normalized classical density, or
5forget the classical register by the actual operator-valued Bochner integral. -/
6 
7noncomputable section
8open scoped ComplexOrder InnerProductSpace Topology BigOperators
9open MeasureTheory Filter Cloning.InfiniteTraceClass
10namespace Cloning.Hybrid
11set_option backward.isDefEq.respectTransparency false
12 
13variable {Ω H : Type*} [MeasurableSpace Ω] {μ : Measure Ω}
14  [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H]
15 
16theorem prepareL1_blockPositive (g : Ω → ℝ) (hg : Integrable g μ)
17    (hg0 : ∀ y, 0 ≤ g y) {n : ℕ} (A : Fin n → Fin n → TraceClass H)
18    (hA : BlockPositive A) : L1BlockPositive (fun i j => prepareL1 g hg (A i j)) := by
19  have he : ∀ᵐ y ∂μ, ∀ i j : Fin n,
20      prepareL1 g hg (A i j) y = (g y : ℂ) • A i j :=
21    ae_all_iff.mpr fun i => ae_all_iff.mpr fun j => prepareL1_ae g hg (A i j)
22  filter_upwards [he] with y hy
23  intro v
24  simp only [hy]
25  change 0 ≤ ∑ i, ∑ j, ⟪v i, ((g y : ℂ) • (A i j).1) (v j)⟫_ℂ
26  simp only [ContinuousLinearMap.smul_apply, inner_smul_right, ← Finset.mul_sum]
27  exact mul_nonneg (by exact_mod_cast hg0 y) (hA v)
28 
29/-- Appending any actual probability density is a quantum-to-hybrid channel. -/
30def QuantumToHybrid.prepare (g : Ω → ℝ) (hg : Integrable g μ)
31    (hg0 : ∀ y, 0 ≤ g y) (hprob : ∫ y, g y ∂μ = 1) : QuantumToHybrid H H μ where
32  map := (prepareL1 g hg).mkContinuous 1 (fun A =>
33    le_of_eq ((norm_prepareL1 g hg hg0 hprob A).trans (one_mul ‖A‖).symm))
34  completelyPositive := fun _ A hA => prepareL1_blockPositive g hg hg0 A hA
35  tracePreserving := fun A => (integratedTrace_apply _).trans
36    (integral_trace_prepareL1 g hg hprob A)
37 
38@[simp] theorem QuantumToHybrid.prepare_apply (g : Ω → ℝ) (hg : Integrable g μ)
39    (hg0 : ∀ y, 0 ≤ g y) (hprob : ∫ y, g y ∂μ = 1) (A : TraceClass H) :
40    (QuantumToHybrid.prepare g hg hg0 hprob).map A = prepareL1 g hg A := rfl
41 
42theorem L1BlockPositive.integral {n : ℕ}
43    (A : Fin n → Fin n → Lp (TraceClass H) 1 μ) (hA : L1BlockPositive A) :
44    BlockPositive (fun i j => ∫ y, A i j y ∂μ) := by
45  intro v
46  have hi (i j : Fin n) : Integrable (fun y => ⟪v i, (A i j y).1 (v j)⟫_ℂ) μ :=
47    (traceClassMatrixCoefficient (v i) (v j)).integrable_comp (L1.integrable_coeFn (A i j))
48  have hs : Integrable (fun y => ∑ i : Fin n, ∑ j : Fin n,
49      ⟪v i, (A i j y).1 (v j)⟫_ℂ) μ :=
50    integrable_finset_sum _ (fun i _ => integrable_finset_sum _ (fun j _ => hi i j))
51  have he (i j : Fin n) : ⟪v i, (∫ y, A i j y ∂μ).1 (v j)⟫_ℂ =
52      ∫ y, ⟪v i, (A i j y).1 (v j)⟫_ℂ ∂μ :=
53    ((traceClassMatrixCoefficient (v i) (v j)).integral_comp_comm
54      (L1.integrable_coeFn (A i j))).symm
55  simp_rw [he]
56  have hp := integral_complex_nonneg_ae hs (hA.mono fun y hy => hy v)
57  rw [integral_finset_sum _ (fun i _ =>
58    integrable_finset_sum _ (fun j _ => hi i j))] at hp
59  simp_rw [integral_finset_sum _ (fun j _ => hi _ j)] at hp
60  exact hp
61 
62/-- Forgetting the classical register is CPTP for every reference measure. -/
63def HybridToQuantum.integrate : HybridToQuantum H H μ where
64  map := L1.integralCLM' ℂ
65  completelyPositive := fun n A hA => by
66    have h := L1BlockPositive.integral A hA
67    simpa only [← L1.integral_eq', L1.integral_eq_integral] using h
68  tracePreserving := fun _ => rfl
69 
70@[simp] theorem HybridToQuantum.integrate_apply (A : Lp (TraceClass H) 1 μ) :
71    HybridToQuantum.integrate.map A = ∫ y, A y ∂μ := by
72  change L1.integralCLM' ℂ A = _
73  rw [← L1.integral_eq', L1.integral_eq_integral]
74 
75theorem HybridToQuantum.integrate_norm_le (A : Lp (TraceClass H) 1 μ) :
76    ‖HybridToQuantum.integrate.map A‖ ≤ ‖A‖ := by
77  rw [integrate_apply, L1.norm_eq_integral_norm]
78  exact norm_integral_le_integral_norm _
79 
80theorem HybridToQuantum.integrate_prepare (g : Ω → ℝ) (hg : Integrable g μ)
81    (hg0 : ∀ y, 0 ≤ g y) (hprob : ∫ y, g y ∂μ = 1) (A : TraceClass H) :
82    HybridToQuantum.integrate.map ((QuantumToHybrid.prepare g hg hg0 hprob).map A) = A := by
83  rw [integrate_apply, QuantumToHybrid.prepare_apply]
84  calc
85    _ = ∫ y, (g y : ℂ) • A ∂μ := integral_congr_ae (prepareL1_ae g hg A)
86    _ = (∫ y, (g y : ℂ) ∂μ) • A := integral_smul_const _ _
87    _ = A := by
88      have he := Complex.ofRealCLM.integral_comp_comm hg
89      change (∫ y, (g y : ℂ) ∂μ) = ((∫ y, g y ∂μ : ℝ) : ℂ) at he
90      rw [he, hprob]
91      simp
92 
93end Cloning.Hybrid