Function sll_ind

Source
pub fn sll_ind<F: Field>(i: &[F], j: &[F], s: &[F]) -> F
Expand description

Computes the multilinear extension of the logical left shift indicator at a point.

The shift indicator for logical left shift (SLL) evaluates to 1 when bit i of the output equals bit j of the input after shifting left by s positions. Specifically:

  • sll_ind(i, j, s) = 1 if and only if i = j + s and i < 2^k
  • sll_ind(i, j, s) = 0 otherwise

This function evaluates the multilinear extension of this indicator at the given point (i, j, s) where each coordinate is a field element.

§Arguments

  • i - Slice of field elements representing the output bit position (length k)
  • j - Slice of field elements representing the input bit position (length k)
  • s - Slice of field elements representing the shift amount (length k)

§Panics

Panics if the slices don’t all have the same length.