QuantumComputinglib learn · inspect · formalize
Checked on this commit 4,524 public declarations commit ab8f277c5704 Build record

Lean source module

QuantumBlockEncoding/StatePreparationPaperRoutesCompact.lean

34 explicit public declarations in source order.

Back to Library Explorer

def · line 37

QuantumBlockEncoding.StatePreparationBenchmarks.mottonenConditionalAngles

Compiled Compiled

This definition gives the library's named construction or computation for “mottonen conditional angles”.

noncomputable def mottonenConditionalAngles : PrimitiveBasis 1 → ExactAngle :=
  StatePreparationPaperEntryCertificates.mottonenConditionalAngles

commit-pinned source · Verso Blueprint panel

def · line 40

QuantumBlockEncoding.StatePreparationBenchmarks.mottonenDenseUcryCircuit

Compiled Compiled

This definition gives the library's named construction or computation for “mottonen dense ucry circuit”.

noncomputable def mottonenDenseUcryCircuit : PrimitiveCircuit 2 :=
  StatePreparationPaperEntryCertificates.mottonenDenseUcryCircuit

commit-pinned source · Verso Blueprint panel

def · line 43

QuantumBlockEncoding.StatePreparationBenchmarks.mottonenDensePrimitiveCircuit

Compiled Compiled

This definition gives the library's named construction or computation for “mottonen dense primitive circuit”.

noncomputable def mottonenDensePrimitiveCircuit : PrimitiveCircuit 2 :=
  [PrimitiveGate.ry (1 : Fin 2) ryAngle513] ++ mottonenDenseUcryCircuit

commit-pinned source · Verso Blueprint panel

def · line 46

QuantumBlockEncoding.StatePreparationBenchmarks.mottonenRootState

Compiled Compiled

This definition gives the library's named construction or computation for “mottonen root state”.

noncomputable def mottonenRootState : StateVector (gridSize 2) ℂ :=
  (5 / 13 : ℂ) • basisKet (gridSize 2) (0 : Fin 4) +
    (12 / 13 : ℂ) • basisKet (gridSize 2) (2 : Fin 4)

commit-pinned source · Verso Blueprint panel

theorem · line 66

QuantumBlockEncoding.StatePreparationBenchmarks.mottonenRootRy_col_zero

Compiled Compiled

Lean checks the proposition indexed as “mottonen root ry col zero”; the hypotheses and conclusion in the code panel fix its exact scope.

theorem mottonenRootRy_col_zero :
    (evalPrimitiveCircuitLE [PrimitiveGate.ry (1 : Fin 2) ryAngle513]).col
        (0 : Fin 4) = mottonenRootState := by

commit-pinned source · Verso Blueprint panel

theorem · line 96

QuantumBlockEncoding.StatePreparationBenchmarks.mottonenRootRy_prepares

Compiled Compiled

Lean checks the proposition indexed as “mottonen root ry prepares”; the hypotheses and conclusion in the code panel fix its exact scope.

theorem mottonenRootRy_prepares :
    applyVec
        (evalPrimitiveCircuitLE [PrimitiveGate.ry (1 : Fin 2) ryAngle513])
        (zeroKet 2) = mottonenRootState := by

commit-pinned source · Verso Blueprint panel

theorem · line 180

QuantumBlockEncoding.StatePreparationBenchmarks.mottonenDenseUcry_on_root

Compiled Compiled

Lean checks the proposition indexed as “mottonen dense ucry on root”; the hypotheses and conclusion in the code panel fix its exact scope.

theorem mottonenDenseUcry_on_root :
    applyVec (evalPrimitiveCircuitLE mottonenDenseUcryCircuit) mottonenRootState =
      mottonenDenseState := by

commit-pinned source · Verso Blueprint panel

theorem · line 226

QuantumBlockEncoding.StatePreparationBenchmarks.mottonenDensePrimitive_prepares_target

Compiled Compiled

Lean checks the proposition indexed as “mottonen dense primitive prepares target”; the hypotheses and conclusion in the code panel fix its exact scope.

theorem mottonenDensePrimitive_prepares_target :
    applyVec (evalPrimitiveCircuitLE mottonenDensePrimitiveCircuit) (zeroKet 2) =
      mottonenDenseTarget.amplitudes := by

commit-pinned source · Verso Blueprint panel

