Skip to content

Commit 4892b25

Browse files
committed
small fixups
1 parent f35a2ee commit 4892b25

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

docs/r1cs-docs-example.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ Algebraically it can be expressed as a statement that for a free variable \\(z\\
1313
The prover can commit to blinded scalars \\(x_i\\) and \\(y_i\\) then receive a random challenge \\(z\\),
1414
and build a proof that the above relation holds.
1515

16-
K-shuffle requires `2*(K-1)` multipliers.
16+
K-shuffle requires \\( 2*(K-1) \\) multipliers.
1717

1818
For `K > 1`:
1919

@@ -50,7 +50,7 @@ The last multipliers connect the two last variables (on each side)
5050
muly_right[k-2] = y_{k-1} - z
5151
```
5252
For `K = 1`:
53-
Connect x to y directly. Since there is only one permuatation of a 1-element list, we can omit the challenge entirely as it cancels out.
53+
Connect `x_0` to `y_0` directly. Since there is only one permuatation of a 1-element list, we can omit the challenge entirely as it cancels out.
5454
```ascii,no_run
5555
x_0 = y_0
5656
```
@@ -115,11 +115,11 @@ First, the function gets a challenge scalar \\(z\\) by calling the `ConstraintSy
115115

116116
After a check for the lengths of \\(x\\) and \\(y\\), the function then makes
117117
multipliers to create polynomials in terms of the challenge scalar \\(z\\).
118-
It starts with the last multipliers, representing \\( (x_{k-1} - z) *
119-
(x_{k-2} - z) \\) and \\( (y_{k-1} - z) * (y_{k-2} - z) \\). The outputs
118+
It starts with the last multipliers, representing `(x_{k-1} - z) *
119+
(x_{k-2} - z)` and `(y_{k-1} - z) * (y_{k-2} - z)`. The outputs
120120
to these last multipliers than become an input to the next multiplier.
121-
This continues recursively until it reaches \\( x_0 \\) and \\(y_0\\).
122-
Then, it adds a constraint that \\( mulx_out\[0\] = muly_out\[0\] \\),
121+
This continues recursively until it reaches `x_0` and `y_0`.
122+
Then, it adds a constraint that `mulx_out[0]` = `muly_out[0]`,
123123
which constrains that the two polynomials in terms of challenge scalar
124124
\\(z\\) are equal to each other. This is true if and only if \\(y\\) is a valid
125125
reordering of \\(x\\).

0 commit comments

Comments
 (0)