diff --git a/rfcs/starknet/fri.html b/rfcs/starknet/fri.html index c74e490..9ba50ad 100644 --- a/rfcs/starknet/fri.html +++ b/rfcs/starknet/fri.html @@ -340,24 +340,20 @@

Protocol constants

FRI constants

MAX_LAST_LAYER_LOG_DEGREE_BOUND = 15. The maximum degree of the last layer polynomial (in log2).

MAX_FRI_LAYERS = 15. The maximum number of layers in the FRI protocol.

-

MAX_FRI_STEP = 4. The maximum number of layers that can be skipped in FRI (see the overview for more details).

+

MAX_FRI_STEP = 4. The maximum number of layers that can be involved in a reduction in FRI (see the overview for more details). This essentially means that each reduction (except for the first as we specify later) can skip 0 to 3 layers.

This means that the standard can be implemented to test that committed polynomials exist and are of degree at most 215+15=230.

-

TODO: Step generators

+

Step Generators And Inverses

+

As explained in the overview, skipped layers must involve the use of elements of the subgroups of order 2i for i the number of layers included in a step (from 1 to 4 as specified previously).

+

As different generators can generate the same subgroups, we have to define the generators that are expected. Instead, we define the inverse of the generators of groups of different orders (as it more closely matches the code):

-

These are used to skip layers during the FRI protocol. Only 1, 2, 3, or 4 layers can be skipped, each associated to one of the constant below (except for skipping a single layer which is trivial):

-
// to skip 4 layers
-const OMEGA_16: felt252 = 0x5c3ed0c6f6ac6dd647c9ba3e4721c1eb14011ea3d174c52d7981c5b8145aa75;
-// to skip 3 layers
-const OMEGA_8: felt252 = 0x446ed3ce295dda2b5ea677394813e6eab8bfbc55397aacac8e6df6f4bc9ca34;
-// to skip 2 layers
-const OMEGA_4: felt252 = 0x1dafdc6d65d66b5accedf99bcd607383ad971a9537cdf25d59e99d90becc81e;
-
-

TODO: explain more here

+

So here, for example, OMEGA_8 is 1/ω8 where ω8 is the generator of the subgroup of order 8 that we later use in the Verify A Layer's Query section.

@@ -501,20 +497,20 @@

Verify A Layer's Query

Queries between layers verify that the next layer pi+j is computed correctly based on the current layer pi. The next layer is either the direct next layer pi+1 or a layer further away if the configuration allows layers to be skipped. Specifically, each reduction is allowed to skip 0, 1, 2, or 3 layers (see the MAX_FRI_STEP constant).

-

The formula with no skipping is:

+

The FRI formula with no skipping is:

-

The formula with 1 layer skipped with ω4 the generator of the 4-th roots of unity (such that ω42=1):

+

The FRI formula with 1 layer skipped with ω4 the generator of the 4-th roots of unity (such that ω42=1):

As you can see, this requires 4 evaluations of p_{i} at v, v, ω4v, ω4v.

-

The formula with 2 layers skipped with ω8 the generator of the 8-th roots of unity (such that ω82=ω4 and ω84=1):

+

The FRI formula with 2 layers skipped with ω8 the generator of the 8-th roots of unity (such that ω82=ω4 and ω84=1):

As you can see, this requires 8 evaluations of p_{i} at v, v, ω4v, ω4v, ω8v, ω8v, ω83v, ω83v.

-

The formula with 3 layers skipped with ω16 the generator of the 16-th roots of unity (such that ω162=ω8, ω164=ω4, and ω168=1):

+

The FRI formula with 3 layers skipped with ω16 the generator of the 16-th roots of unity (such that ω162=ω8, ω164=ω4, and ω168=1):