halo2_ecc::eccFunction multi_scalar_multiply
Source pub fn multi_scalar_multiply<F: BigPrimeField, FC, C>(
chip: &FC,
ctx: &mut Context<F>,
P: &[EcPoint<F, FC::FieldPoint>],
scalars: Vec<Vec<AssignedValue<F>>>,
max_bits: usize,
window_bits: usize,
) -> EcPoint<F, FC::FieldPoint>
Expand description
ยงAssumptions
points.len() == scalars.len()
scalars[i].len() == scalars[j].len()
for all i, j
scalars[i]
is less than the order of P
scalars[i][j] < 2^{max_bits} for all j
max_bits <= modulus::<F>.bits()
, and equality only allowed when the order of P
equals the modulus of F
points
are all on the curve or the point at infinity
points[i]
is allowed to be (0, 0) to represent the point at infinity (identity point)
- Currently implementation assumes that the only point on curve with y-coordinate equal to
0
is identity point