def · line 241

QuantumBlockEncoding.StatePreparationBenchmarks.mottonenDensePrimitiveRoute

Compiled Compiled

This definition gives the library's named construction or computation for “mottonen dense primitive route”.

noncomputable def mottonenDensePrimitiveRoute :
    ExactPrimitiveStatePreparationRoute 2 where
  target := mottonenDenseTarget
  circuit := mottonenDensePrimitiveCircuit
  normalizationProof := mottonenDenseTarget_normalized
  preparationProof := mottonenDensePrimitive_prepares_target

commit-pinned source · Verso Blueprint panel

theorem · line 248

QuantumBlockEncoding.StatePreparationBenchmarks.mottonenDenseVerified_cost

Compiled Compiled

Lean checks the proposition indexed as “mottonen dense verified cost”; the hypotheses and conclusion in the code panel fix its exact scope.

theorem mottonenDenseVerified_cost :
    mottonenDensePrimitiveRoute.cost =
      { auxiliaryQubits := 0, gateCount := 5, depth := 4, oracleCalls := 0 } := by

commit-pinned source · Verso Blueprint panel

theorem · line 255

QuantumBlockEncoding.StatePreparationBenchmarks.zeroAngleCompiledUcry_eval_eq_one

Compiled Compiled

Lean checks the proposition indexed as “zero angle compiled ucry eval eq one”; the hypotheses and conclusion in the code panel fix its exact scope.

theorem zeroAngleCompiledUcry_eval_eq_one
    {qubits controls : Nat}
    (wires : Fin controls → Fin qubits) (target : Fin qubits)
    (distinct : ∀ control, wires control ≠ target) :
    evalPrimitiveCircuit
        (compileUniformlyControlledRy controls wires target distinct
          (fun _ => ryAngleZero)) = 1 := by

commit-pinned source · Verso Blueprint panel

def · line 287

QuantumBlockEncoding.StatePreparationBenchmarks.sparseControlWire

Compiled Compiled

This definition gives the library's named construction or computation for “sparse control wire”.

def sparseControlWire : Fin 1 → Fin 3 :=
  StatePreparationPaperEntryCertificates.sparseControlWire

commit-pinned source · Verso Blueprint panel

theorem · line 290

QuantumBlockEncoding.StatePreparationBenchmarks.sparseControlWire_ne_target

Compiled Compiled

Lean checks the proposition indexed as “sparse control wire ne target”; the hypotheses and conclusion in the code panel fix its exact scope.

theorem sparseControlWire_ne_target :
    ∀ control, sparseControlWire control ≠ (1 : Fin 3) := by

commit-pinned source · Verso Blueprint panel

def · line 295

QuantumBlockEncoding.StatePreparationBenchmarks.sparseConditionalAngles

Compiled Compiled

This definition gives the library's named construction or computation for “sparse conditional angles”.

noncomputable def sparseConditionalAngles : PrimitiveBasis 1 → ExactAngle :=
  StatePreparationPaperEntryCertificates.sparseConditionalAngles

commit-pinned source · Verso Blueprint panel

def · line 298

QuantumBlockEncoding.StatePreparationBenchmarks.sparsePrunedUcryCircuit

Compiled Compiled

This definition gives the library's named construction or computation for “sparse pruned ucry circuit”.

noncomputable def sparsePrunedUcryCircuit : PrimitiveCircuit 3 :=
  StatePreparationPaperEntryCertificates.sparsePrunedUcryCircuit

commit-pinned source · Verso Blueprint panel

def · line 301

QuantumBlockEncoding.StatePreparationBenchmarks.sparsePrunedCircuit

Compiled Compiled

This definition gives the library's named construction or computation for “sparse pruned circuit”.

noncomputable def sparsePrunedCircuit : PrimitiveCircuit 3 :=
  [PrimitiveGate.ry (2 : Fin 3) ryAngle513] ++ sparsePrunedUcryCircuit

commit-pinned source · Verso Blueprint panel

def · line 304

QuantumBlockEncoding.StatePreparationBenchmarks.sparseRootState

Compiled Compiled

This definition gives the library's named construction or computation for “sparse root state”.

noncomputable def sparseRootState : StateVector (gridSize 3) ℂ :=
  (5 / 13 : ℂ) • basisKet (gridSize 3) (0 : Fin 8) +
    (12 / 13 : ℂ) • basisKet (gridSize 3) (4 : Fin 8)

