//! A hiding Reed–Solomon tensor commitment with a zero-knowledge linear
//! test: the Ligero geometry (Ames, Hazay, Ishai, Venkitasubramaniam, CCS
//! 2017, §4–5) over Goldilocks with Fp3 challenges.
//!
//! Commit. The entries are laid out row-major in rows of `k` (message
//! width). Row `i`'s polynomial is `p_i(X) = Σ_{c<k} u_{i,c} X^c + X^k·ν_i(X)`
//! with `ν_i` uniform of degree `< k` (`K = 2k` coefficients in all), RS-
//! encoded on the order-`N = K·2^r` subgroup. Three masking rows follow the
//! data rows: `m_a` (uniform, degree `< K`), `m_b` (uniform, degree
//! `< k − 1`) and `m_P` (uniform, degree `< K`). Column `j` with four
//! uniform salt limbs is leaf `j` of a hemera Merkle tree; the root is the
//! commitment.
//!
//! Open a linear functional `Λ` (weights on the entries) at claimed value
//! `V = Σ Λ_e u_e`:
//!
//! 1. send `μ = [X^{k−1}] m_a`; draw `α, ρ_L ∈ Fp3`;
//! 2. send `p_P = Σ_i α^i p_i + α^T m_P` over all `T` codeword rows (degree
//! `< K`) and `q = Σ_i Λ'_i·p_i + ρ_L·(m_a + X^K m_b)` (degree
//! `< K + k − 1`), where `Λ'_i(X) = Σ_c Λ_{i,c} X^{k−1−c}`, so that
//! `[X^{k−1}] q = V + ρ_L·μ`;
//! 3. grind, draw `t` column indices, open the columns, their salts and the
//! Merkle multi-opening; the verifier checks the coefficient identity,
//! `p_P(ω^j)` and `q(ω^j)` against every opened column.
//!
//! Soundness (unique decoding, `D = 2K` bounds the degree of the true `q*`
//! whatever the masking rows hold): with `e = ⌊(N − D + 1)/2⌋`, either the
//! committed rows are jointly `e`-far from RS[N, K] — then, except with
//! probability `(T − 1)·N/|Fp3|` over `α` (correlated agreement for the
//! powers generator, BCIKS20 as in WHIR eprint 2024/1586 Thm 4.8), the
//! combination is far and every query passes with probability `≤ 1 − e/N`
//! — or they are `e`-close with a common agreement set, and a `p_P` or `q`
//! other than the true one passes a query with probability `≤ (D − 1 +
//! e)/N`; when both are the true ones, a wrong `V` survives the coefficient
//! check only for one `ρ_L` (`1/|Fp3|`). Per query `≤ (1 + (D − 1)/N)/2`;
//! grinding adds `pow_bits` to the query round.
//!
//! Zero knowledge (honest verifier, salted leaves in the random-oracle
//! model): every data row has `k ≥ t` uniform padding coefficients, so its
//! values at the `≤ t` opened points are uniform and independent of its
//! message; `p_P` is one-time padded by `m_P`, `q` by `m_L = m_a + X^K m_b`
//! except its `X^{k−1}` coefficient, which equals `V + ρ_L μ` with `μ`
//! uniform; the masking rows' opened values are then determined by `p_P`,
//! `q` and the data columns (`m_b`'s by its `k − 1 ≥ t` coefficients).
//! Unopened leaves are hemera outputs on inputs with 256 bits of salt.
//! A simulator given `V` reproduces the distribution exactly up to the
//! random-oracle term.
pub
pub use HidingProof;
pub use ;
pub use verify;
use Fp3;
/// Masking rows after the data rows: `m_a`, `m_b`, `m_P`.
pub const MASK_ROWS: usize = 3;
/// Salt limbs per column leaf.
pub const SALT: usize = 4;
const VERSION: u8 = 1;
/// Security parameters: printed into the proof, admitted by policy.
/// The shape a commitment of `entries` values takes under `params`.
pub
/// `log2 |Fp3|`.
/// A linear functional on the committed entries: `scale·eq(point, e)` on
/// the first `2^point.len()` entries (MSB-first point; high bits pick the
/// row, low bits the column) plus explicit weights on later entries.
pub
Homonyms
cyb/evy/forks/naga/src/back/hlsl/mod.rs
struct Baz { m: mat3x2, } struct Baz { float2 m_0; float2 m_1; float2 m_2; }; float3x2 GetMatmOnBaz(Baz obj) { return float3x2(obj.m_0, obj.m_1, obj.m_2); }