All proofs
Project-declaredLean 4.28.0 Β· mathlib@8f9d9cff6bd7

Dual kron

MatrixMap.dual_kron

Plain-language statement

The dual of a Kronecker product of maps is the Kronecker product of their duals.

Exact Lean statement

lemma dual_kron {A B C D : Type*} [Fintype A] [Fintype B] [Fintype C] [Fintype D]
    [DecidableEq A] [DecidableEq B] [DecidableEq C] [DecidableEq D]
    (M : MatrixMap A B π•œ) (N : MatrixMap C D π•œ) :
    (M βŠ—β‚–β‚˜ N).dual = M.dual βŠ—β‚–β‚˜ N.dual

Formal artifact

Lean source

Canonical source
Full Lean sourceLean 4
lemma dual_kron {A B C D : Type*} [Fintype A] [Fintype B] [Fintype C] [Fintype D]    [DecidableEq A] [DecidableEq B] [DecidableEq C] [DecidableEq D]    (M : MatrixMap A B π•œ) (N : MatrixMap C D π•œ) :    (M βŠ—β‚–β‚˜ N).dual = M.dual βŠ—β‚–β‚˜ N.dual := by  have h_trace : βˆ€ (X : Matrix (A Γ— C) (A Γ— C) π•œ) (Y : Matrix (B Γ— D) (B Γ— D) π•œ), ( (M βŠ—β‚–β‚˜ N) X * Y ).trace = ( X * (M.dual βŠ—β‚–β‚˜ N.dual) Y ).trace := by    -- By definition of dual, we know that $(M x1 * y1).trace = (x1 * M.dual y1).trace$ and $(N x2 * y2).trace = (x2 * N.dual y2).trace$.    have h_dual : βˆ€ (x1 : Matrix A A π•œ) (y1 : Matrix B B π•œ), (M x1 * y1).trace = (x1 * M.dual y1).trace := by      intro x1 y1      convert MatrixMap.Dual.trace_eq M x1 y1 using 1    have h_dual_N : βˆ€ (x2 : Matrix C C π•œ) (y2 : Matrix D D π•œ), (N x2 * y2).trace = (x2 * N.dual y2).trace := by      exact fun x2 y2 => MatrixMap.Dual.trace_eq N x2 y2;    intro X Y;    -- By definition of Kronecker product, we can write X and Y as sums of Kronecker products.    obtain ⟨X_sum, hX_sum⟩ : βˆƒ X_sum : Finset (Matrix A A π•œ Γ— Matrix C C π•œ), X = βˆ‘ p ∈ X_sum, (Matrix.kroneckerMap (fun a b => a * b) p.1 p.2) := by      refine' ⟨ Finset.univ.image fun p : A Γ— A Γ— C Γ— C => ( Matrix.of fun i j => if i = p.1 ∧ j = p.2.1 then X ( p.1, p.2.2.1 ) ( p.2.1, p.2.2.2 ) else 0, Matrix.of fun i j => if i = p.2.2.1 ∧ j = p.2.2.2 then 1 else 0 ), _ ⟩;      ext ⟨a, c⟩ ⟨a', c'⟩;      rw [ Finset.sum_apply, Finset.sum_apply ];      rw [ Finset.sum_eq_single ( ( Matrix.of fun i j => if i = a ∧ j = a' then X ( a, c ) ( a', c' ) else 0, Matrix.of fun i j => if i = c ∧ j = c' then 1 else 0 ) ) ] <;> simp;      Β· intro a_1 b x x_1 x_2 x_3 a_2 a_3 a_4        subst a_3 a_2        contrapose! a_4; aesop;      Β· exact fun h => False.elim ( h a a' c c' ( by ext i j; aesop ) ( by ext i j; aesop ) )    obtain ⟨Y_sum, hY_sum⟩ : βˆƒ Y_sum : Finset (Matrix B B π•œ Γ— Matrix D D π•œ), Y = βˆ‘ p ∈ Y_sum, (Matrix.kroneckerMap (fun a b => a * b) p.1 p.2) := by      use Finset.image (fun p => (Matrix.of (fun i j => Y (i, p.1) (j, p.2)), Matrix.of (fun i j => if i = p.1 ∧ j = p.2 then 1 else 0))) (Finset.univ : Finset (D Γ— D));      ext ⟨i, j⟩ ⟨k, l⟩; simp [ Matrix.kroneckerMap ] ;      rw [ Finset.sum_image ] <;> simp [ Matrix.sum_apply ];      Β· rw [ Finset.sum_eq_single ( j, l ) ] <;> aesop;      Β· intro p q h        subst hX_sum        simp_all only [Prod.mk.injEq, EmbeddingLike.apply_eq_iff_eq]        obtain ⟨fst, snd⟩ := p        obtain ⟨fst_1, snd_1⟩ := q        obtain ⟨left, right⟩ := h        simp_all only [Prod.mk.injEq]        apply And.intro        Β· have := congr_fun ( congr_fun right fst ) snd; aesop;        Β· replace right := congr_fun ( congr_fun right fst ) snd; aesop;    -- By linearity of the trace and the properties of the Kronecker product, we can expand both sides of the equation.    have h_expand : βˆ€ (x1 y1 : Matrix A A π•œ) (x2 y2 : Matrix C C π•œ) (x3 y3 : Matrix B B π•œ) (x4 y4 : Matrix D D π•œ), ( (M βŠ—β‚–β‚˜ N) (Matrix.kroneckerMap (fun a b => a * b) x1 x2) * Matrix.kroneckerMap (fun a b => a * b) x3 x4 ).trace = ( Matrix.kroneckerMap (fun a b => a * b) x1 x2 * (M.dual βŠ—β‚–β‚˜ N.dual) (Matrix.kroneckerMap (fun a b => a * b) x3 x4) ).trace := by      intro x1 y1 x2 y2 x3 y3 x4 y4      simp [MatrixMap.kron_map_of_kron_state]      convert congr_argβ‚‚ ( Β· * Β· ) ( h_dual x1 x3 ) ( h_dual_N x2 x4 ) using 1 <;> simp [ Matrix.trace, Matrix.mul_apply, Matrix.kroneckerMap_apply ]      Β· simp only [Finset.sum_sigma', Finset.sum_mul _ _ _, Finset.mul_sum];        refine' Finset.sum_bij ( fun x _ => ⟨ ⟨ x.fst.1, x.snd.1 ⟩, ⟨ x.fst.2, x.snd.2 ⟩ ⟩ ) _ _ _ _ <;> simp [ mul_assoc, mul_comm, mul_left_comm ];        Β· bound;        Β· exact fun b => ⟨ _, _, _, _, rfl ⟩;      Β· simp only [mul_assoc, Finset.mul_sum _ _ _, Finset.sum_mul];        simp only [← Finset.sum_product', mul_left_comm];        refine' Finset.sum_bij ( fun x _ => ( x.1.2, x.2.2, x.1.1, x.2.1 ) ) _ _ _ _ <;> simp;    simp_all [ Matrix.trace_sum, Finset.sum_mul _ _ _ ];    simp [Matrix.mul_sum, h_expand]  apply dual_unique; assumption;
Project
quantumInfo
License
MIT
Commit
56e83a9288a3
Source
QuantumInfo/Finite/CPTPMap/Dual.lean:155-206

