support
defimported Lean
The support $\mathrm{supp}(p) \subseteq \mathrm{Fin}\,n$ consists of coordinates where $p(i) \neq I$; the weight is $\mathrm{wt}(p) = |\mathrm{supp}(p)|$.
Statement
set_option linter.mathlibStandardSet false in open scoped BigOperators in open scoped Real in open scoped Nat in open scoped Classical in open scoped Pointwise in set_option maxRecDepth 4000 in set_option synthInstance.maxHeartbeats 20000 in set_option synthInstance.maxSize 128 in set_option relaxedAutoImplicit false in set_option autoImplicit false in open Complex Matrix in noncomputable def support {n : ℕ} (p : PauliString n) : Finset (Fin n)
- Defined in
- TCSlib, `support`
- Lean proof
- By Allan Li, Hydroxyi (from the file's git history), from github.com/Shilun-Allan-Li/tcslib at
c8a02591b1e5(Apache-2.0). Compiled here against leanprover/lean4:v4.33.1, Mathlib v4.33.1; written for leanprover/lean4:v4.25.0.support← support (TCSlib/ErrorCorrectingCodes/QuantumHamming.lean:88): verbatim
- Verified
- 07 Oct 2026
- Axioms
- none listed
- Built on 2
- PauliStringA Pauli string of length $n$ is a function $p : \mathrm{Fin}\,n \to \mathrm{PauliBasis}$.
- PauliBasisThe four Pauli basis elements $\{I,X,Y,Z\}$, represented as an inductive type.
- Used by 19
- k4_claw_diamond_free_has_no_induced_k4_subdivisionEvery simple graph containing neither an induced K4, an induced claw, nor an induced diamond contains no induced subdivision of K4.
- expected_utility_dus_le_opt_dusFor any Pandora's problem instance with deadlines
instand any valid policyπ,expectedUtilityDUS inst π ≤ optDUS inst. - prm_ghw_dimension_reduction_leLet K be a finite field of order q, let e, m ≥ 1, 0 ≤ t ≤ m - 1, and h = m - t. For every 1 ≤ r ≤ k_e(h), the r-th generalized Hamming…
- support_mkWithSupportSupport of a Pauli string built from prescribed data. Fix $n$, a finset $S \subseteq \mathrm{Fin}\,n$, and an assignment…
- residual_matching_num_single_edge_exchange_iff_criticalLet G be a finite simple graph on a finite vertex type V, M a maximum matching of G, u an M-free vertex, and vw an edge of M such that uv…
- condorcet_failure_iff_acyclic_half_coverFix a positive number n of voters. There exists a finite election with these n voters in which every candidate set of size at most three…
- tree_edge_disjoint_embedding_of_star_TFor n ≥ 2, if T is a spanning star tree on Fin n with center r, then every tree S on Fin (n - 1) can be embedded into Fin n…
- pauliStringsExactSupportThe finset of all Pauli strings on $n$ qubits whose support equals exactly the given finset $S$.
- graph_11_not_is_mutual_visibility_colorable_twoThe simple graph G_11 is not mutual-visibility 2-colorable.
- perm_order_eq_prod_and_sum_prime_power_parts_leLet k ≥ 1. If q is the order of some permutation of k elements and S(q) is the set of maximal prime-power divisors of q, then q =…
- opt_dtd_le_opt_dusFor every Pandora's problem instance with deadlines
inst : PandoraDeadlineInstance, the optimal expected utility under… - le_of_not_set_coloring_ramsey_property_p3If there exists an (a, b)-set-coloring of the complete graph K_N without a monochromatic two-edge path P_3 in any single color, then b *…
- op184_partially_adaptive_half_approximationFor every Pandora's problem instance with deadlines
inst : PandoraDeadlineInstance, there exists a valid partially adaptive policy… - pandora_threshold_policy_lower_boundLemma 3: for reservation values r, t >= 0 and a duplicate-free list of boxes each with positive capped surplus at t, the threshold policy…
- weightThe support $\mathrm{supp}(p) \subseteq \mathrm{Fin}\,n$ consists of coordinates where $p(i) \neq I$; the weight is…
- pandora_adaptive_surplus_upper_boundLemma 1: for reservation values r and any threshold t >= 0, every valid adaptive policy has expected DUS utility at most t plus the total…
- arrows_grundy_three_witness_tree_structureThe explicit 21-vertex graph defined by 20 edges is a tree of maximum degree at most 3, all of whose piece threads have length at most 3.
- card_pauliStringsExactSupportNumber of Pauli strings with a prescribed support. Let $n$ be a natural number and let $S \subseteq \mathrm{Fin}\,n$ be a set of…
- card_pauliErrorsLeCardinality of the bounded-weight Pauli error set. For natural numbers $n$ and $t$, the number of Pauli strings of length $n$ whose weight…
Lean source view module on GitHub
set_option linter.mathlibStandardSet false in open scoped BigOperators in open scoped Real in open scoped Nat in open scoped Classical in open scoped Pointwise in set_option maxRecDepth 4000 in set_option synthInstance.maxHeartbeats 20000 in set_option synthInstance.maxSize 128 in set_option relaxedAutoImplicit false in set_option autoImplicit false in open Complex Matrix in /-- The support of a Pauli string: the set of qubit indices where the operator is not identity. -/ noncomputable def support {n : ℕ} (p : PauliString n) : Finset (Fin n) := Finset.univ.filter (fun i => p i ≠ PauliBasis.I)