Constraint Arrays
A convenient formalism
Here, we factor out a convenient notational device that we will use repeatedly.
We fix a total number of constraints. In the situations we'll be working with, we'll have lists of shifted value indices, indexed by ; thus for each , we will have a list .
Our goal here is to define an array, , that contains the words "specified by the lists" . The array will be of length ; each of its elements will be a 64-bit word.
To define , we set, for each :
Efficient Algorithm
There is a straightforward efficient algorithm that computes the array , given the list , which exploits the sparsity of the constraint system. For completeness, we record it here. On input and , the prover runs:
- allocate the array , containing 64-bit words, initially all 0.
- for each do:
- load the th list from the constraint system.
- for each shifted value index do:
- update .
- return .
The array returned by that algorithm equals the constraint array .