Barretenberg
The ZK-SNARK library at the core of Aztec
Loading...
Searching...
No Matches
bb::TranslatorPermutationRelationImpl< FF_ > Class Template Reference

#include <translator_permutation_relation.hpp>

Public Types

using FF = FF_
 

Static Public Member Functions

template<typename AllEntities >
static bool skip (const AllEntities &in)
 Returns true if the contribution from all subrelations for the provided inputs is identically zero.
 
static auto & get_grand_product_polynomial (auto &in)
 
static auto & get_shifted_grand_product_polynomial (auto &in)
 
template<typename Accumulator , typename AllEntities , typename Parameters >
static Accumulator compute_grand_product_numerator (const AllEntities &in, const Parameters &params)
 
template<typename Accumulator , typename AllEntities , typename Parameters >
static Accumulator compute_grand_product_denominator (const AllEntities &in, const Parameters &params)
 
template<typename ContainerOverSubrelations , typename AllEntities , typename Parameters >
static void accumulate (ContainerOverSubrelations &accumulators, const AllEntities &in, const Parameters &params, const FF &scaling_factor)
 Compute contribution of the goblin translator permutation relation for a given edge (internal function)
 

Static Public Attributes

static constexpr size_t RELATION_LENGTH = 7
 
static constexpr std::array< size_t, 2 > SUBRELATION_PARTIAL_LENGTHS
 

Detailed Description

template<typename FF_>
class bb::TranslatorPermutationRelationImpl< FF_ >

Definition at line 12 of file translator_permutation_relation.hpp.

Member Typedef Documentation

◆ FF

template<typename FF_ >
using bb::TranslatorPermutationRelationImpl< FF_ >::FF = FF_

Definition at line 14 of file translator_permutation_relation.hpp.

Member Function Documentation

◆ accumulate()

template<typename FF >
template<typename ContainerOverSubrelations , typename AllEntities , typename Parameters >
void bb::TranslatorPermutationRelationImpl< FF >::accumulate ( ContainerOverSubrelations &  accumulators,
const AllEntities &  in,
const Parameters &  params,
const FF scaling_factor 
)
static

Compute contribution of the goblin translator permutation relation for a given edge (internal function)

There are 2 relations associated with enforcing the set permutation relation This file handles the relation that confirms faithful calculation of the grand product polynomial Z_perm.

C(in(X)...) = ( z_perm(X) + lagrange_first(X) )*P(X)

  • ( z_perm_shift(X) + lagrange_last(X))*Q(X), where P(X) = Prod_{i=0:4} numerator_polynomial_i(X) + γ Q(X) = Prod_{i=0:4} ordered_range_constraint_i(X) + γ the first 4 numerator polynomials are interleaved range constraint polynomials and the last one is the constant extra numerator

If operating in zero-knowledge, we mark the positions (via the lagrange_masking polynomial) that should contain masking values, expected to be at the same indices both for the ordered and interleaved polynomials.

Parameters
evalstransformed to evals + C(in(X)...)*scaling_factor
inan std::array containing the fully extended Univariate edges.
parameterscontains beta, gamma, and public_input_delta, ....
scaling_factoroptional term to scale the evaluation before adding to evals.

There are 2 relations associated with enforcing the set permutation relation This file handles the relation that confirms faithful calculation of the grand product polynomial Z_perm.

C(in(X)...) = ( z_perm(X) + lagrange_first(X) )*P(X)

  • ( z_perm_shift(X) + lagrange_last(X))*Q(X), where P(X) = Prod_{i=0:4} numerator_polynomial_i(X) + γ Q(X) = Prod_{i=0:4} ordered_range_constraint_i(X) + γ the first 4 numerator polynomials are interleaved range constraint polynomials and the last one is the constant extra numerator

If operating in zero-knowledge, we mark the positions (via the lagrange_masking polynomial) that contain random values.

Parameters
evalstransformed to evals + C(in(X)...)*scaling_factor
inan std::array containing the fully extended Univariate edges.
parameterscontains beta, gamma, and public_input_delta, ....
scaling_factoroptional term to scale the evaluation before adding to evals.

Definition at line 37 of file translator_permutation_relation_impl.hpp.

◆ compute_grand_product_denominator()

template<typename FF_ >
template<typename Accumulator , typename AllEntities , typename Parameters >
static Accumulator bb::TranslatorPermutationRelationImpl< FF_ >::compute_grand_product_denominator ( const AllEntities &  in,
const Parameters &  params 
)
inlinestatic

Definition at line 61 of file translator_permutation_relation.hpp.

◆ compute_grand_product_numerator()

template<typename FF_ >
template<typename Accumulator , typename AllEntities , typename Parameters >
static Accumulator bb::TranslatorPermutationRelationImpl< FF_ >::compute_grand_product_numerator ( const AllEntities &  in,
const Parameters &  params 
)
inlinestatic

Definition at line 38 of file translator_permutation_relation.hpp.

◆ get_grand_product_polynomial()

template<typename FF_ >
static auto & bb::TranslatorPermutationRelationImpl< FF_ >::get_grand_product_polynomial ( auto &  in)
inlinestatic

Definition at line 34 of file translator_permutation_relation.hpp.

◆ get_shifted_grand_product_polynomial()

template<typename FF_ >
static auto & bb::TranslatorPermutationRelationImpl< FF_ >::get_shifted_grand_product_polynomial ( auto &  in)
inlinestatic

Definition at line 35 of file translator_permutation_relation.hpp.

◆ skip()

template<typename FF_ >
template<typename AllEntities >
static bool bb::TranslatorPermutationRelationImpl< FF_ >::skip ( const AllEntities &  in)
inlinestatic

Returns true if the contribution from all subrelations for the provided inputs is identically zero.

Definition at line 27 of file translator_permutation_relation.hpp.

Member Data Documentation

◆ RELATION_LENGTH

template<typename FF_ >
constexpr size_t bb::TranslatorPermutationRelationImpl< FF_ >::RELATION_LENGTH = 7
staticconstexpr

Definition at line 16 of file translator_permutation_relation.hpp.

◆ SUBRELATION_PARTIAL_LENGTHS

template<typename FF_ >
constexpr std::array<size_t, 2> bb::TranslatorPermutationRelationImpl< FF_ >::SUBRELATION_PARTIAL_LENGTHS
staticconstexpr
Initial value:
{
7,
3
}

Definition at line 18 of file translator_permutation_relation.hpp.


The documentation for this class was generated from the following files: