Barretenberg
The ZK-SNARK library at the core of Aztec
Loading...
Searching...
No Matches
multilinear_batching_recursive_flavor.hpp
Go to the documentation of this file.
1// === AUDIT STATUS ===
2// internal: { status: not started, auditors: [], date: YYYY-MM-DD }
3// external_1: { status: not started, auditors: [], date: YYYY-MM-DD }
4// external_2: { status: not started, auditors: [], date: YYYY-MM-DD }
5// =====================
6
7#pragma once
8#include <utility>
9
12
13namespace bb {
14
16 public:
20 using PCS = KZG<Curve>;
21 using FF = typename Curve::ScalarField;
22 using Commitment = typename Curve::Element;
24
25 // An upper bound on the size of the MultilinearBatching-circuits. `CONST_PG_LOG_N` bounds the log circuit sizes in
26 // the CIVC context. `MEGA_AVM_LOG_N` is determined by the size of the AVMRecursiveVerifier.
27 static constexpr size_t VIRTUAL_LOG_N = NativeFlavor::VIRTUAL_LOG_N;
28 // Indicates that this flavor runs with non-ZK Sumcheck.
29 static constexpr bool HasZK = NativeFlavor::HasZK;
30 // Indicates that this flavor runs with Multilinear Batching.
32 // To achieve fixed proof size and that the recursive verifier circuit is constant, we are using padding in Sumcheck
33 // and Shplemini
34 static constexpr bool USE_PADDING = NativeFlavor::USE_PADDING;
35 static constexpr size_t NUM_WIRES = NativeFlavor::NUM_WIRES;
36 // The number of multivariate polynomials on which a sumcheck prover sumcheck operates (including shifts). We often
37 // need containers of this size to hold related data, so we choose a name more agnostic than `NUM_POLYNOMIALS`.
39
40 // The total number of witness entities not including shifts.
42
43 // define the tuple of Relations that comprise the Sumcheck relation
44 // Note: made generic for use in MegaRecursive.
45 template <typename FF>
46 using Relations_ =
49
51
52 // BATCHED_RELATION_PARTIAL_LENGTH = algebraic degree of sumcheck relation *after* multiplying by the `pow_zeta`
53 // random polynomial e.g. For \sum(x) [A(x) * B(x) + C(x)] * PowZeta(X), relation length = 2 and random relation
54 // length = 3
57
58 // For instances of this flavour, used in folding, we need a unique sumcheck batching challenges for each
59 // subrelation. This is because using powers of alpha would increase the degree of Protogalaxy polynomial $G$ (the
60 // combiner) too much.
61 static constexpr size_t NUM_SUBRELATIONS = compute_number_of_subrelations<Relations>();
62 using SubrelationSeparators = std::array<FF, NUM_SUBRELATIONS - 1>;
63
65 public:
67 using Base::Base;
68 };
69
71};
72
73} // namespace bb
Common transcript class for both parties. Stores the data for the current round, as well as the manif...
A base class labelling all entities (for instance, all of the polynomials used by the prover during s...
static constexpr size_t BATCHED_RELATION_PARTIAL_LENGTH
static constexpr size_t MAX_PARTIAL_RELATION_LENGTH
std::array< FF, NUM_SUBRELATIONS - 1 > SubrelationSeparators
std::tuple< bb::MultilinearBatchingAccumulatorRelation< FF >, bb::MultilinearBatchingInstanceRelation< FF > > Relations_
A wrapper for Relations to expose methods used by the Sumcheck prover or verifier to add the contribu...
Entry point for Barretenberg command-line interface.
MegaCircuitBuilder_< field< Bn254FrParams > > MegaCircuitBuilder
constexpr decltype(auto) get(::tuplet::tuple< T... > &&t) noexcept
Definition tuple.hpp:13
field_t< CircuitBuilder > ScalarField
Definition bn254.hpp:33