Step 1 of Algorithm 8.1:
DefinitionTwoFoldOPI_Supplement_ansatzY0coding-theoryoptimal-polynomial-intersectionp2o-gran-per-chapterp2o-plan-paperp2o-v1quantum-algorithmsregev-reductionschur-product-codes
Given and with every , step 1 of Algorithm 8.1 computes
Formalization Note is the field inverse of , nonzero in the odd-order fields of the algorithm.
Definition code
import Mathlib
namespace TwoFoldOPI
namespace Supplement
/-- **Step 1 of Algorithm 8.1: `y_0 = ¼ (h^{−1} ⊙ w^{⊙2} − ξ h)`.**
Ragavan, Shutty, *Quantum Algorithms for OPI Variants Beyond Locality and Classical
Decodability*, arXiv:2610.00502 (version held, sha256 ef050ec0…62605), §8.1, Algorithm 8.1, step 1, p.45: "Compute y_0 = (1/4)(h^{−1} ⊙ w^{⊙2} − ξh)."
Coordinate-wise, `y_0(j) = ¼ (w_j² / h_j − ξ h_j)`.
**Formalization Note.** `¼` is the inverse of `4` in the field; the algorithm's fields have odd
order, where `4 ≠ 0`. `h` has nonzero entries on every input of the algorithm. -/
def ansatzY0 {K : Type*} [Field K] {m : ℕ} (ξ : K) (h w : Fin m → K) : Fin m → K :=
fun j => (4 : K)⁻¹ * ((h j)⁻¹ * w j ^ 2 - ξ * h j)
end Supplement
end TwoFoldOPI
Source
Ragavan, Shutty, Quantum Algorithms for OPI Variants Beyond Locality and Classical Decodability, arXiv:2610.00502 (version held, sha256 ef050ec0…62605), §8.1, Algorithm 8.1, step 1, p. 45