commit-pinned source · Verso Blueprint panel

theorem · line 325

QuantumBlockEncoding.StatePreparationBenchmarks.sparseRootRy_col_zero

Compiled Compiled

Lean checks the proposition indexed as “sparse root ry col zero”; the hypotheses and conclusion in the code panel fix its exact scope.

theorem sparseRootRy_col_zero :
    (evalPrimitiveCircuitLE [PrimitiveGate.ry (2 : Fin 3) ryAngle513]).col
        (0 : Fin 8) = sparseRootState := by

commit-pinned source · Verso Blueprint panel

theorem · line 371

QuantumBlockEncoding.StatePreparationBenchmarks.sparseRootRy_prepares

Compiled Compiled

Lean checks the proposition indexed as “sparse root ry prepares”; the hypotheses and conclusion in the code panel fix its exact scope.

theorem sparseRootRy_prepares :
    applyVec
        (evalPrimitiveCircuitLE [PrimitiveGate.ry (2 : Fin 3) ryAngle513])
        (zeroKet 3) = sparseRootState := by

commit-pinned source · Verso Blueprint panel

theorem · line 497

QuantumBlockEncoding.StatePreparationBenchmarks.sparsePrunedUcry_on_root

Compiled Compiled

Lean checks the proposition indexed as “sparse pruned ucry on root”; the hypotheses and conclusion in the code panel fix its exact scope.

theorem sparsePrunedUcry_on_root :
    applyVec (evalPrimitiveCircuitLE sparsePrunedUcryCircuit) sparseRootState = sparseThreeState := by

commit-pinned source · Verso Blueprint panel

theorem · line 577

QuantumBlockEncoding.StatePreparationBenchmarks.sparsePruned_prepares_target

Compiled Compiled

Lean checks the proposition indexed as “sparse pruned prepares target”; the hypotheses and conclusion in the code panel fix its exact scope.

theorem sparsePruned_prepares_target :
    applyVec (evalPrimitiveCircuitLE sparsePrunedCircuit) (zeroKet 3) =
      sparseThreeTarget.amplitudes := by

commit-pinned source · Verso Blueprint panel

def · line 592

QuantumBlockEncoding.StatePreparationBenchmarks.sparsePrunedRoute

Compiled Compiled

This definition gives the library's named construction or computation for “sparse pruned route”.

noncomputable def sparsePrunedRoute : ExactPrimitiveStatePreparationRoute 3 where
  target := sparseThreeTarget
  circuit := sparsePrunedCircuit
  normalizationProof := sparseThreeTarget_normalized
  preparationProof := sparsePruned_prepares_target

commit-pinned source · Verso Blueprint panel

def · line 598

QuantumBlockEncoding.StatePreparationBenchmarks.sparseDenseControlWires

Compiled Compiled

This definition gives the library's named construction or computation for “sparse dense control wires”.

def sparseDenseControlWires : Fin 2 → Fin 3
  | ⟨0, _⟩ => 1
  | _ => 2

commit-pinned source · Verso Blueprint panel

theorem · line 602

QuantumBlockEncoding.StatePreparationBenchmarks.sparseDenseControlWires_ne_target

Compiled Compiled

Lean checks the proposition indexed as “sparse dense control wires ne target”; the hypotheses and conclusion in the code panel fix its exact scope.

theorem sparseDenseControlWires_ne_target :
    ∀ control, sparseDenseControlWires control ≠ (0 : Fin 3) := by

commit-pinned source · Verso Blueprint panel

def · line 607

QuantumBlockEncoding.StatePreparationBenchmarks.sparseZeroFillCircuit

Compiled Compiled

This definition gives the library's named construction or computation for “sparse zero fill circuit”.

noncomputable def sparseZeroFillCircuit : PrimitiveCircuit 3 :=
  compileUniformlyControlledRy 2 sparseDenseControlWires (0 : Fin 3)
    sparseDenseControlWires_ne_target (fun _ => ryAngleZero)

commit-pinned source · Verso Blueprint panel

def · line 611

QuantumBlockEncoding.StatePreparationBenchmarks.sparseDenseTreeCircuit

Compiled Compiled

This definition gives the library's named construction or computation for “sparse dense tree circuit”.

