barretenberg
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | List of all members
barretenberg::PowUnivariate< FF > Struct Template Reference

#include <pow.hpp>

Public Member Functions

 PowUnivariate (FF zeta_pow)
 
FF univariate_eval (FF challenge) const
 
void partially_evaluate (FF challenge)
 Parially evaluate the polynomial in the new challenge, by updating the constant c_{l} -> c_{l+1}. Also update (ζ_{l}, ζ_{l+1}) -> (ζ_{l+1}, ζ_{l+1}^2)
 

Public Attributes

FF zeta_pow
 
FF zeta_pow_sqr
 
FF partial_evaluation_constant = FF(1)
 

Detailed Description

template<typename FF>
struct barretenberg::PowUnivariate< FF >

Note that

pow(X) = ∏_{0≤l<d} ((1−X_l) + X_l⋅ζ_l) is the multi-linear polynomial whose evaluation at the i-th index of the full hypercube, equals ζⁱ. We can also see it as the multi-linear extension of the vector (1, ζ, ζ², ...).

We want to check that P(i)=0 for all i ∈ {0,1}^d. So we use Sumcheck over the polynomial P'(X) = pow(X)⋅P(X). The claimed sum is 0 and is equal to ∑_{i ∈ {0,1}^d} pow(i)⋅P(i) = ∑_{i ∈ {0,1}^d} ζ^{i}⋅P(i) If the Sumcheck passes, then with it must hold with high-probability that all P(i) are 0.

The trivial implementation using P'(X) directly would increase the degree of our combined relation by 1. Instead, we exploit the special structure of pow to preserve the same degree.

In each round l, the prover should compute the univariate polynomial for the relation defined by P'(X) S'ˡ(X_l) = ∑_{ 0 ≤ i < 2^{d-l-1} } powˡᵢ( X_l ) Sˡᵢ( X_l ) . = ∑_{ 0 ≤ i < 2^{d-l-1} } [ ζ_{l+1}ⁱ⋅( (1−X_l) + X_l⋅ζ_l )⋅c_l ]⋅Sˡᵢ( X_l ) = ( (1−X_l) + X_l⋅ζ_l ) ⋅ ∑_{ 0 ≤ i < 2^{d-l-1} } [ c_l ⋅ ζ_{l+1}ⁱ ⋅ Sˡᵢ( X_l ) ] = ( (1−X_l) + X_l⋅ζ_l ) ⋅ ∑_{ 0 ≤ i < 2^{d-l-1} } [ c_l ⋅ ζ_{l+1}ⁱ ⋅ Sˡᵢ( X_l ) ]

If we define Tˡ( X_l ) := ∑_{0≤i<2ˡ} [ c_l ⋅ ζ_{l+1}ⁱ ⋅ Sˡᵢ( X_l ) ], then Tˡ has the same degree as the original Sˡ( X_l ) for the relation P(X) and is only slightly more expensive to compute than Sˡ( X_l ). Moreover, given Tˡ( X_l ), the verifier can evaluate S'ˡ( u_l ) by evaluating ( (1−u_l) + u_l⋅ζ_l )Tˡ( u_l ). When the verifier checks the claimed sum, the procedure is modified as follows

Init:

Round 0≤l<d-1:

Final round l=d-1:

Member Function Documentation

◆ partially_evaluate()

template<typename FF >
void barretenberg::PowUnivariate< FF >::partially_evaluate ( FF  challenge)
inline

Parially evaluate the polynomial in the new challenge, by updating the constant c_{l} -> c_{l+1}. Also update (ζ_{l}, ζ_{l+1}) -> (ζ_{l+1}, ζ_{l+1}^2)

Parameters
challengel-th verifier challenge u_{l}

The documentation for this struct was generated from the following file: