diff --git a/specs/_features/eip7594/polynomial-commitments-sampling.md b/specs/_features/eip7594/polynomial-commitments-sampling.md index 19c3569b8..8dceb3ebe 100644 --- a/specs/_features/eip7594/polynomial-commitments-sampling.md +++ b/specs/_features/eip7594/polynomial-commitments-sampling.md @@ -130,13 +130,13 @@ def coset_evals_to_cell(coset_evals: CosetEvals) -> Cell: ```python def g2_lincomb(points: Sequence[G2Point], scalars: Sequence[BLSFieldElement]) -> Bytes96: """ - BLS multiscalar multiplication in G2. This function can be optimized using Pippenger's algorithm and variants. + BLS multiscalar multiplication in G2. This can be naively implemented using double-and-add. """ assert len(points) == len(scalars) points_g2 = [] for point in points: points_g2.append(bls.bytes96_to_G2(point)) - result = bls.g2_multi_exp(points_g2, scalars) + result = bls.multi_exp(points_g2, scalars) return Bytes96(bls.G2_to_bytes96(result)) ``` diff --git a/specs/deneb/polynomial-commitments.md b/specs/deneb/polynomial-commitments.md index 953bc28cd..26db0df93 100644 --- a/specs/deneb/polynomial-commitments.md +++ b/specs/deneb/polynomial-commitments.md @@ -274,13 +274,13 @@ def div(x: BLSFieldElement, y: BLSFieldElement) -> BLSFieldElement: ```python def g1_lincomb(points: Sequence[KZGCommitment], scalars: Sequence[BLSFieldElement]) -> KZGCommitment: """ - BLS multiscalar multiplication. This function can be optimized using Pippenger's algorithm and variants. + BLS multiscalar multiplication in G1. This can be naively implemented using double-and-add. """ assert len(points) == len(scalars) points_g1 = [] for point in points: points_g1.append(bls.bytes48_to_G1(point)) - result = bls.g1_multi_exp(points_g1, scalars) + result = bls.multi_exp(points_g1, scalars) return KZGCommitment(bls.G1_to_bytes48(result)) ```