noncomputable def sparseDenseTreeCircuit : PrimitiveCircuit 3 :=
  sparsePrunedCircuit ++ sparseZeroFillCircuit

commit-pinned source · Verso Blueprint panel

theorem · line 614

QuantumBlockEncoding.StatePreparationBenchmarks.sparseZeroFill_eval_eq_one

Compiled Compiled

Lean checks the proposition indexed as “sparse zero fill eval eq one”; the hypotheses and conclusion in the code panel fix its exact scope.

theorem sparseZeroFill_eval_eq_one :
    evalPrimitiveCircuit sparseZeroFillCircuit = 1 := by

commit-pinned source · Verso Blueprint panel

theorem · line 620

QuantumBlockEncoding.StatePreparationBenchmarks.sparseZeroFill_evalLE_eq_one

Compiled Compiled

Lean checks the proposition indexed as “sparse zero fill eval le eq one”; the hypotheses and conclusion in the code panel fix its exact scope.

theorem sparseZeroFill_evalLE_eq_one :
    evalPrimitiveCircuitLE sparseZeroFillCircuit = 1 := by

commit-pinned source · Verso Blueprint panel

theorem · line 626

QuantumBlockEncoding.StatePreparationBenchmarks.sparseDenseTree_evalLE_eq_pruned

Compiled Compiled

Lean checks the proposition indexed as “sparse dense tree eval le eq pruned”; the hypotheses and conclusion in the code panel fix its exact scope.

theorem sparseDenseTree_evalLE_eq_pruned :
    evalPrimitiveCircuitLE sparseDenseTreeCircuit =
      evalPrimitiveCircuitLE sparsePrunedCircuit := by

commit-pinned source · Verso Blueprint panel

theorem · line 633

QuantumBlockEncoding.StatePreparationBenchmarks.sparseDenseTree_prepares_target

Compiled Compiled

Lean checks the proposition indexed as “sparse dense tree prepares target”; the hypotheses and conclusion in the code panel fix its exact scope.

theorem sparseDenseTree_prepares_target :
    applyVec (evalPrimitiveCircuitLE sparseDenseTreeCircuit) (zeroKet 3) =
      sparseThreeTarget.amplitudes := by

commit-pinned source · Verso Blueprint panel

def · line 639

QuantumBlockEncoding.StatePreparationBenchmarks.sparseDenseTreeRoute

Compiled Compiled

This definition gives the library's named construction or computation for “sparse dense tree route”.

noncomputable def sparseDenseTreeRoute : ExactPrimitiveStatePreparationRoute 3 where
  target := sparseThreeTarget
  circuit := sparseDenseTreeCircuit
  normalizationProof := sparseThreeTarget_normalized
  preparationProof := sparseDenseTree_prepares_target

commit-pinned source · Verso Blueprint panel

theorem · line 645

QuantumBlockEncoding.StatePreparationBenchmarks.sparsePrunedVerified_cost

Compiled Compiled

Lean checks the proposition indexed as “sparse pruned verified cost”; the hypotheses and conclusion in the code panel fix its exact scope.

theorem sparsePrunedVerified_cost :
    sparsePrunedRoute.cost =
      { auxiliaryQubits := 0, gateCount := 5, depth := 4, oracleCalls := 0 } := by

commit-pinned source · Verso Blueprint panel

theorem · line 650

QuantumBlockEncoding.StatePreparationBenchmarks.sparseDenseTreeVerified_cost

Compiled Compiled

Lean checks the proposition indexed as “sparse dense tree verified cost”; the hypotheses and conclusion in the code panel fix its exact scope.

theorem sparseDenseTreeVerified_cost :
    sparseDenseTreeRoute.cost =
      { auxiliaryQubits := 0, gateCount := 15, depth := 13, oracleCalls := 0 } := by

commit-pinned source · Verso Blueprint panel

theorem · line 655

QuantumBlockEncoding.StatePreparationBenchmarks.sparsePruned_betterThan_denseTree

Compiled Compiled

Lean checks the proposition indexed as “sparse pruned better than dense tree”; the hypotheses and conclusion in the code panel fix its exact scope.

theorem sparsePruned_betterThan_denseTree :
    sparsePrunedRoute.cost.betterThan sparseDenseTreeRoute.cost := by

commit-pinned source · Verso Blueprint panel