BoolFourier.BoolToPM1
abbrevimported Lean
The map $\mathrm{BoolToPM1} : \mathrm{Bool} \to \mathbb{R}$ sends $\mathtt{false}$ to $1$ and $\mathtt{true}$ to $-1$, realising the standard identification $\{0,1\} \cong \{\pm 1\}$.
Statement
set_option relaxedAutoImplicit false in set_option autoImplicit false in open Finset BooleanAnalysis in abbrev BoolFourier.BoolToPM1 : Bool → ℝ
- Defined in
- TCSlib, `BoolFourier.BoolToPM1`
- Lean proof
- By Prastik Mohanraj, from github.com/Shilun-Allan-Li/tcslib at
c8a02591b1e5(Copyright (c) 2026 Prastik Mohanraj. All rights reserved, Apache-2.0). Compiled here against leanprover/lean4:v4.33.1, Mathlib v4.33.1; written for leanprover/lean4:v4.25.0.BoolFourier.BoolToPM1← BoolFourier.BoolToPM1 (TCSlib/BooleanAnalysis/BLR/BoolFourier.lean:60): verbatim
- Verified
- 07 Oct 2026
- Axioms
- none listed
- Built on 1
- BooleanAnalysis.boolToSignThe sign encoding maps $\mathrm{Bool}$ to $\{-1,1\}\subset\bbr$:…
- Used by 8
- BoolBLR.fourier_coeff_le_of_far_from_linearFourier coefficient bound for functions far from linear. Let $f : \{0,1\}^n \to \{0,1\}$ be $\varepsilon$-far from linear, meaning that…
- BoolFourier.BoolToPM1_sqSquare of the Bool-to-$\pm 1$ embedding. For every Boolean value $b$, the image $\mathrm{BoolToPM1}(b)$ under the map sending…
- BoolBLR.fourier_coeff_le_of_dist_ge_aux_h_lift_pm1Product of $\pm 1$ lifts as a disagreement indicator. Let $f, g : \{0,1\}^n \to \{0,1\}$ be Boolean-valued functions on the hypercube, and…
- BoolBLR.linear_bool_iff_characterLinear Boolean functions are exactly the Walsh characters. Let $f : \{0,1\}^n \to \{0,1\}$ be a Boolean function. Then $f$ is linear —…
- BoolFourier.BoolToPM1_xorXOR as multiplication under the $\pm 1$ embedding. Let $\mathrm{BoolToPM1} : \mathrm{Bool} \to \bbr$ be the map sending $\mathtt{false}$…
- BoolBLR.linear_bool_iff_character_aux_h_eq_hXOR-additivity of a Boolean function that lifts to a character. Let $f : \{0,1\}^n \to \{0,1\}$ be a Boolean-valued function whose $\pm 1$…
- BoolBLR.lift_pm1Given $f : \{0,1\}^n \to \{0,1\}$, its $\pm 1$ lift $\texttt{BoolBLR.lift\_pm1}\,f : \{0,1\}^n \to \mathbb{R}$ is defined by…
- BoolBLR.linear_bool_iff_character_aux_h_eqXOR-additivity of a Boolean function whose lift is a character. Let $f : \{0,1\}^n \to \{0,1\}$ be a Boolean-valued function whose $\pm 1$…
Lean source view module on GitHub
set_option relaxedAutoImplicit false in set_option autoImplicit false in open Finset BooleanAnalysis in /-- Names the standard embedding of Boolean values into `{±1} ⊂ ℝ`. **Source:** [OD14, §1.3]. -/ abbrev BoolFourier.BoolToPM1 : Bool → ℝ := boolToSign