Reuse this declaration

Bring the exact result into your workflow

The import identifies the source module. Your project still needs the pinned package dependency shown on this page.

What this badge means

This completion status comes from the project or community source. It has not yet been represented here as an independent rebuild and axiom audit.

Continue in this project

Related declarations

Project-declaredLean 4.28.0

Conj Transpose isometry mul isometry le one

conjTranspose_isometry_mul_isometry_le_one

Project documentation

The operator norm of the conjugate transpose is equal to the operator norm. -/ theorem Matrix.opNorm_conjTranspose_eq_opNorm {m n : Type*} [Fintype m] [Fintype n] [DecidableEq m] [DecidableEq n] (A : Matrix m n π•œ) : Matrix.opNorm Aα΄΄ = Matrix.opNorm A := by unfold Matrix.opNorm rw [← ContinuousLinearMap.adjoint.norm_map (toEuclideanLin A).toContinuousLine...

quantum informationentropyquantum channels

Source project: quantumInfo

Person-level attribution pending.

View proof record
Project-declaredLean 4.28.0

Convex roof of pure

convex_roof_of_pure

Plain-language statement

The convex roof extension of g : KetUpToPhase d β†’ ℝβ‰₯0 applied to a pure state ψ is g (KetUpToPhase.mk ψ).

quantum informationentropyquantum channels

Source project: quantumInfo

Person-level attribution pending.

View proof record
Project-declaredLean 4.28.0

Id achieves Rate log dim

CPTPMap.id_achievesRate_log_dim

Plain-language statement

The identity channel on D dimensional space achieves a rate of log2(D).

quantum informationentropyquantum channels

Source project: quantumInfo

Person-level attribution pending.

View proof record